Files
addons
app_download_files
extend
hyhproject
admin
app
common
home
home2
behavior
InitConfig.php
ListenProtectedUrl.php
common
conf
controller
model
validate
view
mobile2
wechat2
.htaccess
command.php
mobile
oss
static
thinkphp
upload
vendor
wxtmp
.gitignore
.htaccess
.user.ini
404.html
H5436787D.wgt
admin.php
app-release.apk
app_download.html
cash.lock
demo.php
get_startup.php
get_version.php
get_version_new.php
index.html
index.php
reg.lock
robots.txt
qlg.tsgz.moe/hyhproject/home2/behavior/InitConfig.php
2019-09-06 23:53:10 +08:00

23 lines
611 B
PHP
Executable File

<?php
namespace wstmart\home\behavior;
/**
* ============================================================================
* 初始化基础数据
*/
class InitConfig
{
public function run(&$params){
WSTConf('protectedUrl',model('HomeMenus')->getMenusUrl());
// 检测手机端访问
$request = request();
$currModel = $request->module();
hook('initConfigHook',['getParams'=>input()]);
if($request->isMobile() && $currModel=='home'){
$url = url('mobile/index/index');
header("location:$url");
die;
}
}
}