diff --git a/ds-wms-service/DS.Module.Core/Constants/MultiLanguageConst.cs b/ds-wms-service/DS.Module.Core/Constants/MultiLanguageConst.cs index fae4b03f..49343ed1 100644 --- a/ds-wms-service/DS.Module.Core/Constants/MultiLanguageConst.cs +++ b/ds-wms-service/DS.Module.Core/Constants/MultiLanguageConst.cs @@ -258,6 +258,13 @@ public static class MultiLanguageConst public const string CodeFrtImportNoData = "Code_Frt_Import_No_Data"; [Description("存在已导入的付费方式")] public const string CodeFrtImportAlready = "Code_Frt_Import_Already"; + [Description("运输条款已存在")] + public const string CodeServiceExist = "Code_Service_Exist"; + [Description("运输条款导入无数据")] + public const string CodeServiceImportNoData = "Code_Service_Import_No_Data"; + [Description("存在已导入的运输条款")] + public const string CodeServiceImportAlready = "Code_Service_Import_Already"; + [Description("结算方式已存在")] public const string CodeStlModeExist = "Code_StlMode_Exist"; [Description("结算方式导入无数据")] diff --git a/ds-wms-service/DS.WMS.AdminApi/Controllers/CodeServiceController.cs b/ds-wms-service/DS.WMS.AdminApi/Controllers/CodeServiceController.cs new file mode 100644 index 00000000..84107322 --- /dev/null +++ b/ds-wms-service/DS.WMS.AdminApi/Controllers/CodeServiceController.cs @@ -0,0 +1,63 @@ +using DS.Module.Core; +using DS.WMS.Core.Code.Dtos; +using DS.WMS.Core.Code.Interface; +using DS.WMS.Core.System.Dtos; +using Microsoft.AspNetCore.Mvc; + +namespace DS.WMS.AdminApi.Controllers; + +/// +/// 运输条款服务 +/// +public class CodeServiceController : ApiController +{ + private readonly ICodeServiceService _invokeService; + + /// + /// 构造函数 + /// + /// + public CodeServiceController(ICodeServiceService invokeService) + { + _invokeService = invokeService; + } + + /// + /// 列表 + /// + /// + /// + [HttpPost] + [Route("GetCodeServiceList")] + public DataResult> GetCodeServiceList([FromBody] PageRequest request) + { + var res = _invokeService.GetListByPage(request); + return res; + } + + /// + /// 编辑 + /// + /// + /// + [HttpPost] + [Route("EditCodeService")] + public DataResult EditCodeService([FromBody] CodeServiceReq model) + { + var res = _invokeService.EditCodeService(model); + return res; + } + + /// + /// 详情 + /// + /// + /// + [HttpGet] + [Route("GetCodeServiceInfo")] + public DataResult GetCodeServiceInfo([FromQuery] string id) + { + var res = _invokeService.GetCodeServiceInfo(id); + return res; + } +} \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeCtnSelectRes.cs b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeCtnSelectRes.cs new file mode 100644 index 00000000..e23ac7da --- /dev/null +++ b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeCtnSelectRes.cs @@ -0,0 +1,57 @@ +using DS.Module.Core; + +namespace DS.WMS.Core.Code.Dtos; + +/// +/// 集装箱信息选择返回 +/// +public class CodeCtnSelectRes +{ + /// + /// 主键Id + /// + public long Id { get; set; } + /// + /// 集装箱尺寸 + /// + public string CtnSize { get; set; } = ""; + /// + /// 集装箱类型 + /// + public string CtnType { get; set; }= ""; + /// + /// 表现形式 + /// + public string CtnName { get; set; }= ""; + /// + /// EDI代码 + /// + public string EdiCode { get; set; }= ""; + /// + /// 箱皮重 + /// + public decimal CtnWeight { get; set; }= 0; + /// + /// 中文说明 + /// + public string CnExplain { get; set; }= ""; + /// + /// 英文说明 + /// + public string EnExplain { get; set; }= ""; + + /// + /// AFR代码 + /// + public string AfrCode { get; set; }= ""; + + /// + /// 默认限重 + /// + public decimal LimitWeight { get; set; } = 0; + /// + /// TEU + /// + public decimal TEU { get; set; }= 0; + +} \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeFormCopyReq.cs b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeFormCopyReq.cs index f458e74a..56d5d4c2 100644 --- a/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeFormCopyReq.cs +++ b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeFormCopyReq.cs @@ -17,7 +17,10 @@ public class CodeFormCopyReq /// 权限Id /// public long? PermissionId { get; set; } - + /// + /// 权限模块名称 + /// + public string PermissionName { get; set; } /// /// 字段复制设置 /// diff --git a/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeFormCopyRes.cs b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeFormCopyRes.cs index 63a3c414..5641e586 100644 --- a/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeFormCopyRes.cs +++ b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeFormCopyRes.cs @@ -16,7 +16,10 @@ public class CodeFormCopyRes /// 权限Id /// public long? PermissionId { get; set; } - + /// + /// 权限模块名称 + /// + public string PermissionName { get; set; } /// /// 字段设置 /// diff --git a/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeFormSetReq.cs b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeFormSetReq.cs index 0a8de48a..53b024e1 100644 --- a/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeFormSetReq.cs +++ b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeFormSetReq.cs @@ -17,7 +17,10 @@ public class CodeFormSetReq /// 权限Id /// public long? PermissionId { get; set; } - + /// + /// 权限模块名称 + /// + public string PermissionName { get; set; } /// /// 模板名称 /// diff --git a/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeFormSetRes.cs b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeFormSetRes.cs index df4361b8..2af2c34e 100644 --- a/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeFormSetRes.cs +++ b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeFormSetRes.cs @@ -16,7 +16,10 @@ public class CodeFormSetRes /// 权限Id /// public long? PermissionId { get; set; } - + /// + /// 权限模块名称 + /// + public string PermissionName { get; set; } /// /// 字段设置 /// diff --git a/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeFrtRes.cs b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeFrtRes.cs index d8dbc71e..2c847c73 100644 --- a/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeFrtRes.cs +++ b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeFrtRes.cs @@ -3,9 +3,9 @@ using DS.Module.Core; namespace DS.WMS.Core.Code.Dtos; /// -/// 结算方式信息返回 +/// 付费方式信息返回 /// -public class CodeVesselRes +public class CodeFrtRes { /// /// 主键Id diff --git a/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeFrtSelectRes.cs b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeFrtSelectRes.cs new file mode 100644 index 00000000..927f0566 --- /dev/null +++ b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeFrtSelectRes.cs @@ -0,0 +1,31 @@ +using DS.Module.Core; + +namespace DS.WMS.Core.Code.Dtos; + +/// +/// 付费方式信息返回 +/// +public class CodeFrtSelectRes +{ + /// + /// 主键Id + /// + public long Id { get; set; } + /// + /// 付费方式-英文名称 + /// + public string FrtName { get; set; } + /// + /// 中文名称 + /// + public string CnName { get; set; } + + /// + /// EDI代码 + /// + public string EdiCode { get; set; } + /// + /// 备注 + /// + public string Note { get; set; } = ""; +} \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/Code/Dtos/CodePackageSelectRes.cs b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodePackageSelectRes.cs new file mode 100644 index 00000000..95fc9a92 --- /dev/null +++ b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodePackageSelectRes.cs @@ -0,0 +1,30 @@ +using DS.Module.Core; + +namespace DS.WMS.Core.Code.Dtos; + +/// +/// 包装类型信息选择返回 +/// +public class CodePackageSelectRes +{ + /// + /// 主键Id + /// + public long Id { get; set; } + /// + /// 包装类型 + /// + public string PackageName { get; set; } + /// + /// 中文说明 + /// + public string CnExplain { get; set; } + /// + /// AFR代码 + /// + public string AfrCode { get; set; } + /// + /// EDI代码 + /// + public string EdiCode { get; set; } +} \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeServiceReq.cs b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeServiceReq.cs new file mode 100644 index 00000000..e3419e9e --- /dev/null +++ b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeServiceReq.cs @@ -0,0 +1,48 @@ +using DS.Module.Core; +using FluentValidation; + +namespace DS.WMS.Core.Code.Dtos; + +/// +/// 运输条款请求实体 +/// +public class CodeServiceReq +{ + /// + /// 主键Id + /// + public long Id { get; set; } + + /// + /// 运输条款-英文名称 + /// + public string ServiceName { get; set; }= ""; + /// + /// 中文名称 + /// + public string CnName { get; set; }= ""; + + /// + /// 状态 0 启用 1 禁用 + /// + public StatusEnum? Status { get; set; } = StatusEnum.Enable; + /// + /// 备注 + /// + public string Note { get; set; } = ""; +} + +/// +/// 验证 +/// +public class CodeServiceReqValidator : AbstractValidator +{ + /// + /// 构造函数 + /// + public CodeServiceReqValidator() + { + this.RuleFor(o => o.ServiceName) + .NotEmpty().WithName("运输条款-英文名称"); + } +} \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeServiceRes.cs b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeServiceRes.cs new file mode 100644 index 00000000..209cf8e6 --- /dev/null +++ b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeServiceRes.cs @@ -0,0 +1,36 @@ +using DS.Module.Core; + +namespace DS.WMS.Core.Code.Dtos; + +/// +/// 运输条款信息返回 +/// +public class CodeServiceRes +{ + /// + /// 主键Id + /// + public long Id { get; set; } + /// + /// 运输条款-英文名称 + /// + public string ServiceName { get; set; } + /// + /// 中文名称 + /// + public string CnName { get; set; } + + + /// + /// 状态 0 启用 1 禁用 + /// + public StatusEnum? Status { get; set; } = StatusEnum.Enable; + /// + /// 备注 + /// + public string Note { get; set; } = ""; + /// + /// 创建时间 + /// + public DateTime CreateTime { get; set; } +} \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeServiceSelectRes.cs b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeServiceSelectRes.cs new file mode 100644 index 00000000..eb3bf472 --- /dev/null +++ b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeServiceSelectRes.cs @@ -0,0 +1,28 @@ +using DS.Module.Core; + +namespace DS.WMS.Core.Code.Dtos; + +/// +/// 运输条款信息返回 +/// +public class CodeServiceSelectRes +{ + /// + /// 主键Id + /// + public long Id { get; set; } + /// + /// 运输条款-英文名称 + /// + public string ServiceName { get; set; } + /// + /// 中文名称 + /// + public string CnName { get; set; } + + + /// + /// 备注 + /// + public string Note { get; set; } = ""; +} \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeSourceDetailSelectRes.cs b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeSourceDetailSelectRes.cs new file mode 100644 index 00000000..d66dcc69 --- /dev/null +++ b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeSourceDetailSelectRes.cs @@ -0,0 +1,31 @@ +using DS.Module.Core; + +namespace DS.WMS.Core.Code.Dtos; + +/// +/// 业务来源明细信息选择返回 +/// +public class CodeSourceDetailSelectRes +{ + /// + /// 主键Id + /// + public long Id { get; set; } + /// + /// 业务来源Id + /// + public long SourceId { get; set; } + /// + /// 来源明细名称 + /// + public string DetailName { get; set; }= ""; + + /// + /// 英文名称 + /// + public string EnName { get; set; } = ""; + /// + /// 备注 + /// + public string Note { get; set; } = ""; +} \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeSourceSelectRes.cs b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeSourceSelectRes.cs new file mode 100644 index 00000000..ec8b1fdd --- /dev/null +++ b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeSourceSelectRes.cs @@ -0,0 +1,30 @@ +using DS.Module.Core; + +namespace DS.WMS.Core.Code.Dtos; + +/// +/// 业务来源信息选择返回 +/// +public class CodeSourceSelectRes +{ + /// + /// 主键Id + /// + public long Id { get; set; } + /// + /// 业务来源唯一代码 + /// + public string SourceCode { get; set; } + /// + /// 业务来源名称 + /// + public string SourceName { get; set; } + /// + /// 英文名称 + /// + public string EnName { get; set; } + /// + /// 备注 + /// + public string Note { get; set; } = ""; +} \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeStlModeSelectRes.cs b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeStlModeSelectRes.cs new file mode 100644 index 00000000..23bfb598 --- /dev/null +++ b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeStlModeSelectRes.cs @@ -0,0 +1,34 @@ +using DS.Module.Core; + +namespace DS.WMS.Core.Code.Dtos; + +/// +/// 结算方式选择返回 +/// +public class CodeStlModeSelectRes +{ + /// + /// 主键Id + /// + public long Id { get; set; } + /// + /// 结算方式唯一代码 + /// + public string StlCode { get; set; } + /// + /// 结算方式名称 + /// + public string StlName { get; set; } + /// + /// 英文名称 + /// + public string EnName { get; set; } + /// + /// 财务软件代码 + /// + public string FinanceSoftCode { get; set; } + /// + /// 备注 + /// + public string Note { get; set; } = ""; +} \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeVesselRes.cs b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeVesselRes.cs index c38dd50d..a6c940e3 100644 --- a/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeVesselRes.cs +++ b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeVesselRes.cs @@ -3,9 +3,9 @@ using DS.Module.Core; namespace DS.WMS.Core.Code.Dtos; /// -/// 付费方式返回 +/// 船名返回 /// -public class CodeFrtRes +public class CodeVesselRes { /// /// 主键Id @@ -14,7 +14,7 @@ public class CodeFrtRes /// /// 船名 /// - public string FrtName { get; set; } = ""; + public string VesselName { get; set; } = ""; /// /// 中文说明 /// diff --git a/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeVesselSelectRes.cs b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeVesselSelectRes.cs new file mode 100644 index 00000000..b4fb6415 --- /dev/null +++ b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeVesselSelectRes.cs @@ -0,0 +1,36 @@ +using DS.Module.Core; + +namespace DS.WMS.Core.Code.Dtos; + +/// +/// 船名选择返回 +/// +public class CodeVesselSelectRes +{ + /// + /// 主键Id + /// + public long Id { get; set; } + /// + /// 船名 + /// + public string VesselName { get; set; } = ""; + /// + /// 中文说明 + /// + public string CnName { get; set; }= ""; + /// + /// 船公司Id + /// + public long CarrierId { get; set; } + + /// + /// 船运代理 + /// + public string ShipAgency { get; set; }= ""; + + /// + /// EDI代码-船舶呼号 + /// + public string EdiCode { get; set; } = ""; +} \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeVoynoSelectRes.cs b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeVoynoSelectRes.cs new file mode 100644 index 00000000..395aa306 --- /dev/null +++ b/ds-wms-service/DS.WMS.Core/Code/Dtos/CodeVoynoSelectRes.cs @@ -0,0 +1,60 @@ +using DS.Module.Core; + +namespace DS.WMS.Core.Code.Dtos; + +/// +/// 航次信息选择返回 +/// +public class CodeVoynoSelectRes +{ + /// + /// 主键Id + /// + public long Id { get; set; } + /// + /// 船名Id + /// + public long VesselId { get; set; } + /// + /// 船名 + /// + public string VesselName { get; set; } + /// + /// 航次 + /// + public string VoyNo { get; set; } = ""; + /// + /// 装货港 + /// + public string LoadPort { get; set; }= ""; + /// + /// 中转港 + /// + public string EnterPort { get; set; }= ""; + /// + /// 卸货港 + /// + public string DischargePort { get; set; }= ""; + /// + /// 开船日期 + /// + public DateTime? ETD { get; set; } + + /// + /// 预抵日期 + /// + public DateTime? ETA { get; set; } + + /// + /// ATD + /// + public DateTime? ATD { get; set; } + /// + /// 截单时间 + /// + public DateTime? CloseDoDate { get; set; } + /// + /// 默认场站(码头)Id + /// + public long YardId { get; set; } +} \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/Code/Dtos/IssueTypeSelectRes.cs b/ds-wms-service/DS.WMS.Core/Code/Dtos/IssueTypeSelectRes.cs new file mode 100644 index 00000000..eb808bda --- /dev/null +++ b/ds-wms-service/DS.WMS.Core/Code/Dtos/IssueTypeSelectRes.cs @@ -0,0 +1,31 @@ +using DS.Module.Core; + +namespace DS.WMS.Core.Code.Dtos; + +/// +/// 签单方式信息选择返回 +/// +public class IssueTypeSelectRes +{ + /// + /// 主键Id + /// + public long Id { get; set; } + /// + /// 签单方式 + /// + public string BillType { get; set; } + /// + /// 英文名称 + /// + public string EnName { get; set; } + /// + /// 正本份数 + /// + public string NoBill { get; set; } + /// + /// 副本份数 + /// + public string CopyNoBill { get; set; } + +} \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/Code/Entity/CodeFormCopy.cs b/ds-wms-service/DS.WMS.Core/Code/Entity/CodeFormCopy.cs index 3fdded6b..59908b33 100644 --- a/ds-wms-service/DS.WMS.Core/Code/Entity/CodeFormCopy.cs +++ b/ds-wms-service/DS.WMS.Core/Code/Entity/CodeFormCopy.cs @@ -15,6 +15,11 @@ public class CodeFormCopy : BaseOrgModel /// [SugarColumn(ColumnDescription = "权限Id", IsNullable = false)] public long? PermissionId { get; set; } + /// + /// 权限模块名称 + /// + [SugarColumn(ColumnDescription = "权限模块名称", IsNullable = false,Length = 50)] + public string PermissionName { get; set; } /// /// 模板名称 diff --git a/ds-wms-service/DS.WMS.Core/Code/Entity/CodeFormSet.cs b/ds-wms-service/DS.WMS.Core/Code/Entity/CodeFormSet.cs index 72699b9b..0e00ba99 100644 --- a/ds-wms-service/DS.WMS.Core/Code/Entity/CodeFormSet.cs +++ b/ds-wms-service/DS.WMS.Core/Code/Entity/CodeFormSet.cs @@ -15,7 +15,11 @@ public class CodeFormSet : BaseOrgModel /// [SugarColumn(ColumnDescription = "权限Id", IsNullable = false)] public long? PermissionId { get; set; } - + /// + /// 权限模块名称 + /// + [SugarColumn(ColumnDescription = "权限模块名称", IsNullable = false,Length = 50)] + public string PermissionName { get; set; } /// /// 表单设置 /// diff --git a/ds-wms-service/DS.WMS.Core/Code/Entity/CodeService.cs b/ds-wms-service/DS.WMS.Core/Code/Entity/CodeService.cs new file mode 100644 index 00000000..f9524178 --- /dev/null +++ b/ds-wms-service/DS.WMS.Core/Code/Entity/CodeService.cs @@ -0,0 +1,29 @@ +using DS.Module.Core; +using DS.Module.Core.Data; +using SqlSugar; + +namespace DS.WMS.Core.Code.Entity; +/// +/// 运输条款表 +/// +[SqlSugar.SugarTable("op_code_service","运输条款表")] +public class CodeService: BaseModel +{ + /// + /// 运输条款-英文名称 + /// + [SugarColumn(ColumnDescription = "运输条款-英文名称", Length = 100)] + public string ServiceName { get; set; } + /// + /// 中文名称 + /// + [SugarColumn(ColumnDescription = "中文名称", Length = 50,IsNullable = true)] + public string CnName { get; set; } + + + /// + /// 状态 0启用 1禁用 + /// + [SugarColumn(ColumnDescription = "状态",DefaultValue = "0")] + public StatusEnum? Status { get; set; } = StatusEnum.Enable; +} \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/Code/Interface/ICodeServiceService.cs b/ds-wms-service/DS.WMS.Core/Code/Interface/ICodeServiceService.cs new file mode 100644 index 00000000..07cede1e --- /dev/null +++ b/ds-wms-service/DS.WMS.Core/Code/Interface/ICodeServiceService.cs @@ -0,0 +1,70 @@ +using DS.Module.Core; +using DS.Module.Core.Data; +using DS.WMS.Core.Code.Dtos; + +namespace DS.WMS.Core.Code.Interface; + +public interface ICodeServiceService +{ + /// + /// 列表 + /// + /// + /// + DataResult> GetListByPage(PageRequest request); + + + /// + /// 编辑 + /// + /// + /// + DataResult EditCodeService(CodeServiceReq req); + + /// + /// 获取详情 + /// + /// + /// + DataResult GetCodeServiceInfo(string id); + /// + /// 列表 + /// + /// + /// + DataResult> GetClientListByPage(PageRequest request); + /// + /// 编辑-客户端 + /// + /// + /// + DataResult EditClientCodeService(CodeServiceReq req); + /// + /// 获取详情 -客户端 + /// + /// + /// + public DataResult GetClientCodeServiceInfo(string id); + + + + /// + /// 获取运输条款列表-基础库 + /// + /// + /// + DataResult> GetCodeServiceList(PageRequest request); + /// + /// 导入运输条款列表 + /// + /// + /// + DataResult ImportCodeService(IdModel req); + + /// + /// 获取当前租户已有的运输条款 + /// + /// + public DataResult> GetExistCodeServiceList(); + +} \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/Code/Method/CodeFormCopyService.cs b/ds-wms-service/DS.WMS.Core/Code/Method/CodeFormCopyService.cs index 650a5e0d..193c8b42 100644 --- a/ds-wms-service/DS.WMS.Core/Code/Method/CodeFormCopyService.cs +++ b/ds-wms-service/DS.WMS.Core/Code/Method/CodeFormCopyService.cs @@ -40,10 +40,13 @@ public class CodeFormCopyService : IFormCopyService public DataResult> GetListByPage(PageRequest request) { var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + + var permissions = db.Queryable(); //序列化查询条件 var whereList = db.ConfigQuery.Context.Utilities.JsonToConditionalModels(request.QueryCondition); var data = tenantDb.Queryable() - .LeftJoin((a, b) => a.PermissionId == b.Id) + // .LeftJoin((a, b) => a.PermissionId == b.Id) + // .LeftJoin(saasService.GetMasterDb().Queryable().AsWithAttr(),(a, b) => a.PermissionId == b.Id) .Where(whereList) .Select().ToQueryPage(request.PageCondition); return data; @@ -91,7 +94,7 @@ public class CodeFormCopyService : IFormCopyService { var tenantDb = saasService.GetBizDbScopeById(user.TenantId); var data = tenantDb.Queryable() - .LeftJoin((a, b) => a.PermissionId == b.Id) + // .LeftJoin((a, b) => a.PermissionId == b.Id) .Where(x => x.Id == long.Parse(id)) .Select() .First(); diff --git a/ds-wms-service/DS.WMS.Core/Code/Method/CodeFormSetService.cs b/ds-wms-service/DS.WMS.Core/Code/Method/CodeFormSetService.cs index b61826ef..8c44c109 100644 --- a/ds-wms-service/DS.WMS.Core/Code/Method/CodeFormSetService.cs +++ b/ds-wms-service/DS.WMS.Core/Code/Method/CodeFormSetService.cs @@ -43,7 +43,6 @@ public class CodeFormSetService : IFormSetService //序列化查询条件 var whereList = db.ConfigQuery.Context.Utilities.JsonToConditionalModels(request.QueryCondition); var data = tenantDb.Queryable() - .LeftJoin((a, b) => a.PermissionId == b.Id) .Where(whereList) .Select().ToQueryPage(request.PageCondition); return data; @@ -91,7 +90,6 @@ public class CodeFormSetService : IFormSetService { var tenantDb = saasService.GetBizDbScopeById(user.TenantId); var data = tenantDb.Queryable() - .LeftJoin((a, b) => a.PermissionId == b.Id) .Where(x => x.Id == long.Parse(id)) .Select() .First(); diff --git a/ds-wms-service/DS.WMS.Core/Code/Method/CodeServiceService.cs b/ds-wms-service/DS.WMS.Core/Code/Method/CodeServiceService.cs new file mode 100644 index 00000000..08b3a4d8 --- /dev/null +++ b/ds-wms-service/DS.WMS.Core/Code/Method/CodeServiceService.cs @@ -0,0 +1,169 @@ +using DS.Module.Core; +using DS.Module.Core.Data; +using DS.Module.Core.Extensions; +using DS.Module.SqlSugar; +using DS.Module.UserModule; +using DS.WMS.Core.Code.Dtos; +using DS.WMS.Core.Code.Entity; +using DS.WMS.Core.Code.Interface; +using Mapster; +using Microsoft.Extensions.DependencyInjection; +using SqlSugar; + +namespace DS.WMS.Core.Code.Method; + +public class CodeServiceService:ICodeServiceService +{ + private readonly IServiceProvider _serviceProvider; + private readonly ISqlSugarClient db; + private readonly IUser user; + private readonly ISaasDbService saasService; + /// + /// + /// + /// + public CodeServiceService(IServiceProvider serviceProvider) + { + _serviceProvider = serviceProvider; + db = _serviceProvider.GetRequiredService(); + user = _serviceProvider.GetRequiredService(); + saasService = _serviceProvider.GetRequiredService(); + } + + public DataResult> GetListByPage(PageRequest request) + { + //序列化查询条件 + var whereList = db.ConfigQuery.Context.Utilities.JsonToConditionalModels(request.QueryCondition); + var data = db.Queryable() + .Where(whereList) + .Select().ToQueryPage(request.PageCondition); + return data; + } + + public DataResult EditCodeService(CodeServiceReq req) + { + if (req.Id == 0) + { + + if (db.Queryable().Where(x=>x.ServiceName == req.ServiceName.Trim()).Any()) + { + return DataResult.Failed("运输条款已存在!",MultiLanguageConst.CodeServiceExist); + } + + var data = req.Adapt(); + + var entity = db.Insertable(data).ExecuteReturnEntity(); + + return DataResult.Successed("添加成功!", entity.Id,MultiLanguageConst.DataCreateSuccess); + } + else + { + var info = db.Queryable().Where(x => x.Id == req.Id).First(); + + info = req.Adapt(info); + + db.Updateable(info).IgnoreColumns(ignoreAllNullColumns: true).EnableDiffLogEvent().ExecuteCommand(); + return DataResult.Successed("更新成功!",MultiLanguageConst.DataUpdateSuccess); + } + } + + public DataResult GetCodeServiceInfo(string id) + { + var data = db.Queryable() + .Where(a => a.Id == long.Parse(id)) + .Select() + .First(); + return DataResult.Success(data,MultiLanguageConst.DataQuerySuccess); + } + + public DataResult> GetClientListByPage(PageRequest request) + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + //序列化查询条件 + var whereList = db.ConfigQuery.Context.Utilities.JsonToConditionalModels(request.QueryCondition); + var data = tenantDb.Queryable() + .Where(whereList) + .Select().ToQueryPage(request.PageCondition); + return data; + } + + public DataResult EditClientCodeService(CodeServiceReq req) + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + if (req.Id == 0) + { + + if (tenantDb.Queryable().Where(x=>x.ServiceName == req.ServiceName.Trim()).Any()) + { + return DataResult.Failed("运输条款已存在!",MultiLanguageConst.CodeServiceExist); + } + + var data = req.Adapt(); + + var entity = tenantDb.Insertable(data).EnableDiffLogEvent().ExecuteReturnEntity(); + + return DataResult.Successed("添加成功!", entity.Id,MultiLanguageConst.DataCreateSuccess); + } + else + { + var info = tenantDb.Queryable().Where(x => x.Id == req.Id).First(); + + info = req.Adapt(info); + + tenantDb.Updateable(info).IgnoreColumns(ignoreAllNullColumns: true).ExecuteCommand(); + return DataResult.Successed("更新成功!",MultiLanguageConst.DataUpdateSuccess); + } + } + + public DataResult GetClientCodeServiceInfo(string id) + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .Where(a => a.Id == long.Parse(id)) + .Select() + .First(); + return DataResult.Success(data,MultiLanguageConst.DataQuerySuccess); + } + + public DataResult> GetCodeServiceList(PageRequest request) + { + //序列化查询条件 + var whereList = db.ConfigQuery.Context.Utilities.JsonToConditionalModels(request.QueryCondition); + var data = db.Queryable().Where(a=>a.Status == StatusEnum.Enable) + .Where(whereList) + .Select().ToQueryPage(request.PageCondition); + return data; + } + + public DataResult ImportCodeService(IdModel req) + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var list = db.Queryable().Where(x =>req.Ids.Contains(x.Id) ).ToList(); + if (list.Count == 0) + { + return DataResult.Failed("运输条款导入无数据!",MultiLanguageConst.CodeServiceImportNoData); + } + + if (tenantDb.Queryable().Where(x =>req.Ids.Contains(x.Id) ).Any()) + { + return DataResult.Failed("存在已导入的运输条款!",MultiLanguageConst.CodeServiceImportAlready); + } + + tenantDb.Insertable(list).ExecuteCommand(); + return DataResult.Successed("引入成功!",MultiLanguageConst.DataImportSuccess); + } + + /// + /// 获取当前租户已有的运输条款 + /// + /// + public DataResult> GetExistCodeServiceList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .Select(n=>n.Id.ToString()) + .ToList(); + return DataResult>.Success(data); + } + +} \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/Info/Dtos/ClientSelectRes.cs b/ds-wms-service/DS.WMS.Core/Info/Dtos/ClientSelectRes.cs new file mode 100644 index 00000000..30e0293c --- /dev/null +++ b/ds-wms-service/DS.WMS.Core/Info/Dtos/ClientSelectRes.cs @@ -0,0 +1,30 @@ +namespace DS.WMS.Core.Info.Dtos; + +/// +/// 客户下拉实体 +/// +public class ClientSelectRes +{ + /// + /// 主键Id + /// + public long Id { get; set; } + + + /// + /// Desc:客户代码 + /// + public string CodeName { get; set; } + + /// + /// Desc:客户简称 + /// + public string ShortName { get; set; } + + + /// + /// Desc:英文简称 + /// + public string EnShortName { get; set; } + +} \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/Sea/Dtos/SeaExportReq.cs b/ds-wms-service/DS.WMS.Core/Sea/Dtos/SeaExportReq.cs index eed75732..3f3f48d2 100644 --- a/ds-wms-service/DS.WMS.Core/Sea/Dtos/SeaExportReq.cs +++ b/ds-wms-service/DS.WMS.Core/Sea/Dtos/SeaExportReq.cs @@ -51,7 +51,7 @@ public class SeaExportReq /// /// 财务日期 /// - public DateTime AccountDate { get; set; } = DateTime.Now; + public string AccountDate { get; set; } /// /// 主提单号 @@ -967,8 +967,7 @@ public class SeaExportReq /// 备注 /// public string Note { get; set; } = ""; - - + } /// diff --git a/ds-wms-service/DS.WMS.Core/Sea/Dtos/SeaExportRes.cs b/ds-wms-service/DS.WMS.Core/Sea/Dtos/SeaExportRes.cs index b7730ec5..2f009c71 100644 --- a/ds-wms-service/DS.WMS.Core/Sea/Dtos/SeaExportRes.cs +++ b/ds-wms-service/DS.WMS.Core/Sea/Dtos/SeaExportRes.cs @@ -50,7 +50,7 @@ public class SeaExportRes /// /// 财务日期 /// - public DateTime AccountDate { get; set; } = DateTime.Now; + public string AccountDate { get; set; } /// /// 主提单号 @@ -972,4 +972,17 @@ public class SeaExportRes /// 创建时间 /// public DateTime CreateTime { get; set; } + + + + /// + /// Desc:提单签发状态 + /// + public int BLIssueStatus { get; set; } + + /// + /// Desc:整票提交状态 + /// + public int BillSubmitStatus { get; set; } + } \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/Sea/Entity/SeaExport.cs b/ds-wms-service/DS.WMS.Core/Sea/Entity/SeaExport.cs index 1f6a8150..c1289853 100644 --- a/ds-wms-service/DS.WMS.Core/Sea/Entity/SeaExport.cs +++ b/ds-wms-service/DS.WMS.Core/Sea/Entity/SeaExport.cs @@ -54,8 +54,8 @@ public class SeaExport : BaseOrgModel /// /// 财务日期 /// - [SqlSugar.SugarColumn(ColumnDescription = "财务日期", IsNullable = false, Length = 7)] - public DateTime AccountDate { get; set; } = DateTime.Now; + [SqlSugar.SugarColumn(ColumnDescription = "财务日期", IsNullable = false,Length = 7)] + public string AccountDate { get; set; } /// /// 主提单号 @@ -319,13 +319,13 @@ public class SeaExport : BaseOrgModel /// /// 唛头 N/M /// - [SugarColumn(ColumnDescription = "唛头", IsNullable = true, Length = 3000)] + [SugarColumn(ColumnDescription = "唛头", IsNullable = true, ColumnDataType=StaticConfig.CodeFirst_BigString)] public string Marks { get; set; } /// /// 箱号封号 /// - [SugarColumn(ColumnDescription = "箱号封号", IsNullable = true, Length = 4000)] + [SugarColumn(ColumnDescription = "箱号封号", IsNullable = true, ColumnDataType=StaticConfig.CodeFirst_BigString)] public string CntrSealNo { get; set; } /// @@ -337,7 +337,7 @@ public class SeaExport : BaseOrgModel /// /// 货物描述 /// - [SugarColumn(ColumnDescription = "货物描述", IsNullable = true, Length = 2000)] + [SugarColumn(ColumnDescription = "货物描述", IsNullable = true, ColumnDataType=StaticConfig.CodeFirst_BigString)] public string Description { get; set; } /// @@ -662,7 +662,7 @@ public class SeaExport : BaseOrgModel /// /// Desc:备注 /// - [SugarColumn(ColumnDescription = "备注", IsNullable = true, Length = 4000)] + [SugarColumn(ColumnDescription = "备注", IsNullable = true, ColumnDataType=StaticConfig.CodeFirst_BigString)] public string Remark { get; set; } /// @@ -1174,4 +1174,21 @@ public class SeaExport : BaseOrgModel /// [SugarColumn(ColumnDescription = "", IsNullable = true, DefaultValue = "0")] public int WarnCount { get; set; } = 0; + + + + + /// + /// Desc:提单签发状态 + /// + [SugarColumn(ColumnDescription = "提单签发状态", IsNullable = true, DefaultValue = "0")] + public int BLIssueStatus { get; set; } + + /// + /// Desc:整票提交状态 + /// + [SugarColumn(ColumnDescription = "整票提交状态", IsNullable = true, DefaultValue = "0")] + public int BillSubmitStatus { get; set; } + + } \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/System/Dtos/DeptSelectRes.cs b/ds-wms-service/DS.WMS.Core/System/Dtos/DeptSelectRes.cs new file mode 100644 index 00000000..b70cb9b8 --- /dev/null +++ b/ds-wms-service/DS.WMS.Core/System/Dtos/DeptSelectRes.cs @@ -0,0 +1,18 @@ +namespace DS.WMS.Core.System.Dtos; + +/// +/// 部门选择 +/// +public class DeptSelectRes +{ + /// + /// 主键Id + /// + public long Id { get; set; } + + + /// + /// 机构名称 + /// + public string OrgName { get; set; } +} \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/System/Dtos/UserReq.cs b/ds-wms-service/DS.WMS.Core/System/Dtos/UserReq.cs index 7baa243f..7759c602 100644 --- a/ds-wms-service/DS.WMS.Core/System/Dtos/UserReq.cs +++ b/ds-wms-service/DS.WMS.Core/System/Dtos/UserReq.cs @@ -90,6 +90,53 @@ public class UserReq /// 用戶机构 /// public long?[] OrgIds { get; set; } + + /// + /// 是否操作 + /// + public bool IsOperator { get; set; } = false; + + /// + /// 是否单证 + /// + public bool IsVouchingClerk { get; set; } = false; + + /// + /// 是否销售 + /// + public bool IsSale { get; set; } = false; + + /// + /// 是否报关员 + /// + public bool IsCustom { get; set; } = false; + + /// + /// 是否财务 + /// + public bool IsFinancialStaff { get; set; } = false; + /// + /// 是否客服 + /// + public bool IsCustomerService { get; set; } = false; + /// + /// 是否司机 + /// + public bool IsDriver { get; set; } = false; + /// + /// 是否派车调度人员 + /// + public bool IsDispatcher { get; set; } = false; + + /// + /// 默认部门Id + /// + public long DeptId { get; set; } = 0; + + /// + /// 默认机构Id + /// + public long DefaultOrgId { get; set; } = 0; } /// diff --git a/ds-wms-service/DS.WMS.Core/System/Dtos/UserSelectRes.cs b/ds-wms-service/DS.WMS.Core/System/Dtos/UserSelectRes.cs new file mode 100644 index 00000000..bb8a423a --- /dev/null +++ b/ds-wms-service/DS.WMS.Core/System/Dtos/UserSelectRes.cs @@ -0,0 +1,22 @@ +namespace DS.WMS.Core.System.Dtos; + +/// +/// 用户下拉选择 +/// +public class UserSelectRes +{ + /// + /// 主键Id + /// + public long Id { get; set; } + /// + /// 登陆账号 + /// + public string UserCode { get; set; } + + + /// + ///姓名 + /// + public string UserName { get; set; } +} \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/System/Dtos/UserViewModel.cs b/ds-wms-service/DS.WMS.Core/System/Dtos/UserViewModel.cs index 958b6703..565f6477 100644 --- a/ds-wms-service/DS.WMS.Core/System/Dtos/UserViewModel.cs +++ b/ds-wms-service/DS.WMS.Core/System/Dtos/UserViewModel.cs @@ -99,4 +99,49 @@ public class UserViewModel /// public long?[] OrgIds { get; set; } // public string[] RoleIds { get; set; } + + /// + /// 是否操作 + /// + public bool IsOperator { get; set; } = false; + + /// + /// 是否单证 + /// + public bool IsVouchingClerk { get; set; } = false; + + /// + /// 是否销售 + /// + public bool IsSale { get; set; } = false; + + /// + /// 是否报关员 + /// + public bool IsCustom { get; set; } = false; + + /// + /// 是否财务 + /// + public bool IsFinancialStaff { get; set; } = false; + /// + /// 是否客服 + /// + public bool IsCustomerService { get; set; } = false; + /// + /// 是否司机 + /// + public bool IsDriver { get; set; } = false; + /// + /// 是否派车调度人员 + /// + public bool IsDispatcher { get; set; } = false; + /// + /// 默认部门Id + /// + public long DeptId { get; set; } + /// + /// 默认机构Id + /// + public long DefaultOrgId { get; set; } } \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/System/Entity/SysUser.cs b/ds-wms-service/DS.WMS.Core/System/Entity/SysUser.cs index aa718479..35e198c1 100644 --- a/ds-wms-service/DS.WMS.Core/System/Entity/SysUser.cs +++ b/ds-wms-service/DS.WMS.Core/System/Entity/SysUser.cs @@ -111,15 +111,67 @@ public class SysUser : UserTenantModel [Description("公司Id")] public string CompanyId { get; set; } + /// - /// ClientId + /// 默认机构Id /// - [Description("客户Id")] - public string ClientId { get; set; } + [Description("默认机构Id")] + public long DefaultOrgId { get; set; } + /// + /// DeptId + /// + [Description("默认部门Id")] + public long DeptId { get; set; } /// /// 是否限制客户 /// [Description("是否限制客户")] public bool IsLimitClient { get; set; } + + /// + /// 是否操作 + /// + [Description("是否操作")] + public bool IsOperator { get; set; } = false; + + /// + /// 是否单证 + /// + [Description("是否单证")] + public bool IsVouchingClerk { get; set; } = false; + + /// + /// 是否销售 + /// + [Description("是否销售")] + public bool IsSale { get; set; } = false; + + /// + /// 是否报关员 + /// + [Description("是否报关员")] + public bool IsCustom { get; set; } = false; + + /// + /// 是否财务 + /// + [Description("是否财务")] + public bool IsFinancialStaff { get; set; } = false; + /// + /// 是否客服 + /// + [Description("是否客服")] + public bool IsCustomerService { get; set; } = false; + /// + /// 是否司机 + /// + [Description("是否司机")] + public bool IsDriver { get; set; } = false; + /// + /// 是否派车调度人员 + /// + [Description("是否派车调度人员")] + public bool IsDispatcher { get; set; } = false; + } \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/System/Interface/IClientCommonService.cs b/ds-wms-service/DS.WMS.Core/System/Interface/IClientCommonService.cs new file mode 100644 index 00000000..7bf31a04 --- /dev/null +++ b/ds-wms-service/DS.WMS.Core/System/Interface/IClientCommonService.cs @@ -0,0 +1,228 @@ +using DS.Module.Core; +using DS.Module.Core.Extensions; +using DS.WMS.Core.Code.Dtos; +using DS.WMS.Core.Info.Dtos; +using DS.WMS.Core.System.Dtos; +using DS.WMS.Core.System.Entity; +using SqlSugar; + +namespace DS.WMS.Core.System.Interface; +/// +/// +/// +public interface IClientCommonService +{ + + /// + /// 获取船公司下拉列表 + /// + /// + public DataResult> GetCarrierClientList(); + + /// + /// 获取场站下拉列表 + /// + /// + public DataResult> GetYardClientList(); + + /// + /// 获取订舱公司下拉列表 + /// + /// + public DataResult> GetBookingClientList(); + + /// + /// 获取车队下拉列表 + /// + /// + public DataResult> GetTruckClientList(); + + /// + /// 获取委托单位下拉列表 + /// + /// + public DataResult> GetControllerClientList(); + + /// + /// 获取报关行下拉列表 + /// + /// + public DataResult> GetCustomClientList(); + + /// + /// 获取代理(国外)下拉列表 + /// + /// + public DataResult> GetAgentClientList(); + + /// + /// 获取代理(国内)下拉列表 + /// + /// + public DataResult> GetAgentCnClientList(); + + /// + /// 获取快递公司下拉列表 + /// + /// + public DataResult> GetExpressClientList(); + + /// + /// 获取航空公司下拉列表 + /// + /// + public DataResult> GetAirLinesClientList(); + + /// + /// 获取发货人下拉列表 + /// + /// + public DataResult> GetShipperClientList(); + + /// + /// 获取收货人下拉列表 + /// + /// + public DataResult> GetConsigneeClientList(); + + /// + /// 获取通知人下拉列表 + /// + /// + public DataResult> GetNotifyPartyClientList(); + + /// + /// 获取仓库下拉列表 + /// + /// + public DataResult> GetWareHouseClientList(); + + /// + /// 获取码头下拉列表 + /// + /// + public DataResult> GetWharfClientList(); + + /// + /// 获取保险公司下拉列表 + /// + /// + public DataResult> GetInsurerClientList(); + + /// + /// 获取租箱公司下拉列表 + /// + /// + public DataResult> GetLeasingClientList(); + + /// + /// 获取贸易代理下拉列表 + /// + /// + public DataResult> GetTradingAgencyClientList(); + + /// + /// 获取船代下拉列表 + /// + /// + public DataResult> GetShipAgencyClientList(); + + /// + /// 获取经营单位下拉列表 + /// + /// + public DataResult> GetEnterpriseClientList(); + + + + /// + /// 获取部门列表 + /// + /// 机构id + /// + public DataResult> GetDeptList(string orgId = ""); + + /// + /// 获取操作员列表 + /// + /// + public DataResult> GetOperatorUserList(); + + /// + /// 获取单证员列表 + /// + /// + public DataResult> GetVouchingClerkList(); + + /// + /// 获取销售员列表 + /// + /// + public DataResult> GetSaleUserList(); + + /// + /// 获取报关员列表 + /// + /// + public DataResult> GetCustomUserList(); + + /// + /// 获取财务员列表 + /// + /// + public DataResult> GetFinancialStaffList(); + + /// + /// 获取客服列表 + /// + /// + public DataResult> GetCustomerServiceList(); + + /// + /// 获取司机列表 + /// + /// + public DataResult> GetDiverList(); + + /// + /// 获取派车调度人员列表 + /// + /// + public DataResult> GetDispatcherList(); + + /// + /// 获取签单方式下拉列表 + /// + /// + public DataResult> GetIssueTypeSelectList(); + + /// + /// 获取集装箱下拉列表 + /// + /// + public DataResult> GetCtnSelectList(); + + /// + /// 获取包装类型下拉列表 + /// + /// + public DataResult> GetPackageSelectList(); + + /// + /// 获取船名下拉列表 + /// + /// + public DataResult> GetVesselSelectList(); + + /// + /// 获取航次下拉列表 + /// + /// + public DataResult> GetVoynoSelectList(); + + /// + /// 获取运输条款下拉列表 + /// + /// + public DataResult> GetServiceSelectList(); +} \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/System/Interface/ICommonService.cs b/ds-wms-service/DS.WMS.Core/System/Interface/ICommonService.cs index eb44ab61..5e9a4d6a 100644 --- a/ds-wms-service/DS.WMS.Core/System/Interface/ICommonService.cs +++ b/ds-wms-service/DS.WMS.Core/System/Interface/ICommonService.cs @@ -216,5 +216,28 @@ public interface ICommonService /// /// public DataResult> GetClientPortSelectList(); + + /// + /// 获取付费方式下拉列表-客户端 + /// + /// + public DataResult> GetClientFrtSelectList(); + + /// + /// 获取结算方式下拉列表-客户端 + /// + /// + public DataResult> GetClientStlModeSelectList(); + /// + /// 获取业务来源下拉列表-客户端 + /// + /// + public DataResult> GetClientSourceSelectList(); + + /// + /// 获取业务来源明细下拉列表-客户端 + /// + /// + public DataResult> GetClientSourceDetailSelectList(string id); } \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/System/Method/ClientCommonService.cs b/ds-wms-service/DS.WMS.Core/System/Method/ClientCommonService.cs new file mode 100644 index 00000000..26fa6dc7 --- /dev/null +++ b/ds-wms-service/DS.WMS.Core/System/Method/ClientCommonService.cs @@ -0,0 +1,684 @@ +using DS.Module.Core; +using DS.Module.Core.Extensions; +using DS.Module.SqlSugar; +using DS.Module.UserModule; +using DS.WMS.Core.Code.Dtos; +using DS.WMS.Core.Code.Entity; +using DS.WMS.Core.Info.Dtos; +using DS.WMS.Core.Info.Entity; +using DS.WMS.Core.System.Dtos; +using DS.WMS.Core.System.Entity; +using DS.WMS.Core.System.Interface; +using Microsoft.Extensions.DependencyInjection; +using SqlSugar; + +namespace DS.WMS.Core.System.Method; + +public class ClientCommonService : IClientCommonService +{ + private readonly IServiceProvider _serviceProvider; + private readonly ISqlSugarClient db; + private readonly IUser user; + private readonly ISaasDbService saasService; + + /// + /// + /// + /// + public ClientCommonService(IServiceProvider serviceProvider) + { + _serviceProvider = serviceProvider; + db = _serviceProvider.GetRequiredService(); + user = _serviceProvider.GetRequiredService(); + saasService = _serviceProvider.GetRequiredService(); + } + + /// + /// 获取船公司下拉列表 + /// + /// + public DataResult> GetCarrierClientList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .InnerJoin((a, b) => a.Id == b.ClientId) + .Where((a, b) => a.Status == StatusEnum.Enable.ToEnumInt() && b.IsCarrier == true) + .Select((a, b) => new ClientSelectRes + { + Id = a.Id, + CodeName = a.CodeName, + ShortName = a.ShortName, + EnShortName = a.EnShortName + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取场站下拉列表 + /// + /// + public DataResult> GetYardClientList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .InnerJoin((a, b) => a.Id == b.ClientId) + .Where((a, b) => a.Status == StatusEnum.Enable.ToEnumInt() && b.IsYard == true) + .Select((a, b) => new ClientSelectRes + { + Id = a.Id, + CodeName = a.CodeName, + ShortName = a.ShortName, + EnShortName = a.EnShortName + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取订舱公司下拉列表 + /// + /// + public DataResult> GetBookingClientList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .InnerJoin((a, b) => a.Id == b.ClientId) + .Where((a, b) => a.Status == StatusEnum.Enable.ToEnumInt() && b.IsBooking == true) + .Select((a, b) => new ClientSelectRes + { + Id = a.Id, + CodeName = a.CodeName, + ShortName = a.ShortName, + EnShortName = a.EnShortName + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取车队下拉列表 + /// + /// + public DataResult> GetTruckClientList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .InnerJoin((a, b) => a.Id == b.ClientId) + .Where((a, b) => a.Status == StatusEnum.Enable.ToEnumInt() && b.IsTruck == true) + .Select((a, b) => new ClientSelectRes + { + Id = a.Id, + CodeName = a.CodeName, + ShortName = a.ShortName, + EnShortName = a.EnShortName + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取委托单位下拉列表 + /// + /// + public DataResult> GetControllerClientList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .InnerJoin((a, b) => a.Id == b.ClientId) + .Where((a, b) => a.Status == StatusEnum.Enable.ToEnumInt() && b.IsController == true) + .Select((a, b) => new ClientSelectRes + { + Id = a.Id, + CodeName = a.CodeName, + ShortName = a.ShortName, + EnShortName = a.EnShortName + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取报关行下拉列表 + /// + /// + public DataResult> GetCustomClientList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .InnerJoin((a, b) => a.Id == b.ClientId) + .Where((a, b) => a.Status == StatusEnum.Enable.ToEnumInt() && b.IsCustom == true) + .Select((a, b) => new ClientSelectRes + { + Id = a.Id, + CodeName = a.CodeName, + ShortName = a.ShortName, + EnShortName = a.EnShortName + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取代理(国外)下拉列表 + /// + /// + public DataResult> GetAgentClientList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .InnerJoin((a, b) => a.Id == b.ClientId) + .Where((a, b) => a.Status == StatusEnum.Enable.ToEnumInt() && b.IsAgent == true) + .Select((a, b) => new ClientSelectRes + { + Id = a.Id, + CodeName = a.CodeName, + ShortName = a.ShortName, + EnShortName = a.EnShortName + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取代理(国内)下拉列表 + /// + /// + public DataResult> GetAgentCnClientList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .InnerJoin((a, b) => a.Id == b.ClientId) + .Where((a, b) => a.Status == StatusEnum.Enable.ToEnumInt() && b.IsAgentCn == true) + .Select((a, b) => new ClientSelectRes + { + Id = a.Id, + CodeName = a.CodeName, + ShortName = a.ShortName, + EnShortName = a.EnShortName + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取快递公司下拉列表 + /// + /// + public DataResult> GetExpressClientList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .InnerJoin((a, b) => a.Id == b.ClientId) + .Where((a, b) => a.Status == StatusEnum.Enable.ToEnumInt() && b.IsExpress == true) + .Select((a, b) => new ClientSelectRes + { + Id = a.Id, + CodeName = a.CodeName, + ShortName = a.ShortName, + EnShortName = a.EnShortName + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取航空公司下拉列表 + /// + /// + public DataResult> GetAirLinesClientList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .InnerJoin((a, b) => a.Id == b.ClientId) + .Where((a, b) => a.Status == StatusEnum.Enable.ToEnumInt() && b.IsAirLines == true) + .Select((a, b) => new ClientSelectRes + { + Id = a.Id, + CodeName = a.CodeName, + ShortName = a.ShortName, + EnShortName = a.EnShortName + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取发货人下拉列表 + /// + /// + public DataResult> GetShipperClientList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .InnerJoin((a, b) => a.Id == b.ClientId) + .Where((a, b) => a.Status == StatusEnum.Enable.ToEnumInt() && b.IsShipper == true) + .Select((a, b) => new ClientSelectRes + { + Id = a.Id, + CodeName = a.CodeName, + ShortName = a.ShortName, + EnShortName = a.EnShortName + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取收货人下拉列表 + /// + /// + public DataResult> GetConsigneeClientList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .InnerJoin((a, b) => a.Id == b.ClientId) + .Where((a, b) => a.Status == StatusEnum.Enable.ToEnumInt() && b.IsConsignee == true) + .Select((a, b) => new ClientSelectRes + { + Id = a.Id, + CodeName = a.CodeName, + ShortName = a.ShortName, + EnShortName = a.EnShortName + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取通知人下拉列表 + /// + /// + public DataResult> GetNotifyPartyClientList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .InnerJoin((a, b) => a.Id == b.ClientId) + .Where((a, b) => a.Status == StatusEnum.Enable.ToEnumInt() && b.IsNotifyParty == true) + .Select((a, b) => new ClientSelectRes + { + Id = a.Id, + CodeName = a.CodeName, + ShortName = a.ShortName, + EnShortName = a.EnShortName + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取仓库下拉列表 + /// + /// + public DataResult> GetWareHouseClientList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .InnerJoin((a, b) => a.Id == b.ClientId) + .Where((a, b) => a.Status == StatusEnum.Enable.ToEnumInt() && b.IsWareHouse == true) + .Select((a, b) => new ClientSelectRes + { + Id = a.Id, + CodeName = a.CodeName, + ShortName = a.ShortName, + EnShortName = a.EnShortName + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取码头下拉列表 + /// + /// + public DataResult> GetWharfClientList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .InnerJoin((a, b) => a.Id == b.ClientId) + .Where((a, b) => a.Status == StatusEnum.Enable.ToEnumInt() && b.IsWharf == true) + .Select((a, b) => new ClientSelectRes + { + Id = a.Id, + CodeName = a.CodeName, + ShortName = a.ShortName, + EnShortName = a.EnShortName + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取保险公司下拉列表 + /// + /// + public DataResult> GetInsurerClientList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .InnerJoin((a, b) => a.Id == b.ClientId) + .Where((a, b) => a.Status == StatusEnum.Enable.ToEnumInt() && b.IsInsurer == true) + .Select((a, b) => new ClientSelectRes + { + Id = a.Id, + CodeName = a.CodeName, + ShortName = a.ShortName, + EnShortName = a.EnShortName + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取租箱公司下拉列表 + /// + /// + public DataResult> GetLeasingClientList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .InnerJoin((a, b) => a.Id == b.ClientId) + .Where((a, b) => a.Status == StatusEnum.Enable.ToEnumInt() && b.IsLeasing == true) + .Select((a, b) => new ClientSelectRes + { + Id = a.Id, + CodeName = a.CodeName, + ShortName = a.ShortName, + EnShortName = a.EnShortName + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取贸易代理下拉列表 + /// + /// + public DataResult> GetTradingAgencyClientList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .InnerJoin((a, b) => a.Id == b.ClientId) + .Where((a, b) => a.Status == StatusEnum.Enable.ToEnumInt() && b.IsTradingAgency == true) + .Select((a, b) => new ClientSelectRes + { + Id = a.Id, + CodeName = a.CodeName, + ShortName = a.ShortName, + EnShortName = a.EnShortName + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取船代下拉列表 + /// + /// + public DataResult> GetShipAgencyClientList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .InnerJoin((a, b) => a.Id == b.ClientId) + .Where((a, b) => a.Status == StatusEnum.Enable.ToEnumInt() && b.IsShipAgency == true) + .Select((a, b) => new ClientSelectRes + { + Id = a.Id, + CodeName = a.CodeName, + ShortName = a.ShortName, + EnShortName = a.EnShortName + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取经营单位下拉列表 + /// + /// + public DataResult> GetEnterpriseClientList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .InnerJoin((a, b) => a.Id == b.ClientId) + .Where((a, b) => a.Status == StatusEnum.Enable.ToEnumInt() && b.IsEnterprise == true) + .Select((a, b) => new ClientSelectRes + { + Id = a.Id, + CodeName = a.CodeName, + ShortName = a.ShortName, + EnShortName = a.EnShortName + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取签单方式下拉列表 + /// + /// + public DataResult> GetIssueTypeSelectList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .Where(a => a.Status == StatusEnum.Enable.ToEnumInt()) + .Select().ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + /// + /// 获取集装箱下拉列表 + /// + /// + public DataResult> GetCtnSelectList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .Where(a => a.Status == StatusEnum.Enable) + .Select().ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取包装类型下拉列表 + /// + /// + public DataResult> GetPackageSelectList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .Where(a => a.Status == StatusEnum.Enable) + .Select().ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + /// + /// 获取船名下拉列表 + /// + /// + public DataResult> GetVesselSelectList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .Where(a => a.Status == StatusEnum.Enable) + .Select().ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + /// + /// 获取航次下拉列表 + /// + /// + public DataResult> GetVoynoSelectList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .Where(a => a.Status == StatusEnum.Enable) + .Select().ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + /// + /// 获取运输条款下拉列表 + /// + /// + public DataResult> GetServiceSelectList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var data = tenantDb.Queryable() + .Where(a => a.Status == StatusEnum.Enable) + .Select().ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + /// + /// 获取部门列表 + /// + /// 机构id + /// + public DataResult> GetDeptList(string orgId = "") + { + var list = db.Queryable() + .WhereIF(orgId.IsNotEmptyOrNull(), a => a.ParentId == long.Parse(orgId)) + .Where(a => a.Status == StatusEnum.Enable && a.IsDepartment == true) + .Select() + .ToList(); + return DataResult>.Success("获取数据成功!", list); + } + /// + /// 获取操作员列表 + /// + /// + public DataResult> GetOperatorUserList() + { + var data = db.Queryable() + .Where(a => a.Status == StatusEnum.Enable.ToEnumInt() && a.IsOperator == true) + .Select(a => new UserSelectRes + { + Id = a.Id, + UserCode= a.UserCode, + UserName = a.UserName, + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取单证员列表 + /// + /// + public DataResult> GetVouchingClerkList() + { + var data = db.Queryable() + .Where(a => a.Status == StatusEnum.Enable.ToEnumInt() && a.IsVouchingClerk == true) + .Select(a => new UserSelectRes + { + Id = a.Id, + UserCode= a.UserCode, + UserName = a.UserName, + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + /// + /// 获取销售员列表 + /// + /// + public DataResult> GetSaleUserList() + { + var data = db.Queryable() + .Where(a => a.Status == StatusEnum.Enable.ToEnumInt() && a.IsSale == true) + .Select(a => new UserSelectRes + { + Id = a.Id, + UserCode= a.UserCode, + UserName = a.UserName, + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取报关员列表 + /// + /// + public DataResult> GetCustomUserList() + { + var data = db.Queryable() + .Where(a => a.Status == StatusEnum.Enable.ToEnumInt() && a.IsCustom == true) + .Select(a => new UserSelectRes + { + Id = a.Id, + UserCode= a.UserCode, + UserName = a.UserName, + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取财务员列表 + /// + /// + public DataResult> GetFinancialStaffList() + { + var data = db.Queryable() + .Where(a => a.Status == StatusEnum.Enable.ToEnumInt() && a.IsFinancialStaff == true) + .Select(a => new UserSelectRes + { + Id = a.Id, + UserCode= a.UserCode, + UserName = a.UserName, + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取客服列表 + /// + /// + public DataResult> GetCustomerServiceList() + { + var data = db.Queryable() + .Where(a => a.Status == StatusEnum.Enable.ToEnumInt() && a.IsCustomerService == true) + .Select(a => new UserSelectRes + { + Id = a.Id, + UserCode= a.UserCode, + UserName = a.UserName, + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + + /// + /// 获取司机列表 + /// + /// + public DataResult> GetDiverList() + { + var data = db.Queryable() + .Where(a => a.Status == StatusEnum.Enable.ToEnumInt() && a.IsDriver == true) + .Select(a => new UserSelectRes + { + Id = a.Id, + UserCode= a.UserCode, + UserName = a.UserName, + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } + /// + /// 获取派车调度人员列表 + /// + /// + public DataResult> GetDispatcherList() + { + var data = db.Queryable() + .Where(a => a.Status == StatusEnum.Enable.ToEnumInt() && a.IsDispatcher == true) + .Select(a => new UserSelectRes + { + Id = a.Id, + UserCode= a.UserCode, + UserName = a.UserName, + } + ).ToList(); + return DataResult>.Success("获取数据成功!", data, MultiLanguageConst.DataQuerySuccess); + } +} \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.Core/System/Method/CommonService.cs b/ds-wms-service/DS.WMS.Core/System/Method/CommonService.cs index dfb68186..16b93748 100644 --- a/ds-wms-service/DS.WMS.Core/System/Method/CommonService.cs +++ b/ds-wms-service/DS.WMS.Core/System/Method/CommonService.cs @@ -108,7 +108,7 @@ public class CommonService : ICommonService TenantId = tenantId, UserType = a.UserType, CompanyId = a.CompanyId, - ClientId = a.ClientId, + // ClientId = a.ClientId, IsLimitClient = a.IsLimitClient, RefreshToken = refreshToken, // OrgId = a.OrgId.ToString(), CompanyName = a.CustomerName @@ -427,7 +427,7 @@ public class CommonService : ICommonService TenantId = tenantId, UserType = a.UserType, CompanyId = a.CompanyId, - ClientId = a.ClientId, + // ClientId = a.ClientId, IsLimitClient = a.IsLimitClient, RefreshToken = refreshToken, // UserOrgs = orgRelations, @@ -1469,4 +1469,61 @@ public class CommonService : ICommonService } #endregion + + + #region 租户下拉信息 + + /// + /// 获取付费方式下拉列表-客户端 + /// + /// + public DataResult> GetClientFrtSelectList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var list = tenantDb.Queryable() + .Where(x => x.Status == StatusEnum.Enable) + .Select() + .ToList(); + return DataResult>.Success("获取数据成功!", list); + } + /// + /// 获取结算方式下拉列表-客户端 + /// + /// + public DataResult> GetClientStlModeSelectList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var list = tenantDb.Queryable() + .Where(x => x.Status == StatusEnum.Enable) + .Select() + .ToList(); + return DataResult>.Success("获取数据成功!", list); + } + /// + /// 获取业务来源下拉列表-客户端 + /// + /// + public DataResult> GetClientSourceSelectList() + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var list = tenantDb.Queryable() + .Where(x => x.Status == StatusEnum.Enable) + .Select() + .ToList(); + return DataResult>.Success("获取数据成功!", list); + } + /// + /// 获取业务来源明细下拉列表-客户端 + /// + /// + public DataResult> GetClientSourceDetailSelectList(string id) + { + var tenantDb = saasService.GetBizDbScopeById(user.TenantId); + var list = tenantDb.Queryable() + .Where(x => x.Status == StatusEnum.Enable && x.SourceId == long.Parse(id)) + .Select() + .ToList(); + return DataResult>.Success("获取数据成功!", list); + } + #endregion } \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.MainApi/Controllers/ClientCommonController.cs b/ds-wms-service/DS.WMS.MainApi/Controllers/ClientCommonController.cs new file mode 100644 index 00000000..946835ab --- /dev/null +++ b/ds-wms-service/DS.WMS.MainApi/Controllers/ClientCommonController.cs @@ -0,0 +1,420 @@ +using DS.Module.Core; +using DS.Module.Core.Extensions; +using DS.WMS.Core.Code.Dtos; +using DS.WMS.Core.Info.Dtos; +using DS.WMS.Core.System.Dtos; +using DS.WMS.Core.System.Entity; +using DS.WMS.Core.System.Interface; +using Microsoft.AspNetCore.Authorization; +using Microsoft.AspNetCore.Mvc; +using SqlSugar; + +namespace DS.WMS.MainApi.Controllers; + +/// +/// 公共模块-客户端 +/// +public class ClientCommonController : ApiController +{ + private readonly IClientCommonService _invokeService; + + /// + /// 构造函数 + /// + /// + public ClientCommonController(IClientCommonService invokeService) + { + _invokeService = invokeService; + } + + /// + /// 获取船公司下拉列表 + /// + /// + [HttpGet] + [Route("GetCarrierClientList")] + public DataResult> GetCarrierClientList() + { + var res = _invokeService.GetCarrierClientList(); + return res; + } + /// + /// 获取场站下拉列表 + /// + /// + [HttpGet] + [Route("GetYardClientList")] + public DataResult> GetYardClientList() + { + var res = _invokeService.GetYardClientList(); + return res; + } + /// + /// 获取订舱公司下拉列表 + /// + /// + [HttpGet] + [Route("GetBookingClientList")] + public DataResult> GetBookingClientList() + { + var res = _invokeService.GetBookingClientList(); + return res; + } + /// + /// 获取车队下拉列表 + /// + /// + [HttpGet] + [Route("GetTruckClientList")] + public DataResult> GetTruckClientList() + { + var res = _invokeService.GetTruckClientList(); + return res; + } + /// + /// 获取委托单位下拉列表 + /// + /// + [HttpGet] + [Route("GetControllerClientList")] + public DataResult> GetControllerClientList() + { + var res = _invokeService.GetControllerClientList(); + return res; + } + /// + /// 获取报关行下拉列表 + /// + /// + [HttpGet] + [Route("GetCustomClientList")] + public DataResult> GetCustomClientList() + { + var res = _invokeService.GetCustomClientList(); + return res; + } + /// + /// 获取代理(国外)下拉列表 + /// + /// + [HttpGet] + [Route("GetAgentClientList")] + public DataResult> GetAgentClientList() + { + var res = _invokeService.GetAgentClientList(); + return res; + } + /// + /// 获取代理(国内)下拉列表 + /// + /// + [HttpGet] + [Route("GetAgentCnClientList")] + public DataResult> GetAgentCnClientList() + { + var res = _invokeService.GetAgentCnClientList(); + return res; + } + /// + /// 获取快递公司下拉列表 + /// + /// + [HttpGet] + [Route("GetExpressClientList")] + public DataResult> GetExpressClientList() + { + var res = _invokeService.GetExpressClientList(); + return res; + } + /// + /// 获取航空公司下拉列表 + /// + /// + [HttpGet] + [Route("GetAirLinesClientList")] + public DataResult> GetAirLinesClientList() + { + var res = _invokeService.GetAirLinesClientList(); + return res; + } + /// + /// 获取发货人下拉列表 + /// + /// + [HttpGet] + [Route("GetShipperClientList")] + public DataResult> GetShipperClientList() + { + var res = _invokeService.GetShipperClientList(); + return res; + } + /// + /// 获取收货人下拉列表 + /// + /// + [HttpGet] + [Route("GetConsigneeClientList")] + public DataResult> GetConsigneeClientList() + { + var res = _invokeService.GetConsigneeClientList(); + return res; + } + /// + /// 获取通知人下拉列表 + /// + /// + [HttpGet] + [Route("GetNotifyPartyClientList")] + public DataResult> GetNotifyPartyClientList() + { + var res = _invokeService.GetNotifyPartyClientList(); + return res; + } + /// + /// 获取仓库下拉列表 + /// + /// + [HttpGet] + [Route("GetWareHouseClientList")] + public DataResult> GetWareHouseClientList() + { + var res = _invokeService.GetWareHouseClientList(); + return res; + } + /// + /// 获取保险公司下拉列表 + /// + /// + [HttpGet] + [Route("GetInsurerClientList")] + public DataResult> GetInsurerClientList() + { + var res = _invokeService.GetInsurerClientList(); + return res; + } + /// + /// 获取租箱公司下拉列表 + /// + /// + [HttpGet] + [Route("GetLeasingClientList")] + public DataResult> GetLeasingClientList() + { + var res = _invokeService.GetLeasingClientList(); + return res; + } + /// + /// 获取贸易代理下拉列表 + /// + /// + [HttpGet] + [Route("GetTradingAgencyClientList")] + public DataResult> GetTradingAgencyClientList() + { + var res = _invokeService.GetTradingAgencyClientList(); + return res; + } + /// + /// 获取船代下拉列表 + /// + /// + [HttpGet] + [Route("GetShipAgencyClientList")] + public DataResult> GetShipAgencyClientList() + { + var res = _invokeService.GetShipAgencyClientList(); + return res; + } + /// + /// 获取经营单位下拉列表 + /// + /// + [HttpGet] + [Route("GetEnterpriseClientList")] + public DataResult> GetEnterpriseClientList() + { + var res = _invokeService.GetEnterpriseClientList(); + return res; + } + /// + /// 获取码头下拉列表 + /// + /// + [HttpGet] + [Route("GetWharfClientList")] + public DataResult> GetWharfClientList() + { + var res = _invokeService.GetWharfClientList(); + return res; + } + /// + /// 获取部门列表 + /// + /// + [HttpGet] + [Route("GetDeptList")] + public DataResult> GetDeptList([FromQuery]string orgId = "") + { + var res = _invokeService.GetDeptList(orgId); + return res; + } + /// + /// 获取操作员列表 + /// + /// + [HttpGet] + [Route("GetOperatorUserList")] + public DataResult> GetOperatorUserList() + { + var res = _invokeService.GetOperatorUserList(); + return res; + } + /// + /// 获取单证员列表 + /// + /// + [HttpGet] + [Route("GetVouchingClerkList")] + public DataResult> GetVouchingClerkList() + { + var res = _invokeService.GetVouchingClerkList(); + return res; + } + /// + /// 获取销售员列表 + /// + /// + [HttpGet] + [Route("GetSaleUserList")] + public DataResult> GetSaleUserList() + { + var res = _invokeService.GetSaleUserList(); + return res; + } + /// + /// 获取报关员列表 + /// + /// + [HttpGet] + [Route("GetCustomUserList")] + public DataResult> GetCustomUserList() + { + var res = _invokeService.GetCustomUserList(); + return res; + } + /// + /// 获取财务人员列表 + /// + /// + [HttpGet] + [Route("GetFinancialStaffList")] + public DataResult> GetFinancialStaffList() + { + var res = _invokeService.GetFinancialStaffList(); + return res; + } + /// + /// 获取客服列表 + /// + /// + [HttpGet] + [Route("GetCustomerServiceList")] + public DataResult> GetCustomerServiceList() + { + var res = _invokeService.GetCustomerServiceList(); + return res; + } + + /// + /// 获取司机列表 + /// + /// + [HttpGet] + [Route("GetDiverList")] + public DataResult> GetDiverList() + { + var res = _invokeService.GetDiverList(); + return res; + } + + /// + /// 获取派车调度人员列表 + /// + /// + [HttpGet] + [Route("GetDispatcherList")] + public DataResult> GetDispatcherList() + { + var res = _invokeService.GetDispatcherList(); + return res; + } + /// + /// 获取签单方式下拉列表 + /// + /// + [HttpGet] + [Route("GetIssueTypeSelectList")] + public DataResult> GetIssueTypeSelectList() + { + var res = _invokeService.GetIssueTypeSelectList(); + return res; + } + /// + /// 获取集装箱下拉列表 + /// + /// + [HttpGet] + [Route("GetCtnSelectList")] + public DataResult> GetCtnSelectList() + { + var res = _invokeService.GetCtnSelectList(); + return res; + } + /// + /// 获取包装类型下拉列表 + /// + /// + [HttpGet] + [Route("GetPackageSelectList")] + public DataResult> GetPackageSelectList() + { + var res = _invokeService.GetPackageSelectList(); + return res; + } + + /// + /// 获取船名下拉列表 + /// + /// + [HttpGet] + [Route("GetVesselSelectList")] + public DataResult> GetVesselSelectList() + { + var res = _invokeService.GetVesselSelectList(); + return res; + } + + /// + /// 获取航次下拉列表 + /// + /// + [HttpGet] + [Route("GetVoynoSelectList")] + public DataResult> GetVoynoSelectList() + { + var res = _invokeService.GetVoynoSelectList(); + return res; + } + + /// + /// 获取运输条款下拉列表 + /// + /// + [HttpGet] + [Route("GetServiceSelectList")] + public DataResult> GetServiceSelectList() + { + var res = _invokeService.GetServiceSelectList(); + return res; + } +} \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.MainApi/Controllers/CodeServiceController.cs b/ds-wms-service/DS.WMS.MainApi/Controllers/CodeServiceController.cs new file mode 100644 index 00000000..01da0584 --- /dev/null +++ b/ds-wms-service/DS.WMS.MainApi/Controllers/CodeServiceController.cs @@ -0,0 +1,100 @@ +using DS.Module.Core; +using DS.Module.Core.Data; +using DS.WMS.Core.Code.Dtos; +using DS.WMS.Core.Code.Interface; +using Microsoft.AspNetCore.Mvc; + +namespace DS.WMS.MainApi.Controllers; + +/// +/// 运输条款服务 +/// +public class CodeServiceController : ApiController +{ + private readonly ICodeServiceService _invokeService; + + /// + /// 构造函数 + /// + /// + public CodeServiceController(ICodeServiceService invokeService) + { + _invokeService = invokeService; + } + + /// + /// 列表 + /// + /// + /// + [HttpPost] + [Route("GetCodeServiceList")] + public DataResult> GetCodeServiceList([FromBody] PageRequest request) + { + var res = _invokeService.GetClientListByPage(request); + return res; + } + + /// + /// 编辑 + /// + /// + /// + [HttpPost] + [Route("EditCodeService")] + public DataResult EditCodeService([FromBody] CodeServiceReq model) + { + var res = _invokeService.EditClientCodeService(model); + return res; + } + + /// + /// 详情 + /// + /// + /// + [HttpGet] + [Route("GetCodeServiceInfo")] + public DataResult GetCodeServiceInfo([FromQuery] string id) + { + var res = _invokeService.GetClientCodeServiceInfo(id); + return res; + } + + /// + /// 获取运输条款列表-基础库 + /// + /// + /// + [HttpPost] + [Route("GetBasicsCodeServiceList")] + public DataResult> GetBasicsCodeServiceList([FromBody] PageRequest request) + { + var res = _invokeService.GetCodeServiceList(request); + return res; + } + /// + /// 导入运输条款类型-基础库 + /// + /// + /// + [HttpPost] + [Route("ImportCodeService")] + public DataResult ImportCodeService([FromBody] IdModel req) + { + var res = _invokeService.ImportCodeService(req); + return res; + } + + /// + /// 获取当前租户已有的运输条款 + /// + /// + [HttpGet] + [Route("GetExistCodeServiceList")] + public DataResult> GetExistCodeServiceList() + { + var res = _invokeService.GetExistCodeServiceList(); + return res; + } +} \ No newline at end of file diff --git a/ds-wms-service/DS.WMS.MainApi/Controllers/CommonController.cs b/ds-wms-service/DS.WMS.MainApi/Controllers/CommonController.cs index 810dd9f3..23df75a0 100644 --- a/ds-wms-service/DS.WMS.MainApi/Controllers/CommonController.cs +++ b/ds-wms-service/DS.WMS.MainApi/Controllers/CommonController.cs @@ -223,6 +223,50 @@ public class CommonController : ApiController return res; } /// + /// 获取付费方式下拉列表-客户端 + /// + /// + [HttpGet] + [Route("GetClientFrtSelectList")] + public DataResult> GetClientFrtSelectList() + { + var res = _invokeService.GetClientFrtSelectList(); + return res; + } + /// + /// 获取结算方式下拉列表-客户端 + /// + /// + [HttpGet] + [Route("GetClientStlModeSelectList")] + public DataResult> GetClientStlModeSelectList() + { + var res = _invokeService.GetClientStlModeSelectList(); + return res; + } + /// + /// 获取业务来源下拉列表-客户端 + /// + /// + [HttpGet] + [Route("GetClientSourceSelectList")] + public DataResult> GetClientSourceSelectList() + { + var res = _invokeService.GetClientSourceSelectList(); + return res; + } + /// + /// 获取业务来源明细下拉列表-客户端 + /// + /// + [HttpGet] + [Route("GetClientSourceDetailSelectList")] + public DataResult> GetClientSourceDetailSelectList([FromQuery] string id) + { + var res = _invokeService.GetClientSourceDetailSelectList(id); + return res; + } + /// /// 修改密码 /// /// diff --git a/ds-wms-service/DS.WMS.MainApi/Logs/internal-nlog.txt b/ds-wms-service/DS.WMS.MainApi/Logs/internal-nlog.txt index c0a0d1ee..83012574 100644 --- a/ds-wms-service/DS.WMS.MainApi/Logs/internal-nlog.txt +++ b/ds-wms-service/DS.WMS.MainApi/Logs/internal-nlog.txt @@ -852,3 +852,66 @@ 2024-03-12 17:23:44.4645 Info Validating config: TargetNames=console, ownFile-web, ConfigItems=54, FilePath=D:\Code\DS\ds8-solution\ds-wms-service\DS.WMS.MainApi\bin\Debug\net8.0\nlog.config 2024-03-12 17:23:44.4834 Warn Unused target detected. Add a rule for this target to the configuration. TargetName: allfile 2024-03-12 17:23:44.5366 Info Configuration initialized. +2024-03-20 10:37:25.1210 Info Registered target NLog.Targets.FileTarget(Name=allfile) +2024-03-20 10:37:25.1774 Info Registered target NLog.Targets.FileTarget(Name=ownFile-web) +2024-03-20 10:37:25.2210 Info Registered target NLog.Targets.ColoredConsoleTarget(Name=console) +2024-03-20 10:37:25.2582 Info NLog, Version=5.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c. File version: 5.2.8.2366. Product version: 5.2.8+f586f1341c46fa38aaaff4c641e7f0fa7e813943. GlobalAssemblyCache: False +2024-03-20 10:37:25.3190 Info Validating config: TargetNames=console, ownFile-web, ConfigItems=54, FilePath=D:\Code\DS\ds8-solution\ds-wms-service\DS.WMS.MainApi\bin\Debug\net8.0\nlog.config +2024-03-20 10:37:25.3443 Warn Unused target detected. Add a rule for this target to the configuration. TargetName: allfile +2024-03-20 10:37:25.4156 Info Configuration initialized. +2024-03-20 11:01:01.9675 Info Registered target NLog.Targets.FileTarget(Name=allfile) +2024-03-20 11:01:01.9922 Info Registered target NLog.Targets.FileTarget(Name=ownFile-web) +2024-03-20 11:01:02.0094 Info Registered target NLog.Targets.ColoredConsoleTarget(Name=console) +2024-03-20 11:01:02.0348 Info NLog, Version=5.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c. File version: 5.2.8.2366. Product version: 5.2.8+f586f1341c46fa38aaaff4c641e7f0fa7e813943. GlobalAssemblyCache: False +2024-03-20 11:01:02.0592 Info Validating config: TargetNames=console, ownFile-web, ConfigItems=54, FilePath=D:\Code\DS\ds8-solution\ds-wms-service\DS.WMS.MainApi\bin\Debug\net8.0\nlog.config +2024-03-20 11:01:02.0691 Warn Unused target detected. Add a rule for this target to the configuration. TargetName: allfile +2024-03-20 11:01:02.0935 Info Configuration initialized. +2024-03-20 11:01:50.2035 Info Registered target NLog.Targets.FileTarget(Name=allfile) +2024-03-20 11:01:50.2310 Info Registered target NLog.Targets.FileTarget(Name=ownFile-web) +2024-03-20 11:01:50.2506 Info Registered target NLog.Targets.ColoredConsoleTarget(Name=console) +2024-03-20 11:01:50.2690 Info NLog, Version=5.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c. File version: 5.2.8.2366. Product version: 5.2.8+f586f1341c46fa38aaaff4c641e7f0fa7e813943. GlobalAssemblyCache: False +2024-03-20 11:01:50.2940 Info Validating config: TargetNames=console, ownFile-web, ConfigItems=54, FilePath=D:\Code\DS\ds8-solution\ds-wms-service\DS.WMS.MainApi\bin\Debug\net8.0\nlog.config +2024-03-20 11:01:50.3041 Warn Unused target detected. Add a rule for this target to the configuration. TargetName: allfile +2024-03-20 11:01:50.3241 Info Configuration initialized. +2024-03-20 11:04:42.4079 Info Registered target NLog.Targets.FileTarget(Name=allfile) +2024-03-20 11:04:42.4259 Info Registered target NLog.Targets.FileTarget(Name=ownFile-web) +2024-03-20 11:04:42.4357 Info Registered target NLog.Targets.ColoredConsoleTarget(Name=console) +2024-03-20 11:04:42.4357 Info NLog, Version=5.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c. File version: 5.2.8.2366. Product version: 5.2.8+f586f1341c46fa38aaaff4c641e7f0fa7e813943. GlobalAssemblyCache: False +2024-03-20 11:04:42.4632 Info Validating config: TargetNames=console, ownFile-web, ConfigItems=54, FilePath=D:\Code\DS\ds8-solution\ds-wms-service\DS.WMS.MainApi\bin\Debug\net8.0\nlog.config +2024-03-20 11:04:42.4707 Warn Unused target detected. Add a rule for this target to the configuration. TargetName: allfile +2024-03-20 11:04:42.4873 Info Configuration initialized. +2024-03-20 11:06:55.5478 Info Registered target NLog.Targets.FileTarget(Name=allfile) +2024-03-20 11:06:55.5796 Info Registered target NLog.Targets.FileTarget(Name=ownFile-web) +2024-03-20 11:06:55.6021 Info Registered target NLog.Targets.ColoredConsoleTarget(Name=console) +2024-03-20 11:06:55.6200 Info NLog, Version=5.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c. File version: 5.2.8.2366. Product version: 5.2.8+f586f1341c46fa38aaaff4c641e7f0fa7e813943. GlobalAssemblyCache: False +2024-03-20 11:06:55.6467 Info Validating config: TargetNames=console, ownFile-web, ConfigItems=54, FilePath=D:\Code\DS\ds8-solution\ds-wms-service\DS.WMS.MainApi\bin\Debug\net8.0\nlog.config +2024-03-20 11:06:55.6600 Warn Unused target detected. Add a rule for this target to the configuration. TargetName: allfile +2024-03-20 11:06:55.6896 Info Configuration initialized. +2024-03-20 11:45:26.2534 Info Registered target NLog.Targets.FileTarget(Name=allfile) +2024-03-20 11:45:26.2706 Info Registered target NLog.Targets.FileTarget(Name=ownFile-web) +2024-03-20 11:45:26.2901 Info Registered target NLog.Targets.ColoredConsoleTarget(Name=console) +2024-03-20 11:45:26.3092 Info NLog, Version=5.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c. File version: 5.2.8.2366. Product version: 5.2.8+f586f1341c46fa38aaaff4c641e7f0fa7e813943. GlobalAssemblyCache: False +2024-03-20 11:45:26.3361 Info Validating config: TargetNames=console, ownFile-web, ConfigItems=54, FilePath=D:\Code\DS\ds8-solution\ds-wms-service\DS.WMS.MainApi\bin\Debug\net8.0\nlog.config +2024-03-20 11:45:26.3463 Warn Unused target detected. Add a rule for this target to the configuration. TargetName: allfile +2024-03-20 11:45:26.3670 Info Configuration initialized. +2024-03-20 11:49:20.6178 Info Registered target NLog.Targets.FileTarget(Name=allfile) +2024-03-20 11:49:20.6349 Info Registered target NLog.Targets.FileTarget(Name=ownFile-web) +2024-03-20 11:49:20.6487 Info Registered target NLog.Targets.ColoredConsoleTarget(Name=console) +2024-03-20 11:49:20.6637 Info NLog, Version=5.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c. File version: 5.2.8.2366. Product version: 5.2.8+f586f1341c46fa38aaaff4c641e7f0fa7e813943. GlobalAssemblyCache: False +2024-03-20 11:49:20.6817 Info Validating config: TargetNames=console, ownFile-web, ConfigItems=54, FilePath=D:\Code\DS\ds8-solution\ds-wms-service\DS.WMS.MainApi\bin\Debug\net8.0\nlog.config +2024-03-20 11:49:20.6898 Warn Unused target detected. Add a rule for this target to the configuration. TargetName: allfile +2024-03-20 11:49:20.7081 Info Configuration initialized. +2024-03-20 11:50:28.9010 Info Registered target NLog.Targets.FileTarget(Name=allfile) +2024-03-20 11:50:28.9312 Info Registered target NLog.Targets.FileTarget(Name=ownFile-web) +2024-03-20 11:50:28.9515 Info Registered target NLog.Targets.ColoredConsoleTarget(Name=console) +2024-03-20 11:50:28.9719 Info NLog, Version=5.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c. File version: 5.2.8.2366. Product version: 5.2.8+f586f1341c46fa38aaaff4c641e7f0fa7e813943. GlobalAssemblyCache: False +2024-03-20 11:50:28.9970 Info Validating config: TargetNames=console, ownFile-web, ConfigItems=54, FilePath=D:\Code\DS\ds8-solution\ds-wms-service\DS.WMS.MainApi\bin\Debug\net8.0\nlog.config +2024-03-20 11:50:29.0107 Warn Unused target detected. Add a rule for this target to the configuration. TargetName: allfile +2024-03-20 11:50:29.0548 Info Configuration initialized. +2024-03-20 11:57:03.1428 Info Registered target NLog.Targets.FileTarget(Name=allfile) +2024-03-20 11:57:03.1724 Info Registered target NLog.Targets.FileTarget(Name=ownFile-web) +2024-03-20 11:57:03.1893 Info Registered target NLog.Targets.ColoredConsoleTarget(Name=console) +2024-03-20 11:57:03.2253 Info NLog, Version=5.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c. File version: 5.2.8.2366. Product version: 5.2.8+f586f1341c46fa38aaaff4c641e7f0fa7e813943. GlobalAssemblyCache: False +2024-03-20 11:57:03.2639 Info Validating config: TargetNames=console, ownFile-web, ConfigItems=54, FilePath=D:\Code\DS\ds8-solution\ds-wms-service\DS.WMS.MainApi\bin\Debug\net8.0\nlog.config +2024-03-20 11:57:03.2639 Warn Unused target detected. Add a rule for this target to the configuration. TargetName: allfile +2024-03-20 11:57:03.3249 Info Configuration initialized. diff --git a/ds-wms-service/DS.WMS.Test/SaasTest.cs b/ds-wms-service/DS.WMS.Test/SaasTest.cs index d02af8da..9d1d8b87 100644 --- a/ds-wms-service/DS.WMS.Test/SaasTest.cs +++ b/ds-wms-service/DS.WMS.Test/SaasTest.cs @@ -27,7 +27,7 @@ public class SaasTest { Type[] types= Assembly .LoadFrom("DS.WMS.Core.dll")//如果 .dll报错,可以换成 xxx.exe 有些生成的是exe - .GetTypes().Where(it=>it.FullName.Contains("DS.WMS.Core.Code.Entity.")||it.FullName.Contains("DS.WMS.Core.Info.Entity."))//命名空间过滤,当然你也可以写其他条件过滤 + .GetTypes().Where(it=>it.FullName.Contains("DS.WMS.Core.Code.Entity.")||it.FullName.Contains("DS.WMS.Core.Info.Entity.")||it.FullName.Contains("DS.WMS.Core.Sea.Entity."))//命名空间过滤,当然你也可以写其他条件过滤 .ToArray(); var tenantDb = saasService.GetBizDbScopeById("1750335377144680448"); // var temp = tenantDb.CodeFirst.GetDifferenceTables(types);