From bcedd29f560ee327239d4ad476fa26aba5874822 Mon Sep 17 00:00:00 2001 From: liangkun Date: Mon, 28 Aug 2023 18:25:43 +0800 Subject: [PATCH] =?UTF-8?q?=E5=BE=AE=E4=BF=A1=E7=99=BB=E5=BD=95=E8=B0=83?= =?UTF-8?q?=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Learun.Application.WebApi/Modules/WeixinApi.cs | 12 +++++++++++- Learun.Framework.Ultimate V7/LearunApp-2.2.0/App.vue | 2 +- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/Learun.Framework.Ultimate V7/Learun.Application.WebApi/Modules/WeixinApi.cs b/Learun.Framework.Ultimate V7/Learun.Application.WebApi/Modules/WeixinApi.cs index ee3d82139..e84ebfb49 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.WebApi/Modules/WeixinApi.cs +++ b/Learun.Framework.Ultimate V7/Learun.Application.WebApi/Modules/WeixinApi.cs @@ -108,6 +108,16 @@ namespace Learun.Application.WebApi.Modules string code = Request.Query["code"]; var responsejson = HttpGet("https://api.weixin.qq.com/sns/oauth2/access_token?appid=" + appid + "&secret=" + secret + "&code=" + code + "&grant_type=authorization_code"); + LogEntity logEntity = new LogEntity(); + logEntity.F_CategoryId = 1234; + logEntity.F_OperateTypeId = ((int)OperationType.Visit).ToString(); + logEntity.F_OperateType = EnumAttribute.GetDescription(OperationType.Visit); + logEntity.F_OperateAccount = "wxlogin:access_token"; + logEntity.F_OperateUserId = "wxlogin:access_token"; + logEntity.F_Module = "wxlogin:access_token"; + logEntity.F_Description = "wxlogin:access_token"; + logEntity.F_SourceContentJson = responsejson; + logEntity.WriteLog(); if (!string.IsNullOrEmpty(responsejson)) { var weixintokenobj = JsonConvert.DeserializeObject(responsejson); @@ -120,7 +130,7 @@ namespace Learun.Application.WebApi.Modules ReqParameter req = this.Bind(); string token = OperatorHelper.Instance.AddLoginUser(userEntity.F_Account, "Learun_ADMS_6.1_App", req.loginMark, false);//写入缓存信息 #region 写入日志 - LogEntity logEntity = new LogEntity(); + logEntity = new LogEntity(); logEntity.F_CategoryId = 1; logEntity.F_OperateTypeId = ((int)OperationType.Login).ToString(); logEntity.F_OperateType = EnumAttribute.GetDescription(OperationType.Login); diff --git a/Learun.Framework.Ultimate V7/LearunApp-2.2.0/App.vue b/Learun.Framework.Ultimate V7/LearunApp-2.2.0/App.vue index af8274182..54e2bbded 100644 --- a/Learun.Framework.Ultimate V7/LearunApp-2.2.0/App.vue +++ b/Learun.Framework.Ultimate V7/LearunApp-2.2.0/App.vue @@ -12,7 +12,7 @@ // H5 刷新时获取当前页面路径 const pagePath = "/" + param.path; // 如果 H5 刷新后访问的不是首页/登录页/注册页,直接跳转回首页 - if (!["/pages/login", "/pages/home", "/pages/signup"].includes(pagePath)) { + if (!["/pages/login", "/pages/home", "/pages/signup","/pages/weixinLogin","/pages/wxLogin"].includes(pagePath)) { this.$nextTick(() => { this.TAB_TO("/pages/home"); return;