This commit is contained in:
2025-03-17 11:27:07 +08:00
parent 7a7f432006
commit 5febeca83f
6805 changed files with 6 additions and 6 deletions

View File

@@ -0,0 +1,47 @@
<?php
/*
* description
* authorwh
* email
* createTime{2022/5/4} {9:39}
*/
namespace app\index\controller;
use think\Request;
use wanghua\general_utility_tools_php\framework\base\PublicController;
use wanghua\general_utility_tools_php\tool\Tools;
class BasePublicController extends BaseCommonController
{
public function __construct(Request $request = null)
{
parent::__construct($request);
//校验系统维护状态 start
$chm = $this->checkMaintain();
if($chm['is_maintain']){
if($chm['openid']){
//解析openid
if(!in_array(index_user_openid(), explode(',',$chm['openid']))){
//白名单之外维护中
//Tools::log_to_write_txt([
// '维护测试'=>$chm['openid'],
// 'my'=>index_user_openid()
//]);
return $this->error($chm['msg']);
}
}else{
//不存在,直接维护中
return $this->error($chm['msg'].'');
}
}
//校验系统维护状态 end
}
}