refactor: 进一步区分banner的pc与mobile
This commit is contained in:
@@ -2,9 +2,9 @@
|
||||
// +----------------------------------------------------------------------
|
||||
// | 模板设置
|
||||
// +----------------------------------------------------------------------
|
||||
$view_deivce_name = 'pc';
|
||||
$view_device_name = 'pc';
|
||||
if (request()->isMobile()) {
|
||||
$view_deivce_name = 'mobile';
|
||||
$view_device_name = 'mobile';
|
||||
}
|
||||
|
||||
return [
|
||||
@@ -13,7 +13,7 @@ return [
|
||||
// 默认模板渲染规则 1 解析为小写+下划线 2 全部转换小写 3 保持操作方法
|
||||
'auto_rule' => 1,
|
||||
// 模板目录名
|
||||
'view_dir_name' => "view/{$view_deivce_name}",
|
||||
'view_dir_name' => "view/{$view_device_name}",
|
||||
// 模板后缀
|
||||
'view_suffix' => 'html',
|
||||
// 模板文件名分隔符
|
||||
@@ -28,8 +28,8 @@ return [
|
||||
'taglib_end' => '}',
|
||||
// 模板输出替换
|
||||
'tpl_replace_string' => [
|
||||
'__CSS__' => "/static/index/{$view_deivce_name}/css",
|
||||
'__JS__' => "/static/index/{$view_deivce_name}/js",
|
||||
'__IMAGES__' => "/static/index/{$view_deivce_name}/images",
|
||||
'__CSS__' => "/static/index/{$view_device_name}/css",
|
||||
'__JS__' => "/static/index/{$view_device_name}/js",
|
||||
'__IMAGES__' => "/static/index/{$view_device_name}/images",
|
||||
]
|
||||
];
|
||||
|
||||
Reference in New Issue
Block a user