From e53ac98415624d42b8fc2e6824edcf1635b43a65 Mon Sep 17 00:00:00 2001 From: dyy <807692433@qq.com> Date: Wed, 9 Mar 2022 14:21:48 +0800 Subject: [PATCH] =?UTF-8?q?=E3=80=90=E4=BF=AE=E6=94=B9=E3=80=9130=E5=A4=A9?= =?UTF-8?q?=E6=9C=AA=E4=BF=AE=E6=94=B9=E5=AF=86=E7=A0=81=E6=8F=90=E7=A4=BA?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E5=BC=80=E5=85=B3=E6=98=BE=E7=A4=BA=E9=85=8D?= =?UTF-8?q?=E7=BD=AE=EF=BC=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Views/TeachSwitch/Index.js | 4 +++- .../Controllers/LoginController.cs | 23 +++++++++++-------- .../Views/Home/AdminDefault/index.js | 2 +- 3 files changed, 17 insertions(+), 12 deletions(-) diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/TeachSwitch/Index.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/TeachSwitch/Index.js index a317d1f94..038692712 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/TeachSwitch/Index.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/TeachSwitch/Index.js @@ -70,7 +70,7 @@ var bootstrap = function ($, learun) { url: top.$.rootUrl + '/EducationalAdministration/TeachSwitch/GetPageList', headData: [ { - label: "开关名称", name: "type", width: 150, align: "left", + label: "开关名称", name: "type", width: 300, align: "left", formatter: function (val) { if (val == 'js') { return '教师注册开关'; @@ -80,6 +80,8 @@ var bootstrap = function ($, learun) { return '网上办事大厅开关'; } else if (val == 'wxloginforpc') { return '微信快捷登录PC端'; + } else if (val == 'modifypwdtip') { + return '30天未修改密码登录后提示修改'; } } diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Controllers/LoginController.cs b/Learun.Framework.Ultimate V7/Learun.Application.Web/Controllers/LoginController.cs index de541d24a..ca2700b51 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Controllers/LoginController.cs +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Controllers/LoginController.cs @@ -571,21 +571,24 @@ namespace Learun.Application.Web.Controllers return Success(new { pwd = true }); } //是否30天未修改密码验证 - //TODO:获取开关配置中“30天未修改密码进行提示”项的配置 - if (userEntity.F_ModifyPwdDate.HasValue) + //获取开关显示配置中“30天未修改密码登录后提示修改”项的配置 + if (teachSwitchIBLL.FindFirst("modifypwdtip")) { - if ((DateTime.Now-userEntity.F_ModifyPwdDate.Value).Days>30) + if (userEntity.F_ModifyPwdDate.HasValue) { - return Success(new { pwdtip = true }); + if ((DateTime.Now-userEntity.F_ModifyPwdDate.Value).Days>30) + { + return Success(new { pwdtip = true }); + } } - } - else - { - if (userEntity.F_CreateDate.HasValue && (DateTime.Now-userEntity.F_CreateDate.Value).Days>30) + else { - return Success(new { pwdtip=true }); + if (userEntity.F_CreateDate.HasValue && (DateTime.Now-userEntity.F_CreateDate.Value).Days>30) + { + return Success(new { pwdtip=true }); + } } - } + } return Success("登录成功"); } diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminDefault/index.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminDefault/index.js index 76e7aa1bd..9f2ebdff8 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminDefault/index.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminDefault/index.js @@ -228,7 +228,7 @@ var bootstrap = function ($, learun) { } //30天未修改密码进行提示 if (pwdtip == "true") { - layer.alert("您已30天未修改密码,请先修改!", { title: "提示", yes: function (index) { layer.close(index) } }); + layer.alert("您已30天未修改密码,请先修改!", {icon:7, title: "提示", yes: function (index) { layer.close(index) } }); } //上网认证 if (ACIp != null && ACIp != "") {