From c229a0cfe28d01ee4eea57e4f3ff6d5d2eea3f57 Mon Sep 17 00:00:00 2001 From: wixy Date: Mon, 7 Mar 2022 11:34:36 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8F=96=E6=B6=88=E6=9B=BF=E6=8D=A2=E7=99=BB?= =?UTF-8?q?=E5=BD=95=E7=95=8C=E9=9D=A2=EF=BC=8C=E6=94=B9=E4=B8=BA=E5=86=8D?= =?UTF-8?q?=E6=BA=90=E7=A8=8B=E5=BA=8F=E7=99=BB=E5=BD=95=E7=95=8C=E9=9D=A2?= =?UTF-8?q?=E6=B3=A8=E5=85=A5=E7=99=BB=E5=BD=95=E6=8C=89=E9=92=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- QuickAuthLogin.zip | Bin 0 -> 10815 bytes QuickAuthLogin/Plugin.php | 35 ++++++++++++++++- QuickAuthLogin/README.md | 60 ++++++++++++++++++++++++++++++ QuickAuthLogin/views/authbind.php | 3 +- 4 files changed, 96 insertions(+), 2 deletions(-) create mode 100644 QuickAuthLogin.zip create mode 100644 QuickAuthLogin/README.md diff --git a/QuickAuthLogin.zip b/QuickAuthLogin.zip new file mode 100644 index 0000000000000000000000000000000000000000..a8408d261cd4e0e7efe3ef26b582470721020220 GIT binary patch literal 10815 zcmZ{Kbx>Vf^7X|vxH|-QclV$dcXxMpNN@=5?oMzI!Cfxy?i$?T%d4qx-qg(d?ej;U zeX91VU0tWT*XnMdECeJ5004jmEco-OMx}6562k)k5R?D_?w_wpZdN8XB5tmhat;<& z_Dmusu2v5AjENi+A}R(S$4GqST{Wh7%xlo4t} zoc_x|^<=DU!!{lGstd!Whvu_&C+&5FJSaO2*PwvVqW#%-gop7Zg~8bD)?d~Rf<+_a zH?Ifjhkj={SzH-|Y06Tsiq@?)maT&>1)4nF+QUrA{m$j8sMx7v1;fR&M}2iHkPrsy zXX$n4bu3!R^ayXGN_!JfL-sXCpCr(+O?5yVB=vRb4M4N8U(PDn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xq*tN zHooGEg&syr;(kB#t3e}Lh~HOO`ktVERQ_a`LxHTD0w4Ct@~Q4j=Sa~1eYVzK@A7hU z?vuKbT6>{87~8nwvtp~?U3YazyhL=6xJPK&zOqTm9m9Sve{2Ll_9|{D6D&nM-&qaR{agFG+LwdYSU(R7D|~c zY_#uSmQ_Jm?SgF2gkzoLB|5>$Q!^AAw5=pa>E)8Q72VyTIv3O3d2bAI%3FdaHiAJ* zDT?^)6?wqs!#G+`>`{M=Sf}u91sqA=4}P;C)(fb0n#Y5=?Kdy8-T@?_&%bW;Z$bc+h5ADt008JePdyj_;6eS@?*9R05=5l{ literal 0 HcmV?d00001 diff --git a/QuickAuthLogin/Plugin.php b/QuickAuthLogin/Plugin.php index 11dfd9b..5597f4a 100644 --- a/QuickAuthLogin/Plugin.php +++ b/QuickAuthLogin/Plugin.php @@ -26,8 +26,11 @@ class QuickAuthLogin_Plugin implements Typecho_Plugin_Interface { $info = self::updateDb(); Typecho_Plugin::factory('admin/menu.php')-> navBar = array(__class__, 'render'); - Typecho_Plugin::factory('admin/header.php')-> header = array(__class__,'login'); Typecho_Plugin::factory('Widget_User')-> loginSucceed = array(__class__,'afterlogin'); + Typecho_Plugin::factory('admin/footer.php')->end = array(__class__, 'render_footer'); + + + Helper::addPanel(1, 'QuickAuthLogin/views/authbind.php', '微信账号绑定', '微信账号绑定', 'subscriber'); Helper::addRoute('bind',__TYPECHO_ADMIN_DIR__.'QuickAuthLogin/bind','QuickAuthLogin_Action','bind'); Helper::addRoute('login',__TYPECHO_ADMIN_DIR__.'QuickAuthLogin/login','QuickAuthLogin_Action','login'); @@ -77,6 +80,10 @@ class QuickAuthLogin_Plugin implements Typecho_Plugin_Interface { ALTER TABLE `{$prefix}users` DROP COLUMN `qa_avatar`; "; $db->query($sql); + + + Helper::removePanel(1, 'QuickAuthLogin/views/authbind.php'); + return "数据表删除字段成功!"; } @@ -170,6 +177,32 @@ class QuickAuthLogin_Plugin implements Typecho_Plugin_Interface { } } + public static function render_footer(){ + $options = self::getoptions(); + if (!Typecho_Widget::widget('Widget_User')->hasLogin()){ + + + echo ''; + } + } + public static function render(){ $options = self::getoptions(); if($options->users){ diff --git a/QuickAuthLogin/README.md b/QuickAuthLogin/README.md new file mode 100644 index 0000000..b07261a --- /dev/null +++ b/QuickAuthLogin/README.md @@ -0,0 +1,60 @@ +# QuickAuthLogin + +基于[QuickAuth](https://qauth.cn)扫码登录平台开发的Typecho微信扫码登录插件 + +## 起始 + +本插件是基于 QuickAuth 开发的 插件,使用前需要进入[QuickAuth平台](https://qauth.cn)注册配置自己的应用 + +如需修改插件或开发自己的接入项目,请参考 [QuickAuth接入文档](https://qauth.cn/doc/index.html) + +插件地址:[https://github.com/mr-wixy/QuickAuthLogin](https://github.com/mr-wixy/QuickAuthLogin) + +(请勿与其它同类插件同时启用,以免互相影响) + +## 使用方法 + +第 1 步:下载本插件,解压,放到 `usr/plugins/` 目录中; + +第 2 步:文件夹名改为 `QuickAuthLogin`; + +第 3 步:登录管理后台,激活插件; + +第 4 步:登录QuickAuth网站创建接入应用; + +![](https://cdn.wixy.cn/blog-picture/blog-picture20220127160420.png) + +
+ +第 5 步:填写应用的基本信息(注意:此时可以获取到AppKey,回调地址请填写自己博客的域名+/index.php/admin/QuickAuthLogin/wechatlogin 此处必须为https) + +![](https://cdn.wixy.cn/blog-picture/blog-picture20220127160707.png) + +第 6 步:发布应用; + +![发布应用](https://cdn.wixy.cn/blog-picture/blog-picture20220127161055.png) + +第 7 步:[获取](https://qauth.cn/config/secret)UserSecretKey; + +![](https://cdn.wixy.cn/blog-picture/blog-picture20220127161157.png) + +第 8 步:进入博客插件后台配置AppKey和UserSecret; + +![](https://cdn.wixy.cn/blog-picture/20220127161859.png) + +
+ +## 重要说明 + +1. QuickAuthApi 默认配置,正常情况下无需修改(除非QuickAuth网站接口地址改了) +2. 账户密码登录默认开启,如需关闭,请确保账号已经绑定微信,否则将无法正常登录后台;如果出现这种情况,请重装插件解决! +3. 允许未绑定微信账号扫码登录开启后,未绑定的微信扫码则会自动注册账号 +4. 非管理员启用选项开启后会在导航栏增加微信账号绑定入口 + +## 与我联系 + +作者:wixy + +如果有任何意见或发现任何BUG请联系我 + +博客:[https://blog.wixy.cn/](https://blog.wixy.cn/) \ No newline at end of file diff --git a/QuickAuthLogin/views/authbind.php b/QuickAuthLogin/views/authbind.php index 1677311..fac76fc 100644 --- a/QuickAuthLogin/views/authbind.php +++ b/QuickAuthLogin/views/authbind.php @@ -1,4 +1,5 @@ users){ //非管理员且[非管理员 - QuickAuthLogin - 扫描登录授权绑定 + QuickAuthLogin - 扫码登录授权绑定