From 26dca595550d540d395def1fa08893582c97e8fe Mon Sep 17 00:00:00 2001 From: jianghaiqing Date: Thu, 6 Jul 2023 14:49:01 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=9C=8D=E5=8A=A1=E6=B5=81?= =?UTF-8?q?=E7=A8=8B=E4=BF=9D=E5=AD=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Entity/TrackingSystem/ServiceWorkFlowBaseInfo.cs | 2 +- .../Service/TrackingSystem/ServiceWorkFlowBaseService.cs | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/Myshipping.Application/Entity/TrackingSystem/ServiceWorkFlowBaseInfo.cs b/Myshipping.Application/Entity/TrackingSystem/ServiceWorkFlowBaseInfo.cs index 9d479539..81ef769e 100644 --- a/Myshipping.Application/Entity/TrackingSystem/ServiceWorkFlowBaseInfo.cs +++ b/Myshipping.Application/Entity/TrackingSystem/ServiceWorkFlowBaseInfo.cs @@ -53,7 +53,7 @@ namespace Myshipping.Application.Entity /// /// 所属租户ID /// - public string BELONG_TENANT_ID { get; set; } + public long BELONG_TENANT_ID { get; set; } /// /// 所属租户名称 diff --git a/Myshipping.Application/Service/TrackingSystem/ServiceWorkFlowBaseService.cs b/Myshipping.Application/Service/TrackingSystem/ServiceWorkFlowBaseService.cs index 4f03a02d..ee9c53d0 100644 --- a/Myshipping.Application/Service/TrackingSystem/ServiceWorkFlowBaseService.cs +++ b/Myshipping.Application/Service/TrackingSystem/ServiceWorkFlowBaseService.cs @@ -192,6 +192,12 @@ namespace Myshipping.Application if (entity == null) throw Oops.Oh($"服务流程不能为空", typeof(InvalidOperationException)); + if(entity.BELONG_TENANT_ID == 0) + { + entity.BELONG_TENANT_ID = UserManager.TENANT_ID; + entity.BELONG_TENANT_NAME = UserManager.TENANT_NAME; + } + _logger.LogInformation($"服务流程保存 JSON={JSON.Serialize(entity)} user={UserManager.UserId}"); if (string.IsNullOrWhiteSpace(entity.PK_ID))