diff --git a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Jobs/ThirdLocationJobController.cs b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Jobs/ThirdLocationJobController.cs
new file mode 100644
index 000000000..f86c7587d
--- /dev/null
+++ b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Jobs/ThirdLocationJobController.cs
@@ -0,0 +1,204 @@
+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/third-location")]
+public class ThirdLocationJobController : AbpController
+{
+ private readonly IThirdLocationJobAppService _thirdLocationJobAppService;
+
+ private readonly IUserWorkGroupAppService _userWorkGroupAppService;
+
+ private readonly IDictAppService _dictApp;
+
+ ///
+ ///
+ ///
+ ///
+ ///
+ public ThirdLocationJobController(
+ IThirdLocationJobAppService thirdLocationJobAppService,
+ IDictAppService dictApp
+ , IUserWorkGroupAppService userWorkGroupAppService)
+ {
+ _userWorkGroupAppService = userWorkGroupAppService;
+ _thirdLocationJobAppService = thirdLocationJobAppService;
+ _dictApp = dictApp;
+ }
+
+ ///
+ /// 获取任务详情
+ ///
+ ///
+ ///
+ [HttpGet("{id}")]
+
+ public virtual async Task> GetAsync(Guid id)
+ {
+ var result = await _thirdLocationJobAppService.GetAsync(id).ConfigureAwait(false);
+ return Ok(result);
+ }
+
+ ///
+ /// 获取列表 筛选
+ ///
+ ///
+ ///
+ [HttpPost("list")]
+ public virtual async Task> GetListAsync(SfsJobRequestInputBase sfsRequestDTO)
+ {
+ var list = await _thirdLocationJobAppService.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(ThirdLocationJobDTO.CreationTime)} ASC",
+ Condition = new Condition
+ {
+ Filters = new List
+ {
+ new(nameof(ThirdLocationJobDTO.JobStatus),jsonStatus,"In")
+ }
+ }
+ };
+
+ var list = await _thirdLocationJobAppService.GetPagedListByFilterAsync(request, true).ConfigureAwait(false);
+
+
+ return list;
+ }
+
+ ///
+ /// 根据Job Number 获取任务列表
+ ///
+ ///
+ ///
+ [HttpGet("by-number/{jobNumber}")]
+ public virtual async Task> GetByNumberAsync(string jobNumber)
+ {
+ var jobDto = await _thirdLocationJobAppService.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(ThirdLocationJobDTO.Priority)} ASC",
+ Condition = new Condition
+ {
+ Filters = new List
+ {
+ new(nameof(ThirdLocationJobDTO.WorkGroupCode),jsonCodes,"In"),
+ new(nameof(ThirdLocationJobDTO.JobStatus),jsonStatus,"In")
+ }
+ }
+ };
+
+ var count = await _thirdLocationJobAppService.GetCountByFilterAsync(request).ConfigureAwait(false);
+
+ return Ok(count);
+ }
+
+ ///
+ /// 承接任务
+ ///
+ ///
+ ///
+ [HttpPost("take/{id}")]
+ public virtual async Task TakeAsync(Guid id)
+ {
+ await _thirdLocationJobAppService.AcceptAsync(id).ConfigureAwait(false);
+ }
+
+ ///
+ /// 取消承接任务
+ ///
+ ///
+ ///
+ [HttpPost("cancel-take/{id}")]
+ public virtual async Task CancelTakeAsync(Guid id)
+ {
+ await _thirdLocationJobAppService.CancelAcceptAsync(id).ConfigureAwait(false);
+ }
+
+ ///
+ /// 执行任务
+ ///
+ ///
+ ///
+ ///
+ [HttpPost("finish/{id}")]
+ public virtual async Task FinishAsync(Guid id, [FromBody] ThirdLocationJobDTO dto)
+ {
+ await _thirdLocationJobAppService.CompleteAsync(id, dto).ConfigureAwait(false);
+ }
+}
diff --git a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/ThirdLocationNoteController.cs b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/ThirdLocationNoteController.cs
new file mode 100644
index 000000000..9006c134d
--- /dev/null
+++ b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/ThirdLocationNoteController.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/third-location-note")]
+
+public class ThirdLocationNoteController : AbpController
+{
+ private readonly IThirdLocationNoteAppService _thirdLocationNoteAppService;
+
+ ///
+ ///
+ ///
+ ///
+ public ThirdLocationNoteController(IThirdLocationNoteAppService thirdLocationNoteAppService)
+ {
+ _thirdLocationNoteAppService = thirdLocationNoteAppService;
+ }
+
+ ///
+ /// 创建器具转移记录
+ ///
+ /// CreateInput
+ ///
+ [HttpPost("")]
+ public virtual async Task CreateAsync(ThirdLocationNoteEditInput input)
+ {
+ await _thirdLocationNoteAppService.CreateAsync(input).ConfigureAwait(false);
+ }
+
+}
diff --git a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/ThirdLocationRequestController.cs b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/ThirdLocationRequestController.cs
new file mode 100644
index 000000000..2ad863e8f
--- /dev/null
+++ b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/ThirdLocationRequestController.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/third-location-request")]
+
+public class ThirdLocationRequestController : AbpController
+{
+ private readonly IThirdLocationRequestAppService _thirdLocationRequestAppService;
+
+ ///
+ ///
+ ///
+ ///
+ public ThirdLocationRequestController(IThirdLocationRequestAppService ThirdLocationRequestAppService)
+ {
+ _thirdLocationRequestAppService = ThirdLocationRequestAppService;
+ }
+
+ ///
+ /// 三方库库移申请
+ ///
+ ///
+ ///
+ [HttpPost("")]
+ public virtual async Task CreateAsync(ThirdLocationRequestEditInput input)
+ {
+ _ = await _thirdLocationRequestAppService.CreateAsync(input).ConfigureAwait(false);
+ }
+
+ ///
+ /// 根据number获取三方库库移申请详情
+ ///
+ ///
+ ///
+ [HttpGet("{number}")]
+
+ public virtual async Task> GetAsync(string number)
+ {
+ var result = await _thirdLocationRequestAppService.GetByNumberAsync(number).ConfigureAwait(false);
+ return Ok(result);
+ }
+
+}
diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductLineItems/DTOs/ProductionLineItemDTO.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductLineItems/DTOs/ProductionLineItemDTO.cs
index a40dc03ee..ba932f2f9 100644
--- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductLineItems/DTOs/ProductionLineItemDTO.cs
+++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductLineItems/DTOs/ProductionLineItemDTO.cs
@@ -2,82 +2,67 @@
// Copyright (c) 闻荫科技 www.ccwin-in.com
using System.ComponentModel.DataAnnotations;
+using Win_in.Sfs.Shared.Domain.Entities;
namespace Win_in.Sfs.Basedata.Application.Contracts;
///
-/// 生产线-物品配置
+/// 生产线-物料关系
///
-[Display(Name = "生产线物品配置")]
-
+[Display(Name = "生产线-物料关系")]
public class ProductionLineItemDTO : SfsBaseDataDTOBase
{
///
- /// 生产线代码
+ /// 生产线代码
///
+ [Key]
[Display(Name = "生产线代码")]
+ [Required(ErrorMessage = "{0}是必填项")]
+ [IgnoreUpdate]
public string ProdLineCode { get; set; }
///
- /// 物品代码
+ /// 物品代码
///
+ [Key]
[Display(Name = "物品代码")]
+ [Required(ErrorMessage = "{0}是必填项")]
+ [IgnoreUpdate]
public string ItemCode { get; set; }
- //[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 ProdLineId { get; set; }
-
- /////
- ///// 生产线Name
- /////
- //public string ProdLineName { get; set; }
-
- /////
- ///// 物品Code
- /////
- //public string ItemCode { get; set; }
-
- /////
- ///// 物品Code
- /////
- //public string ItemName { get; set; }
-
- /////
- ///// 产品结构ID
- /////
- //[Display(Name = "产品结构Id")]
- //[Required(ErrorMessage = "{0}是必填项")]
- //public Guid BomId { get; set; }
+ ///
+ /// 物品名称
+ ///
+ [Display(Name = "物品名称")]
+ public string ItemName { get; set; }
- /////
- ///// Bom名称
- /////
- //public string BomName { get; set; }
+ ///
+ /// 物品描述1
+ ///
+ [Display(Name = "物品描述1")]
+ public string ItemDesc1 { get; set; }
- /////
- ///// 产品结构BomType
- /////
- //public string BomBomType { get; set; }
+ ///
+ /// 物品描述2
+ ///
+ [Display(Name = "物品描述2")]
+ public string ItemDesc2 { get; set; }
- /////
- ///// 工艺路线ID
- /////
- //[Display(Name = "工艺路线Id")]
- //[Required(ErrorMessage = "{0}是必填项")]
- //public Guid RoutingId { get; set; }
+ ///
+ /// 原料库位
+ ///
+ [Display(Name = "原料库位Json集合")]
+ public string RawLocationCodeListJson { get; set; }
- /////
- ///// 工艺路线Name
- /////
- //public string RouteName { get; set; }
+ ///
+ /// 成品库位
+ ///
+ [Display(Name = "完工库位Json集合")]
+ public string ProductLocationCodeListJson { get; set; }
+ ///
+ /// 线边库位
+ ///
+ [Display(Name = "线边库位Json集合")]
+ public string WipLocationCodeListJson { get; set; }
}
diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductLineItems/IProductionLineItemAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductLineItems/IProductionLineItemAppService.cs
index f1a69ce8d..555544476 100644
--- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductLineItems/IProductionLineItemAppService.cs
+++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductLineItems/IProductionLineItemAppService.cs
@@ -1,6 +1,8 @@
// 闻荫智慧工厂管理套件
// Copyright (c) 闻荫科技 www.ccwin-in.com
+using System.Collections.Generic;
+using System.Threading.Tasks;
using Win_in.Sfs.Shared.Application.Contracts;
namespace Win_in.Sfs.Basedata.Application.Contracts;
@@ -10,5 +12,5 @@ public interface IProductionLineItemAppService
, ISfsUpsertAppService
{
-
+ Task> GetByProductLineCodeAsync(string productLineCode);
}
diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductLineItems/Inputs/ProductionLineItemEditInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductLineItems/Inputs/ProductionLineItemEditInput.cs
index 84cad66c2..64d2f07d2 100644
--- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductLineItems/Inputs/ProductionLineItemEditInput.cs
+++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductLineItems/Inputs/ProductionLineItemEditInput.cs
@@ -2,30 +2,64 @@
// Copyright (c) 闻荫科技 www.ccwin-in.com
using System.ComponentModel.DataAnnotations;
-using Win_in.Sfs.Shared.Domain;
+using Win_in.Sfs.Shared.Domain.Entities;
namespace Win_in.Sfs.Basedata.Application.Contracts;
///
-/// 生产线物品
+/// 生产线物品
///
public class ProductionLineItemEditInput : SfsBaseDataCreateOrUpdateInputBase
{
- #region Create
///
- /// 生产线代码
+ /// 生产线代码
///
[Display(Name = "生产线代码")]
[Required(ErrorMessage = "{0}是必填项")]
- [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")]
+ [IgnoreUpdate]
public string ProdLineCode { get; set; }
///
- /// 物品代码
+ /// 物品代码
///
[Display(Name = "物品代码")]
[Required(ErrorMessage = "{0}是必填项")]
- [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")]
+ [IgnoreUpdate]
public string ItemCode { get; set; }
- #endregion
+
+ ///
+ /// 物品名称
+ ///
+ [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 = "原料库位Json集合")]
+ public string RawLocationCodeListJson { get; set; }
+
+ ///
+ /// 成品库位
+ ///
+ [Display(Name = "完工库位Json集合")]
+ public string ProductLocationCodeListJson { get; set; }
+
+ ///
+ /// 线边库位
+ ///
+ [Display(Name = "线边库位Json集合")]
+ public string WipLocationCodeListJson { get; set; }
}
diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductLineItems/Inputs/ProductionLineItemImportInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductLineItems/Inputs/ProductionLineItemImportInput.cs
index 865a2d16e..82a581d93 100644
--- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductLineItems/Inputs/ProductionLineItemImportInput.cs
+++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductLineItems/Inputs/ProductionLineItemImportInput.cs
@@ -2,90 +2,71 @@
// Copyright (c) 闻荫科技 www.ccwin-in.com
using System.ComponentModel.DataAnnotations;
-using Win_in.Sfs.Shared.Domain;
+using Win_in.Sfs.Shared.Domain.Entities;
namespace Win_in.Sfs.Basedata.Application.Contracts;
///
-/// 生产线-物品配置
+/// 生产线-物品配置
///
[Display(Name = "生产线物品信息")]
public class ProductionLineItemImportInput : SfsBaseDataImportInputBase
{
///
- /// 生产线代码
+ /// 生产线代码
///
- [Key]
[Display(Name = "生产线代码")]
[Required(ErrorMessage = "{0}是必填项")]
- [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")]
+ [IgnoreUpdate]
public string ProdLineCode { get; set; }
///
- /// 物品代码
+ /// 物品代码
///
- [Key]
[Display(Name = "物品代码")]
[Required(ErrorMessage = "{0}是必填项")]
- [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")]
+ [IgnoreUpdate]
public string ItemCode { get; set; }
///
- /// 备注
+ /// 物品名称
///
- [Display(Name = "备注")]
- [StringLength(SfsEfCorePropertyConst.RemarkLength, ErrorMessage = "{0}最多输入{1}个字符")]
- public string Remark { get; set; }
-
- /////
- ///// 生产线ID
- /////
- //[Display(Name = "生产线Id")]
- //[Required(ErrorMessage = "{0}是必填项")]
- //public Guid ProdLineId { get; set; }
-
- /////
- ///// 生产线Name
- /////
- //public string ProdLineName { get; set; }
-
- /////
- ///// 物品Code
- /////
- //public string ItemCode { get; set; }
+ [Display(Name = "物品名称")]
+ public string ItemName { get; set; }
- /////
- ///// 物品Code
- /////
- //public string ItemName { get; set; }
-
- /////
- ///// 产品结构ID
- /////
- //[Display(Name = "产品结构Id")]
- //[Required(ErrorMessage = "{0}是必填项")]
- //public Guid BomId { get; set; }
+ ///
+ /// 物品描述1
+ ///
+ [Display(Name = "物品描述1")]
+ public string ItemDesc1 { get; set; }
- /////
- ///// Bom名称
- /////
- //public string BomName { get; set; }
+ ///
+ /// 物品描述2
+ ///
+ [Display(Name = "物品描述2")]
+ public string ItemDesc2 { get; set; }
- /////
- ///// 产品结构BomType
- /////
- //public string BomBomType { get; set; }
+ ///
+ /// 原料库位
+ ///
+ [Display(Name = "原料库位Json集合")]
+ public string RawLocationCodeListJson { get; set; }
- /////
- ///// 工艺路线ID
- /////
- //[Display(Name = "工艺路线Id")]
- //[Required(ErrorMessage = "{0}是必填项")]
- //public Guid RoutingId { get; set; }
+ ///
+ /// 成品库位
+ ///
+ [Display(Name = "完工库位Json集合")]
+ public string ProductLocationCodeListJson { get; set; }
- /////
- ///// 工艺路线Name
- /////
- //public string RouteName { get; set; }
+ ///
+ /// 线边库位
+ ///
+ [Display(Name = "线边库位Json集合")]
+ public string WipLocationCodeListJson { get; set; }
+ ///
+ /// 备注
+ ///
+ [Display(Name = "备注")]
+ public string Remark { get; set; }
}
diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductionLines/DTOs/ProductionLineDTO.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductionLines/DTOs/ProductionLineDTO.cs
index d5c2980d1..9665851df 100644
--- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductionLines/DTOs/ProductionLineDTO.cs
+++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductionLines/DTOs/ProductionLineDTO.cs
@@ -1,6 +1,4 @@
-using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
-using Win_in.Sfs.Basedata.Domain.Shared;
using Win_in.Sfs.Shared.Domain;
using Win_in.Sfs.Shared.Domain.Entities;
@@ -15,11 +13,19 @@ public class ProductionLineDTO : SfsBaseDataDTOBase, IHasCode, IHasName
///
/// 代码
///
- [Display(Name = "代码")]
+ [Display(Name = "生产线代码")]
[Key]
[IgnoreUpdate]
public string Code { get; set; }
+ ///
+ /// 库位
+ ///
+ [Display(Name = "库位代码")]
+ [Key]
+ [IgnoreUpdate]
+ public string LocationCode { get; set; }
+
///
/// 名称
///
@@ -31,27 +37,4 @@ public class ProductionLineDTO : SfsBaseDataDTOBase, IHasCode, IHasName
///
[Display(Name = "描述")]
public string Description { get; set; }
-
- ///
- /// 类型
- ///
- public EnumProductionLineType Type { get; set; }
-
- ///
- /// 原料库位
- ///
- [Display(Name = "原料库位Json集合")]
- public string RawLocationCodeListJson { get; set; }
-
- ///
- /// 成品库位
- ///
- [Display(Name = "完工库位Json集合")]
- public string ProductLocationCodeListJson { get; set; }
-
- ///
- /// 线边库位
- ///
- [Display(Name = "线边库位Json集合")]
- public string WipLocationCodeListJson { get; set; }
}
diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductionLines/IProductionLineAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductionLines/IProductionLineAppService.cs
index 5c97fc68f..a6737d11b 100644
--- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductionLines/IProductionLineAppService.cs
+++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductionLines/IProductionLineAppService.cs
@@ -8,4 +8,5 @@ public interface IProductionLineAppService
, ISfsGetByCodeAppService
, ISfsUpsertAppService
{
+ Task GetByLocationCodeAsync(string locationCode);
}
diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductionLines/Inputs/ProductionLineEditInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductionLines/Inputs/ProductionLineEditInput.cs
index 52c391c8c..6fb089009 100644
--- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductionLines/Inputs/ProductionLineEditInput.cs
+++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductionLines/Inputs/ProductionLineEditInput.cs
@@ -1,24 +1,29 @@
-using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
-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;
///
-/// 新增和更新基础DTO
+/// 新增和更新基础DTO
///
public class ProductionLineEditInput : SfsBaseDataCreateOrUpdateInputBase
{
///
/// 代码
///
- [Display(Name = "代码")]
+ [Display(Name = "生产线代码")]
[Key]
[IgnoreUpdate]
public string Code { get; set; }
+ ///
+ /// 库位
+ ///
+ [Display(Name = "库位代码")]
+ [Key]
+ [IgnoreUpdate]
+ public string LocationCode { get; set; }
+
///
/// 名称
///
@@ -30,27 +35,4 @@ public class ProductionLineEditInput : SfsBaseDataCreateOrUpdateInputBase
///
[Display(Name = "描述")]
public string Description { get; set; }
-
- ///
- /// 类型
- ///
- public EnumProductionLineType Type { get; set; }
-
- ///
- /// 原料库位
- ///
- [Display(Name = "原料库位Json集合")]
- public string RawLocationCodeListJson { get; set; }
-
- ///
- /// 成品库位
- ///
- [Display(Name = "完工库位Json集合")]
- public string ProductLocationCodeListJson { get; set; }
-
- ///
- /// 线边库位
- ///
- [Display(Name = "线边库位Json集合")]
- public string WipLocationCodeListJson { get; set; }
}
diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductionLines/Inputs/ProductionLineImportInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductionLines/Inputs/ProductionLineImportInput.cs
index bbc24b3ae..cdfd4fcfe 100644
--- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductionLines/Inputs/ProductionLineImportInput.cs
+++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/ProductionLines/Inputs/ProductionLineImportInput.cs
@@ -1,13 +1,10 @@
-using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
-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;
///
-/// 实体DTO
+/// 实体DTO
///
[Display(Name = "生产线")]
public class ProductionLineImportInput : SfsBaseDataImportInputBase
@@ -15,11 +12,19 @@ public class ProductionLineImportInput : SfsBaseDataImportInputBase
///
/// 代码
///
- [Display(Name = "代码")]
+ [Display(Name = "生产线代码")]
[Key]
[IgnoreUpdate]
public string Code { get; set; }
+ ///
+ /// 库位
+ ///
+ [Display(Name = "库位代码")]
+ [Key]
+ [IgnoreUpdate]
+ public string LocationCode { get; set; }
+
///
/// 名称
///
@@ -31,27 +36,4 @@ public class ProductionLineImportInput : SfsBaseDataImportInputBase
///
[Display(Name = "描述")]
public string Description { get; set; }
-
- ///
- /// 类型
- ///
- public EnumProductionLineType Type { get; set; }
-
- ///
- /// 原料库位
- ///
- [Display(Name = "原料库位Json集合")]
- public string RawLocationCodeListJson { get; set; }
-
- ///
- /// 成品库位
- ///
- [Display(Name = "完工库位Json集合")]
- public string ProductLocationCodeListJson { get; set; }
-
- ///
- /// 线边库位
- ///
- [Display(Name = "线边库位Json集合")]
- public string WipLocationCodeListJson { get; set; }
}
diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/ErpLocationItems/ErpLocationItemAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/ErpLocationItems/ErpLocationItemAppService.cs
index 1f81f0138..1e34c1f8b 100644
--- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/ErpLocationItems/ErpLocationItemAppService.cs
+++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/ErpLocationItems/ErpLocationItemAppService.cs
@@ -61,7 +61,7 @@ public class ErpLocationItemAppService
if(entity != null)
{
- throw new UserFriendlyException($"物品{input.ItemCode}和储位{input.ErpLocationCode} 对应关系已存在");
+ throw new UserFriendlyException($"物品 {input.ItemCode} 和储位 {input.ErpLocationCode} 对应关系已存在");
}
return await base.CreateAsync(input).ConfigureAwait(false);
diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/ProductionLineItems/ProductionLineItemAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/ProductionLineItems/ProductionLineItemAppService.cs
index 1abc97b23..5f6c35eab 100644
--- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/ProductionLineItems/ProductionLineItemAppService.cs
+++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/ProductionLineItems/ProductionLineItemAppService.cs
@@ -1,7 +1,6 @@
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Threading.Tasks;
-
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc;
using Volo.Abp.Caching;
@@ -13,44 +12,45 @@ namespace Win_in.Sfs.Basedata.Application;
[Authorize]
[Route($"{BasedataConsts.RootPath}prod-line-item")]
-
-public class ProductionLineItemAppService : SfsBaseDataAppServiceBase, IProductionLineItemAppService
+public class ProductionLineItemAppService :
+ SfsBaseDataAppServiceBase, IProductionLineItemAppService
{
private new readonly IProductionLineItemRepository _repository;
-
- private readonly IProductionLineItemManager _manager;
-
- private readonly IProductionLineAppService _productionLineAppService;
-
public ProductionLineItemAppService(
IProductionLineItemRepository repository
, IDistributedCache cache
, IProductionLineItemManager manager
, IProductionLineAppService prodLineAppService
- ) : base(repository, cache)
+ ) : base(repository, cache)
{
_repository = repository;
- _manager = manager;
- _productionLineAppService = prodLineAppService;
base.CreatePolicyName = ProductionLineItemPermissions.Create;
base.UpdatePolicyName = ProductionLineItemPermissions.Update;
base.DeletePolicyName = ProductionLineItemPermissions.Delete;
-
}
[HttpPost("upsert")]
-
public virtual async Task UpsertAsync(ProductionLineItemEditInput input)
{
var entity = ObjectMapper.Map(input);
await _repository.UpsertAsync(entity).ConfigureAwait(false);
}
- protected override async Task ValidateImportModelAsync(ProductionLineItemImportInput importInput, List validationRresult)
+ protected override async Task ValidateImportModelAsync(ProductionLineItemImportInput importInput,
+ List validationRresult)
{
await base.ValidateImportModelAsync(importInput, validationRresult).ConfigureAwait(false);
- await base.CheckItemBasicItemCodeAsync(importInput.ItemCode, validationRresult).ConfigureAwait(false);
- await base.CheckProductionLineProdLineCodeAsync(importInput.ProdLineCode, validationRresult).ConfigureAwait(false);
+ await CheckItemBasicItemCodeAsync(importInput.ItemCode, validationRresult).ConfigureAwait(false);
+ await CheckProductionLineProdLineCodeAsync(importInput.ProdLineCode, validationRresult).ConfigureAwait(false);
+ }
+
+
+ [HttpPost("get-by-product")]
+ public virtual async Task> GetByProductLineCodeAsync(string productLineCode)
+ {
+ var entityList = await _repository.GetListAsync(p => p.ProdLineCode == productLineCode).ConfigureAwait(false);
+ return ObjectMapper.Map, List>(entityList);
}
}
diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/ProductionLines/ProductionLineAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/ProductionLines/ProductionLineAppService.cs
index 1f92877ce..188bfb5f4 100644
--- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/ProductionLines/ProductionLineAppService.cs
+++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/ProductionLines/ProductionLineAppService.cs
@@ -1,9 +1,7 @@
-using System.Collections.Generic;
-using System.ComponentModel.DataAnnotations;
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;
@@ -13,9 +11,9 @@ namespace Win_in.Sfs.Basedata.Application;
[Authorize]
[Route($"{BasedataConsts.RootPath}productionline")]
-
public class ProductionLineAppService
- : SfsBaseDataWithCodeAppServiceBase
+ : SfsBaseDataWithCodeAppServiceBase
, IProductionLineAppService
{
private new readonly IProductionLineRepository _repository;
@@ -29,7 +27,7 @@ public class ProductionLineAppService
, IDistributedCache cache
, IProductionLineManager manager
, IWorkGroupAppService workGroupAppService
- ) : base(repository, cache)
+ ) : base(repository, cache)
{
_repository = repository;
_manager = manager;
@@ -46,4 +44,16 @@ public class ProductionLineAppService
var entity = ObjectMapper.Map(input);
await _repository.UpsertAsync(entity).ConfigureAwait(false);
}
+
+ [HttpPost("get-by-location")]
+ public virtual async Task GetByLocationCodeAsync(string locationCode)
+ {
+ var entity = await _repository.FindAsync(p => p.LocationCode == locationCode).ConfigureAwait(false);
+ if (entity == null)
+ {
+ throw new UserFriendlyException($"【{locationCode}】库位不存在");
+ }
+
+ return ObjectMapper.Map(entity);
+ }
}
diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/ProductionLineItems/ProductionLineItem.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/ProductionLineItems/ProductionLineItem.cs
index 50ec7858e..c319c0d17 100644
--- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/ProductionLineItems/ProductionLineItem.cs
+++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/ProductionLineItems/ProductionLineItem.cs
@@ -7,72 +7,60 @@ using Win_in.Sfs.Shared.Domain.Entities;
namespace Win_in.Sfs.Basedata.Domain;
///
-/// 生产线-物品配置
+/// 生产线-物品配置
///
public class ProductionLineItem : SfsBaseDataAggregateRootBase
{
///
- /// 生产线代码
+ /// 生产线代码
///
+ [Key]
[Display(Name = "生产线代码")]
[Required(ErrorMessage = "{0}是必填项")]
[IgnoreUpdate]
public string ProdLineCode { get; set; }
///
- /// 物品代码
+ /// 物品代码
///
[Display(Name = "物品代码")]
[Required(ErrorMessage = "{0}是必填项")]
[IgnoreUpdate]
public string ItemCode { get; set; }
- /////
- ///// 生产线ID
- /////
- //[Display(Name = "生产线Id")]
- //[Required(ErrorMessage = "{0}是必填项")]
- //public Guid ProdLineId { get; internal set; }
-
- /////
- ///// 生产线 聚合根
- /////
- //public virtual ProductionLine ProdLineAggregateRoot { get; internal set; }
-
- /////
- ///// 物品ID
- /////
- //[Display(Name = "物品Id")]
- //[Required(ErrorMessage = "{0}是必填项")]
- //public Guid ItemId { get; internal set; }
-
- /////
- ///// 物品 聚合根
- /////
- ////public virtual Item ItemsAggregateRoot { get; internal set; }
+ ///
+ /// 物品名称
+ ///
+ [Display(Name = "物品名称")]
+ public string ItemName { get; set; }
- /////
- ///// 产品结构ID
- /////
- //[Display(Name = "产品结构Id")]
- //[Required(ErrorMessage = "{0}是必填项")]
- //public Guid BomId { get; internal set; }
+ ///
+ /// 物品描述1
+ ///
+ [Display(Name = "物品描述1")]
+ public string ItemDesc1 { get; set; }
- /////
- ///// 产品结构 聚合根
- /////
- ////public virtual Bom BomAggregateRoots { get; set; }
+ ///
+ /// 物品描述2
+ ///
+ [Display(Name = "物品描述2")]
+ public string ItemDesc2 { get; set; }
- /////
- ///// 工艺路线ID
- /////
- //[Display(Name = "工艺路线Id")]
- //[Required(ErrorMessage = "{0}是必填项")]
- //public Guid RoutingId { get; internal set; }
+ ///
+ /// 原料库位
+ ///
+ [Display(Name = "原料库位Json集合")]
+ public string RawLocationCodeListJson { get; set; }
- /////
- ///// 工艺路线 聚合根
- /////
- ////public virtual Route RouteAggregateRoot { get; set; }
+ ///
+ /// 成品库位
+ ///
+ [Display(Name = "完工库位Json集合")]
+ public string ProductLocationCodeListJson { get; set; }
+ ///
+ /// 线边库位
+ ///
+ [Display(Name = "线边库位Json集合")]
+ public string WipLocationCodeListJson { get; set; }
}
diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/ProductionLines/ProductionLine.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/ProductionLines/ProductionLine.cs
index 7276cfc46..b7888df0a 100644
--- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/ProductionLines/ProductionLine.cs
+++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/ProductionLines/ProductionLine.cs
@@ -1,6 +1,4 @@
-using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
-using Win_in.Sfs.Basedata.Domain.Shared;
using Win_in.Sfs.Shared.Domain;
using Win_in.Sfs.Shared.Domain.Entities;
@@ -14,11 +12,18 @@ public class ProductionLine : SfsBaseDataAggregateRootBase, IHasCode, IHasName
///
/// 代码
///
- [Display(Name = "代码")]
+ [Display(Name = "生产线代码")]
[Key]
[IgnoreUpdate]
public string Code { get; set; }
+ ///
+ /// 库位
+ ///
+ [Display(Name = "库位代码")]
+ [IgnoreUpdate]
+ public string LocationCode { get; set; }
+
///
/// 名称
///
@@ -30,27 +35,4 @@ public class ProductionLine : SfsBaseDataAggregateRootBase, IHasCode, IHasName
///
[Display(Name = "描述")]
public string Description { get; set; }
-
- ///
- /// 类型
- ///
- public EnumProductionLineType Type { get; set; }
-
- ///
- /// 原料库位
- ///
- [Display(Name = "原料库位Json集合")]
- public string RawLocationCodeListJson { get; set; }
-
- ///
- /// 成品库位
- ///
- [Display(Name = "完工库位Json集合")]
- public string ProductLocationCodeListJson { get; set; }
-
- ///
- /// 线边库位
- ///
- [Display(Name = "线边库位Json集合")]
- public string WipLocationCodeListJson { get; set; }
}
diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20240403083042_BaseData_ProductLine_BaseData_ProductLineItem.Designer.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20240403083042_BaseData_ProductLine_BaseData_ProductLineItem.Designer.cs
new file mode 100644
index 000000000..983447b63
--- /dev/null
+++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20240403083042_BaseData_ProductLine_BaseData_ProductLineItem.Designer.cs
@@ -0,0 +1,4237 @@
+//
+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("20240403083042_BaseData_ProductLine_BaseData_ProductLineItem")]
+ partial class BaseData_ProductLine_BaseData_ProductLineItem
+ {
+ 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(3072)
+ .HasColumnType("nvarchar(3072)")
+ .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", (string)null);
+ });
+
+ 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(3072)
+ .HasColumnType("nvarchar(3072)")
+ .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", (string)null);
+ });
+
+ 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(3072)
+ .HasColumnType("nvarchar(3072)")
+ .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", (string)null);
+ });
+
+ 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(3072)
+ .HasColumnType("nvarchar(3072)");
+
+ 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", (string)null);
+ });
+
+ 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(3072)
+ .HasColumnType("nvarchar(3072)")
+ .HasColumnName("Remark");
+
+ b.Property("TenantId")
+ .HasColumnType("uniqueidentifier")
+ .HasColumnName("TenantId");
+
+ b.HasKey("Id");
+
+ b.HasIndex("Code")
+ .IsUnique();
+
+ b.ToTable("Basedata_Category", (string)null);
+ });
+
+ 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(3072)
+ .HasColumnType("nvarchar(3072)")
+ .HasColumnName("Remark");
+
+ b.Property("TenantId")
+ .HasColumnType("uniqueidentifier")
+ .HasColumnName("TenantId");
+
+ b.HasKey("Id");
+
+ b.HasIndex("Code")
+ .IsUnique();
+
+ b.ToTable("Basedata_Currency", (string)null);
+ });
+
+ 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(3072)
+ .HasColumnType("nvarchar(3072)")
+ .HasColumnName("Remark");
+
+ b.Property("TenantId")
+ .HasColumnType("uniqueidentifier")
+ .HasColumnName("TenantId");
+
+ b.HasKey("Id");
+
+ b.HasIndex("CurrencyId", "BasicCurrencyId")
+ .IsUnique();
+
+ b.ToTable("Basedata_CurrencyExchange", (string)null);
+ });
+
+ 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(3072)
+ .HasColumnType("nvarchar(3072)")
+ .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", (string)null);
+ });
+
+ 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", (string)null);
+ });
+
+ 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(3072)
+ .HasColumnType("nvarchar(3072)")
+ .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", (string)null);
+ });
+
+ 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(3072)
+ .HasColumnType("nvarchar(3072)")
+ .HasColumnName("Remark");
+
+ b.Property("TenantId")
+ .HasColumnType("uniqueidentifier")
+ .HasColumnName("TenantId");
+
+ b.HasKey("Id");
+
+ b.HasIndex("Code")
+ .IsUnique();
+
+ b.ToTable("Basedata_Dict", (string)null);
+ });
+
+ 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(3072)
+ .HasColumnType("nvarchar(3072)")
+ .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", (string)null);
+ });
+
+ 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(3072)
+ .HasColumnType("nvarchar(3072)")
+ .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", (string)null);
+ });
+
+ 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(3072)
+ .HasColumnType("nvarchar(3072)")
+ .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", (string)null);
+ });
+
+ modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Equipment", 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("CreatTime")
+ .HasColumnType("datetime2");
+
+ b.Property("CreationTime")
+ .HasColumnType("datetime2")
+ .HasColumnName("CreationTime");
+
+ b.Property("Creator")
+ .HasColumnType("nvarchar(max)");
+
+ b.Property