From 494295bc4c49b38389f17b90fd878b641bf9881f Mon Sep 17 00:00:00 2001 From: ndbs Date: Wed, 13 Jul 2022 12:26:17 +0800 Subject: [PATCH] =?UTF-8?q?=E6=99=9A=E5=BD=92=E8=A7=84=E5=88=99=E6=B7=BB?= =?UTF-8?q?=E5=8A=A0=20=E4=BF=9D=E5=8D=AB=E5=A4=84=E4=BF=A1=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Acc_DormitoryRule/Acc_DormitoryRuleEntity.cs | 5 +++++ .../Acc_DormitoryRule/Acc_DormitoryRuleService.cs | 6 ++++++ 2 files changed, 11 insertions(+) diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleEntity.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleEntity.cs index 7af6a9117..d7cd70906 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleEntity.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleEntity.cs @@ -74,6 +74,11 @@ namespace Learun.Application.TwoDevelopment.LogisticsManagement /// [Column("DEFEND")] public int? Defend { get; set; } + /// + /// + /// + [Column("DEFENDID")] + public string DefendId { get; set; } #endregion diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleService.cs index d285ddf19..e5148edfb 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleService.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleService.cs @@ -1,4 +1,5 @@ using Dapper; +using Learun.Application.Organization; using Learun.DataBase.Repository; using Learun.Util; using System; @@ -151,6 +152,11 @@ namespace Learun.Application.TwoDevelopment.LogisticsManagement entity.Create(); entity.CreateTime = DateTime.Now; entity.CreateUserId = loInfo.account; + var NewID = this.BaseRepository().FindEntity(x => x.F_FullName == "保卫处").F_DepartmentId; + if (NewID != null && entity.Defend == 1) + { + entity.DefendId = NewID; + } this.BaseRepository("CollegeMIS").Insert(entity); } }