提交 aa2142c4 编写于 作者: D devil_gong

应用开发

上级 9947b898
......@@ -131,6 +131,9 @@ class Common extends Controller
// 用户注册邮箱页面钩子
$this->assign('plugins_view_user_email_reg_info_data', Hook::listen('plugins_view_user_email_reg_info', ['hook_name'=>'plugins_view_user_email_reg_info', 'is_backend'=>false, 'user'=>$this->user]));
// 底部导航上面钩子
$this->assign('plugins_view_common_footer_top_data', Hook::listen('plugins_view_common_footer_top', ['hook_name'=>'plugins_view_common_footer_top', 'is_backend'=>false, 'user'=>$this->user]));
}
/**
......
......@@ -91,8 +91,9 @@ class Index extends Common
// 楼层数据上面
$this->assign('plugins_view_home_floor_top_data', Hook::listen('plugins_view_home_floor_top',
[
'hook_name' => 'plugins_view_home_floor_top',
'hook_name' => 'plugins_view_home_floor_top',
'is_backend' => false,
'user' => $this->user,
]));
}
}
......
......@@ -99,7 +99,7 @@
</div>
</div>
<!-- 楼层数据上面 -->
<!-- 楼层数据上面钩子 -->
{{if isset($shopxo_is_develop) and $shopxo_is_develop eq true and (!isset($is_footer) or $is_footer eq 1)}}
<div class="plugins-tag">
<span>plugins_view_home_floor_top</span>
......
......@@ -14,79 +14,19 @@
</div>
{{/if}}
<style type="text/css">
.module-customer-service {
background: #f8f8f8;
padding: 10px 0;
margin-top: 20px;
}
.module-customer-service .am-gallery-overlay .am-gallery-item img {
width: 50px;
float: left;
}
.module-customer-service .am-gallery-overlay .am-gallery-item .base {
margin-left: 60px;
}
.module-customer-service .am-gallery-overlay .am-gallery-item .base .title {
font-weight: 500;
font-size: 16px;
color: #505050;
}
.module-customer-service .am-gallery-overlay .am-gallery-item .base .desc {
color: #999;
margin-top: 5px;
}
.am-footer-default {
margin-top: 0;
}
@media only screen and (max-width:640px) {
.module-customer-service .am-gallery-overlay .am-gallery-item {
border-bottom: 1px solid #f0f0f0;
padding-bottom: 10px;
}
}
</style>
<div class="module-customer-service">
<ul data-am-widget="gallery" class="am-gallery am-avg-sm-1 am-avg-md-4 am-avg-lg-4 am-gallery-overlay am-no-layout am-container" data-am-gallery="{}">
<li>
<div class="am-gallery-item">
<img src="https://mall.opencart.cn/image/cache/catalog/mi/icon/icon-1-55x55.png" alt="hello" />
<div class="base">
<p class="title">物行天下</p>
<p class="desc">多仓直发 极速配送多仓直发 极速配送</p>
</div>
</div>
</li>
<li>
<div class="am-gallery-item">
<img src="https://mall.opencart.cn/image/cache/catalog/mi/icon/icon-4-55x55.png" alt="hello" />
<div class="base">
<p class="title">精致服务</p>
<p class="desc">精致服务 售后保障精致服务 售后保障</p>
</div>
</div>
</li>
<li>
<div class="am-gallery-item">
<img src="https://mall.opencart.cn/image/cache/catalog/mi/icon/icon-3-55x55.png" alt="hello" />
<div class="base">
<p class="title">退换无忧</p>
<p class="desc">放心购物 退还无忧放心购物 退还无忧</p>
</div> </div>
</li>
<li>
<div class="am-gallery-item">
<img src="https://mall.opencart.cn/image/cache/catalog/mi/icon/icon-2-55x55.png" alt="hello" />
<div class="base">
<p class="title">满减活动</p>
<p class="desc">满500元立减90,新用户立减200</p>
</div>
</div>
</li>
</ul>
</div>
<!-- 底部导航上面钩子 -->
{{if isset($shopxo_is_develop) and $shopxo_is_develop eq true and (!isset($is_footer) or $is_footer eq 1)}}
<div class="plugins-tag">
<span>plugins_view_common_footer_top</span>
</div>
{{/if}}
{{if !empty($plugins_view_common_footer_top_data) and is_array($plugins_view_common_footer_top_data)}}
{{foreach $plugins_view_common_footer_top_data as $hook}}
{{if is_string($hook) or is_int($hook)}}
{{$hook|raw}}
{{/if}}
{{/foreach}}
{{/if}}
<!-- 底部导航 -->
......
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
<?php
// +----------------------------------------------------------------------
// | ShopXO 国内领先企业级B2C免费开源电商系统
// +----------------------------------------------------------------------
// | Copyright (c) 2011~2019 http://shopxo.net All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: Devil
// +----------------------------------------------------------------------
namespace app\plugins\footercustomerservice;
use think\Controller;
use app\plugins\footercustomerservice\Service;
use app\service\PluginsService;
/**
* 底部客户服务介绍插件 - 管理
* @author Devil
* @blog http://gong.gg/
* @version 0.0.1
* @datetime 2016-12-01T21:51:08+0800
*/
class Admin extends Controller
{
/**
* 首页
* @author Devil
* @blog http://gong.gg/
* @version 1.0.0
* @datetime 2019-02-07T08:21:54+0800
* @param [array] $params [输入参数]
*/
public function index($params = [])
{
$ret = PluginsService::PluginsData('footercustomerservice', null, false);
if($ret['code'] == 0)
{
// 数据列表
$list = Service::DataList();
$this->assign('data_list', $list['data']);
$this->assign('data', $ret['data']);
return $this->fetch('../../../plugins/view/footercustomerservice/admin/index');
} else {
return $ret['msg'];
}
}
/**
* 编辑页面
* @author Devil
* @blog http://gong.gg/
* @version 1.0.0
* @datetime 2019-02-07T08:21:54+0800
* @param [array] $params [输入参数]
*/
public function saveinfo($params = [])
{
$ret = PluginsService::PluginsData('footercustomerservice', null, false);
if($ret['code'] == 0)
{
// 是否
$is_whether_list = [
0 => array('id' => 0, 'name' => '否', 'checked' => true),
1 => array('id' => 1, 'name' => '是'),
];
$this->assign('is_whether_list', $is_whether_list);
$this->assign('data', $ret['data']);
return $this->fetch('../../../plugins/view/footercustomerservice/admin/saveinfo');
} else {
return $ret['msg'];
}
}
/**
* 数据保存
* @author Devil
* @blog http://gong.gg/
* @version 1.0.0
* @datetime 2019-02-07T08:21:54+0800
* @param [array] $params [输入参数]
*/
public function save($params = [])
{
$list = Service::DataList();
$params['data_list'] = $list['data'];
return PluginsService::PluginsDataSave(['plugins'=>'footercustomerservice', 'data'=>$params]);
}
/**
* 数据列表页面
* @author Devil
* @blog http://gong.gg/
* @version 1.0.0
* @datetime 2019-02-07T08:21:54+0800
* @param [array] $params [输入参数]
*/
public function dataindex($params = [])
{
$list = Service::DataList();
if($list['code'] == 0)
{
$this->assign('data_list', $list['data']);
return $this->fetch('../../../plugins/view/footercustomerservice/admin/dataindex');
} else {
return $list['msg'];
}
}
/**
* 数据列表编辑
* @author Devil
* @blog http://gong.gg/
* @version 1.0.0
* @datetime 2019-02-07T08:21:54+0800
* @param [array] $params [输入参数]
*/
public function datainfo($params = [])
{
// 数据
$data = [];
if(!empty($params['id']))
{
$data_params = [
'get_id' => $params['id'],
];
$ret = Service::DataList($data_params);
$data = empty($ret['data']) ? [] : $ret['data'];
}
$this->assign('data', $data);
return $this->fetch('../../../plugins/view/footercustomerservice/admin/datainfo');
}
/**
* 数据列表保存
* @author Devil
* @blog http://gong.gg/
* @version 1.0.0
* @datetime 2019-02-07T08:21:54+0800
* @param [array] $params [输入参数]
*/
public function datasave($params = [])
{
// 是否ajax请求
if(!IS_AJAX)
{
return $this->error('非法访问');
}
// 开始处理
return Service::DataSave($params);
}
/**
* 数据列表删除
* @author Devil
* @blog http://gong.gg/
* @version 0.0.1
* @datetime 2016-12-15T11:03:30+0800
* @param [array] $params [输入参数]
*/
public function datadelete($params = [])
{
// 是否ajax请求
if(!IS_AJAX)
{
return $this->error('非法访问');
}
// 开始处理
return Service::DataDelete($params);
}
/**
* 数据列表状态更新
* @author Devil
* @blog http://gong.gg/
* @version 0.0.1
* @datetime 2017-01-12T22:23:06+0800
* @param [array] $params [输入参数]
*/
public function datastatusupdate($params = [])
{
// 是否ajax请求
if(!IS_AJAX)
{
return $this->error('非法访问');
}
// 开始处理
return Service::DataStatusUpdate($params);
}
}
?>
\ No newline at end of file
<?php
// +----------------------------------------------------------------------
// | ShopXO 国内领先企业级B2C免费开源电商系统
// +----------------------------------------------------------------------
// | Copyright (c) 2011~2019 http://shopxo.net All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: Devil
// +----------------------------------------------------------------------
namespace app\plugins\footercustomerservice;
use think\Controller;
use app\plugins\footercustomerservice\Service;
use app\service\PluginsService;
/**
* 底部客户服务介绍插件 - 钩子入口
* @author Devil
* @blog http://gong.gg/
* @version 0.0.1
* @datetime 2016-12-01T21:51:08+0800
*/
class Hook extends Controller
{
/**
* 应用响应入口
* @author Devil
* @blog http://gong.gg/
* @version 1.0.0
* @datetime 2019-02-09T14:25:44+0800
* @param [array] $params [输入参数]
*/
public function run($params = [])
{
if(!empty($params['hook_name']))
{
switch($params['hook_name'])
{
// style css
case 'plugins_common_header' :
$ret = $this->StyleCss($params);
break;
// 底部导航上面钩子
case 'plugins_view_common_footer_top' :
$ret = $this->FooterServerData($params);
break;
default :
$ret = '';
}
return $ret;
}
}
/**
* 客户服务数据
* @author Devil
* @blog http://gong.gg/
* @version 1.0.0
* @datetime 2019-02-06T16:16:34+0800
* @param [array] $params [输入参数]
*/
public function FooterServerData($params = [])
{
$ret = $this->IsNormal($params);
if($ret['code'] == 0)
{
$this->assign('data_list', $ret['data']);
return $this->fetch('../../../plugins/view/footercustomerservice/index/content');
}
return '';
}
/**
* css
* @author Devil
* @blog http://gong.gg/
* @version 1.0.0
* @datetime 2019-02-06T16:16:34+0800
* @param [array] $params [输入参数]
*/
public function StyleCss($params = [])
{
$ret = $this->IsNormal($params);
if($ret['code'] == 0)
{
return '<style type="text/css">
.plugins-footercustomerservice-customer-service {
background: #f8f8f8;
padding: 10px 0;
margin-top: 20px;
}
.plugins-footercustomerservice-customer-service .am-gallery-overlay .am-gallery-item img {
width: 50px;
float: left;
}
.plugins-footercustomerservice-customer-service .am-gallery-overlay .am-gallery-item .base {
margin-left: 60px;
}
.plugins-footercustomerservice-customer-service .am-gallery-overlay .am-gallery-item .base .title {
font-weight: 500;
font-size: 16px;
color: #505050;
}
.plugins-footercustomerservice-customer-service .am-gallery-overlay .am-gallery-item .base .desc {
color: #999;
margin-top: 5px;
}
@media only screen and (max-width:1025px) {
.plugins-footercustomerservice-customer-service .am-gallery-overlay .am-gallery-item {
border-bottom: 1px solid #f0f0f0;
padding-bottom: 10px;
}
}
.am-footer-default {
margin-top: 0;
}
</style>';
}
return '';
}
/**
* 是否正常
* @author Devil
* @blog http://gong.gg/
* @version 1.0.0
* @date 2019-04-23
* @desc description
* @param [array] $params [输入参数]
*/
private function IsNormal($params = [])
{
// 当前模块/控制器/方法
$module_name = strtolower(request()->module());
$controller_name = strtolower(request()->controller());
$action_name = strtolower(request()->action());
// 获取应用数据
$ret = PluginsService::PluginsData('footercustomerservice');
if($ret['code'] == 0)
{
// 是否仅首页
if(isset($ret['data']['is_only_home']) && $ret['data']['is_only_home'] == 1)
{
// 非首页则空
if($module_name.$controller_name.$action_name != 'indexindexindex')
{
return DataReturn('仅首页展示', -1);
}
}
}
// 获取图片列表
$ret = Service::DataList();
if($ret['code'] == 0 && !empty($ret['data']))
{
return DataReturn('成功', 0, $ret['data']);
}
return DataReturn('失败', -100);
}
}
?>
\ No newline at end of file
<?php
// +----------------------------------------------------------------------
// | ShopXO 国内领先企业级B2C免费开源电商系统
// +----------------------------------------------------------------------
// | Copyright (c) 2011~2019 http://shopxo.net All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: Devil
// +----------------------------------------------------------------------
namespace app\plugins\footercustomerservice;
use app\service\PluginsService;
use app\service\ResourcesService;
/**
* 底部客户服务介绍服务层
* @author Devil
* @blog http://gong.gg/
* @version 0.0.1
* @datetime 2016-12-01T21:51:08+0800
*/
class Service
{
/**
* 获取数据列表
* @author Devil
* @blog http://gong.gg/
* @version 1.0.0
* @date 2019-04-22
* @desc description
* @param [array] $params [输入参数]
*/
public static function DataList($params = [])
{
$ret = PluginsService::PluginsData('footercustomerservice');
$data = (empty($ret['data']) || empty($ret['data']['data_list'])) ? [] : $ret['data']['data_list'];
if(!empty($data))
{
$common_is_enable_tips = lang('common_is_enable_tips');
$common_is_text_list = lang('common_is_text_list');
foreach($data as &$v)
{
// 是否启用
$v['is_enable_text'] = $common_is_enable_tips[$v['is_enable']]['name'];
// 图片地址
$v['images_url_old'] = $v['images_url'];
$v['images_url'] = ResourcesService::AttachmentPathViewHandle($v['images_url']);
// 时间
$v['operation_time_time'] = empty($v['operation_time']) ? '' : date('Y-m-d H:i:s', $v['operation_time']);
$v['operation_time_date'] = empty($v['operation_time']) ? '' : date('Y-m-d', $v['operation_time']);
}
}
// 是否读取单条
if(!empty($params['get_id']) && isset($data[$params['get_id']]))
{
$data = $data[$params['get_id']];
}
return DataReturn('处理成功', 0, $data);
}
/**
* 数据列表保存
* @author Devil
* @blog http://gong.gg/
* @version 1.0.0
* @date 2019-04-22
* @desc description
* @param [array] $params [输入参数]
*/
public static function DataSave($params = [])
{
// 请求类型
$p = [
[
'checked_type' => 'length',
'key_name' => 'name',
'checked_data' => '1,8',
'error_msg' => '名称长度 1~8 个字符',
],
[
'checked_type' => 'length',
'key_name' => 'desc',
'checked_data' => '30',
'error_msg' => '描述格式最多 30 个字符',
],
[
'checked_type' => 'empty',
'key_name' => 'images_url',
'checked_data' => '255',
'error_msg' => '请上传图片',
],
];
$ret = ParamsChecked($params, $p);
if($ret !== true)
{
return DataReturn($ret, -1);
}
// 附件
$data_fields = ['images_url'];
$attachment = ResourcesService::AttachmentParams($params, $data_fields);
// 数据
$data = [
'name' => $params['name'],
'desc' => $params['desc'],
'images_url' => $attachment['data']['images_url'],
'is_enable' => isset($params['is_enable']) ? intval($params['is_enable']) : 0,
'operation_time' => time(),
];
// 原有数据
$ret = PluginsService::PluginsData('footercustomerservice', null, false);
// 数据id
$data['id'] = (empty($params['id']) || empty($ret['data']) || empty($ret['data']['data_list'][$params['id']])) ? date('YmdHis').GetNumberCode(6) : $params['id'];
$ret['data']['data_list'][$data['id']] = $data;
// 添加最多添加4条
if(empty($params['id']))
{
if(count($ret['data']['data_list']) > 4)
{
return DataReturn('最多添加4条数据', -1);
}
}
// 保存
return PluginsService::PluginsDataSave(['plugins'=>'footercustomerservice', 'data'=>$ret['data']]);
}
/**
* 数据列表删除
* @author Devil
* @blog http://gong.gg/
* @version 1.0.0
* @date 2018-12-18
* @desc description
* @param [array] $params [输入参数]
*/
public static function DataDelete($params = [])
{
// 请求参数
$p = [
[
'checked_type' => 'empty',
'key_name' => 'id',
'error_msg' => '操作id有误',
],
];
$ret = ParamsChecked($params, $p);
if($ret !== true)
{
return DataReturn($ret, -1);
}
// 原有数据
$ret = PluginsService::PluginsData('footercustomerservice', null, false);
$ret['data']['data_list'] = (empty($ret['data']) || empty($ret['data']['data_list'])) ? [] : $ret['data']['data_list'];
// 删除操作
if(isset($ret['data']['data_list'][$params['id']]))
{
unset($ret['data']['data_list'][$params['id']]);
}
// 保存
return PluginsService::PluginsDataSave(['plugins'=>'footercustomerservice', 'data'=>$ret['data']]);
}
/**
* 数据列表删除
* @author Devil
* @blog http://gong.gg/
* @version 1.0.0
* @date 2018-12-18
* @desc description
* @param [array] $params [输入参数]
*/
public static function DataStatusUpdate($params = [])
{
// 请求参数
$p = [
[
'checked_type' => 'empty',
'key_name' => 'id',
'error_msg' => '操作id有误',
],
[
'checked_type' => 'empty',
'key_name' => 'field',
'error_msg' => '操作字段有误',
],
[
'checked_type' => 'in',
'key_name' => 'state',
'checked_data' => [0,1],
'error_msg' => '状态有误',
],
];
$ret = ParamsChecked($params, $p);
if($ret !== true)
{
return DataReturn($ret, -1);
}
// 原有数据
$ret = PluginsService::PluginsData('footercustomerservice', null, false);
$ret['data']['data_list'] = (empty($ret['data']) || empty($ret['data']['data_list'])) ? [] : $ret['data']['data_list'];
// 删除操作
if(isset($ret['data']['data_list'][$params['id']]) && isset($ret['data']['data_list'][$params['id']][$params['field']]))
{
$ret['data']['data_list'][$params['id']][$params['field']] = intval($params['state']);
$ret['data']['data_list'][$params['id']]['operation_time'] = time();
}
// 保存
return PluginsService::PluginsDataSave(['plugins'=>'footercustomerservice', 'data'=>$ret['data']]);
}
}
?>
\ No newline at end of file
{
"base":{
"plugins":"footercustomerservice",
"name":"底部客户服务介绍",
"logo":"\/static\/upload\/images\/plugins_footercustomerservice\/2019\/04\/23\/1555984179784604.jpg",
"author":"Devil",
"author_url":"https:\/\/shopxo.net\/",
"version":"1.0.0",
"desc":"底部客户服务介绍,最多可添加4项",
"apply_terminal":[
"pc",
"h5"
],
"apply_version":[
"1.5.0"
],
"is_home":false
},
"hook":{
"plugins_common_header":[
"app\\plugins\\footercustomerservice\\Hook"
],
"plugins_view_common_footer_top":[
"app\\plugins\\footercustomerservice\\Hook"
]
}
}
\ No newline at end of file
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
......@@ -13,6 +13,7 @@ namespace app\plugins\homemiddleadv;
use think\Controller;
use app\plugins\homemiddleadv\Service;
use app\service\PluginsService;
/**
* 首页中间广告插件 - 钩子入口
* @author Devil
......
......@@ -12,7 +12,6 @@ namespace app\plugins\homemiddleadv;
use app\service\PluginsService;
use app\service\ResourcesService;
use app\service\AnswerService;
/**
* 首页中间广告服务层
......
......@@ -6,7 +6,7 @@
"author":"Devil",
"author_url":"https:\/\/shopxo.net\/",
"version":"1.0.0",
"desc":"首页中间广告,4个推荐位",
"desc":"首页中间广告,推荐位",
"apply_terminal":[
"pc",
"h5"
......
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
......@@ -24,8 +24,7 @@
{{if !empty($express_list)}}
{{foreach $express_list as $express}}
{{if $express.is_enable eq 1}}
<p>{{$express.name}} <input type="text" name="express_ids[{{$express.id}}]" placeholder="快递代号" class="am-radius" value="{{if !empty($data['express_ids'])}}{{$data.express_ids[$express.id]}}{{/if}}"/></p>
<p>{{$express.name}} <input type="text" name="express_ids[{{$express.id}}]" placeholder="快递代号" class="am-radius" value="{{if !empty($data['express_ids']) and isset($data.express_ids[$express.id])}}{{$data.express_ids[$express.id]}}{{/if}}"/></p>
{{/if}}
{{/foreach}}
{{/if}}
......
{{include file="public/header" /}}
<!-- right content start -->
<div class="content-right">
<div class="content">
<legend>
<span class="fs-16">底部客户服务介绍</span>
<a href="{{:PluginsAdminUrl('footercustomerservice', 'admin', 'index')}}" class="fr fs-14 m-t-5 am-icon-mail-reply"> 返回</a>
</legend>
<div class="footercustomerservice-content">
<!-- operation start -->
<div class="am-g m-t-15">
<a href="{{:PluginsAdminUrl('footercustomerservice', 'admin', 'datainfo')}}" class="am-btn am-btn-secondary am-radius am-btn-xs am-icon-plus"> 新增</a>
</div>
<!-- operation end -->
<!-- list start -->
<table class="am-table am-table-striped am-table-hover am-text-middle m-t-10">
<thead>
<tr>
<th>图片</th>
<th>名称</th>
<th>描述</th>
<th class="am-hide-sm-only">是否启用</th>
<th class="am-hide-sm-only">操作时间</th>
<th>操作</th>
</tr>
</thead>
<tbody>
{{if !empty($data_list)}}
{{foreach $data_list as $v}}
<tr id="data-list-{{$v.id}}" {{if $v['is_enable'] eq 0}}class="am-active"{{/if}}>
<td {{if !empty($v['bg_color'])}}style="background-color:{{$v.bg_color}};"{{/if}}>
{{if !empty($v['images_url'])}}
<a href="{{$v['images_url']}}" target="_blank">
<img src="{{$v['images_url']}}" class="am-radius" width="50" />
</a>
{{else /}}
<span class="cr-ddd">暂无图片</span>
{{/if}}
</td>
<td>{{$v.name}}</td>
<td>{{$v.desc}}</td>
<td class="am-hide-sm-only">
<a href="javascript:;" class="am-icon-btn am-icon-check submit-state {{if $v['is_enable'] eq 1}}am-success{{else /}}am-default{{/if}}" data-url="{{:PluginsAdminUrl('footercustomerservice', 'admin', 'datastatusupdate')}}" data-id="{{$v.id}}" data-state="{{$v['is_enable']}}" data-field="is_enable" data-is-update-status="1"></a>
</td>
<td class="am-hide-sm-only">{{$v.operation_time_time}}</td>
<td class="view-operation">
<a href="{{:PluginsAdminUrl('footercustomerservice', 'admin', 'datainfo', ['id'=>$v['id']])}}">
<button class="am-btn am-btn-secondary am-btn-xs am-radius am-icon-edit"> 编辑</button>
</a>
<button class="am-btn am-btn-danger am-btn-xs am-radius am-icon-trash-o submit-delete" data-url="{{:PluginsAdminUrl('footercustomerservice', 'admin', 'datadelete')}}" data-id="{{$v.id}}"> 删除</button>
</td>
</tr>
{{/foreach}}
{{else /}}
<tr><td colspan="6" class="table-no">没有相关数据</td></tr>
{{/if}}
</tbody>
</table>
<!-- list end -->
</div>
</div>
</div>
<!-- right content end -->
<!-- footer start -->
{{include file="public/footer" /}}
<!-- footer end -->
\ No newline at end of file
{{include file="public/header" /}}
<!-- right content start -->
<div class="content-right">
<div class="content">
<legend>
<span class="fs-16">
{{if empty($data['id'])}}
底部客户服务介绍添加
{{else /}}
底部客户服务介绍编辑
{{/if}}
</span>
<a href="{{:PluginsAdminUrl('footercustomerservice', 'admin', 'dataindex')}}" class="fr fs-14 m-t-5 am-icon-mail-reply"> 返回</a>
</legend>
<div class="footercustomerservice-content">
<!-- form start -->
<form class="am-form form-validation view-save" action="{{:PluginsAdminUrl('footercustomerservice', 'admin', 'datasave')}}" method="POST" request-type="ajax-url" request-value="{{:PluginsAdminUrl('footercustomerservice', 'admin', 'dataindex')}}" enctype="multipart/form-data">
<div class="am-form-group">
<label>名称</label>
<input type="text" name="name" placeholder="名称" minlength="1" maxlength="8" data-validation-message="名称格式 1~8 个字符" class="am-radius" {{if !empty($data)}} value="{{$data.name}}"{{/if}} required />
</div>
<div class="am-form-group">
<label>描述</label>
<input type="text" placeholder="描述" name="desc" maxlength="30" data-validation-message="描述格式最多 30 个字符" class="am-radius" {{if !empty($data)}} value="{{$data.desc}}"{{/if}} />
</div>
<div class="am-form-group am-form-file">
<label class="block">图片<span class="am-form-group-label-tips">建议100像数x100像数</span></label>
<ul class="plug-file-upload-view slide-images_url-images-view" data-form-name="images_url" data-max-number="1" data-delete="0" data-dialog-type="images">
<li>
<input type="text" name="images_url" value="{{if !empty($data['images_url'])}}{{$data.images_url}}{{/if}}" data-validation-message="请上传图片" required />
<img src="{{if !empty($data['images_url'])}}{{$data.images_url}}{{else /}}{{$attachment_host}}/static/plugins/images/footercustomerservice/default-images.jpg{{/if}}" />
</li>
</ul>
<div class="plug-file-upload-submit" data-view-tag="ul.slide-images_url-images-view">+上传图片</div>
</div>
<div class="am-form-group">
<label class="block">是否启用</label>
<input name="is_enable" value="1" type="checkbox" data-off-text="否" data-on-text="是" data-size="xs" data-on-color="success" data-off-color="default" data-handle-width="50" data-am-switch {{if (isset($data['is_enable']) and $data['is_enable'] eq 1) or empty($data)}}checked="true"{{/if}} />
</div>
<div class="am-form-group am-form-group-refreshing">
<input type="hidden" name="id" {{if !empty($data)}} value="{{$data.id}}"{{/if}} />
<button type="submit" class="am-btn am-btn-primary am-radius btn-loading-example am-btn-sm w100" data-am-loading="{loadingText:'处理中...'}">保存</button>
</div>
</form>
<!-- form end -->
</div>
</div>
</div>
<!-- right content end -->
<!-- footer start -->
{{include file="public/footer" /}}
<!-- footer end -->
\ No newline at end of file
{{include file="public/header" /}}
<!-- right content start -->
<div class="content-right">
<div class="content">
<legend>
<span class="fs-16">底部客户服务介绍</span>
<a href="{{:MyUrl('admin/pluginsadmin/index')}}" class="fr fs-14 m-t-5 am-icon-mail-reply"> 返回</a>
</legend>
<div class="footercustomerservice-content">
<!-- 基础数据 -->
<div class="am-panel am-panel-secondary footercustomerservice-middle-banner">
<div class="am-panel-hd">
<span class="am-panel-title">基础数据</span>
<a class="am-fr" href="{{:PluginsAdminUrl('footercustomerservice', 'admin', 'saveinfo')}}">编辑</a>
</div>
<div class="am-panel-bd">
<div class="items">
<label>是否仅首页</label>
<div>
{{if isset($data['is_only_home']) and $data['is_only_home'] eq 1}}
{{else /}}
{{/if}}
</div>
</div>
</div>
</div>
<!-- 广告图片 -->
<div class="am-panel am-panel-secondary footercustomerservice-data-list">
<div class="am-panel-hd">
<span class="am-panel-title">服务介绍</span>
<a class="am-fr" href="{{:PluginsAdminUrl('footercustomerservice', 'admin', 'dataindex')}}">编辑</a>
</div>
<div class="am-panel-bd customer-service">
{{if !empty($data_list)}}
<ul data-am-widget="gallery" class="am-gallery am-avg-sm-2 am-avg-md-4 am-avg-lg-4 am-gallery-overlay" data-am-gallery="{}">
{{foreach $data_list as $k=>$v}}
{{if isset($v['is_enable']) and $v['is_enable'] eq 1}}
<li>
<div class="am-gallery-item">
<img src="{{$v.images_url}}" alt="{{$v.name}}" title="{{$v.name}}" />
<div class="base">
<p class="title">{{$v.name}}</p>
{{if !empty($v['desc'])}}
<p class="desc">{{$v.desc}}</p>
{{/if}}
</div>
</div>
</li>
{{/if}}
{{/foreach}}
</ul>
{{else /}}
没有数据
{{/if}}
</div>
</div>
</div>
</div>
</div>
<!-- right content end -->
<!-- footer start -->
{{include file="public/footer" /}}
<!-- footer end -->
\ No newline at end of file
{{include file="public/header" /}}
<!-- right content start -->
<div class="content-right">
<div class="content">
<!-- form start -->
<form class="am-form form-validation view-save" action="{{:PluginsAdminUrl('footercustomerservice', 'admin', 'save')}}" method="POST" request-type="ajax-url" request-value="{{:PluginsAdminUrl('footercustomerservice', 'admin', 'index')}}" enctype="multipart/form-data">
<legend>
<span class="fs-16">底部客户服务介绍</span>
<a href="{{:PluginsAdminUrl('footercustomerservice', 'admin', 'index')}}" class="fr fs-14 m-t-5 am-icon-mail-reply"> 返回</a>
</legend>
<div class="am-form-group">
<label>是否仅首页<span class="am-form-group-label-tips">默认全局</span></label>
<div>
{{foreach $is_whether_list as $v}}
<label class="am-radio-inline m-r-10">
<input type="radio" name="is_only_home" value="{{$v.id}}" {{if isset($data['is_only_home']) and $data['is_only_home'] eq $v['id']}}checked="checked"{{else /}}{{if !isset($data['is_only_home']) and isset($v['checked']) and $v['checked'] eq true}}checked="checked"{{/if}}{{/if}} data-am-ucheck /> {{$v.name}}
</label>
{{/foreach}}
</div>
</div>
<div class="am-form-group am-form-group-refreshing">
<button type="submit" class="am-btn am-btn-primary am-radius btn-loading-example am-btn-sm w100" data-am-loading="{loadingText:'处理中...'}">保存</button>
</div>
</form>
<!-- form end -->
</div>
</div>
<!-- right content end -->
<!-- footer start -->
{{include file="public/footer" /}}
<!-- footer end -->
\ No newline at end of file
{{if !empty($data_list)}}
<div class="plugins-footercustomerservice-customer-service">
<ul data-am-widget="gallery" class="am-gallery am-avg-sm-1 am-avg-md-2 am-avg-lg-4 am-gallery-overlay am-no-layout am-container" data-am-gallery="{}">
{{foreach $data_list as $k=>$v}}
{{if isset($v['is_enable']) and $v['is_enable'] eq 1}}
<li>
<div class="am-gallery-item">
<img src="{{$v.images_url}}" alt="{{$v.name}}" title="{{$v.name}}" />
<div class="base">
<p class="title">{{$v.name}}</p>
{{if !empty($v['desc'])}}
<p class="desc">{{$v.desc}}</p>
{{/if}}
</div>
</div>
</li>
{{/if}}
{{/foreach}}
</ul>
</div>
{{/if}}
\ No newline at end of file
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
......@@ -36,7 +36,7 @@
<td {{if !empty($v['bg_color'])}}style="background-color:{{$v.bg_color}};"{{/if}}>
{{if !empty($v['images_url'])}}
<a href="{{$v['images_url']}}" target="_blank">
<img src="{{$v['images_url']}}" class="am-radius" width="100" height="60" />
<img src="{{$v['images_url']}}" class="am-radius" width="100" />
</a>
{{else /}}
<span class="cr-ddd">暂无图片</span>
......
文件模式从 100644 更改为 100755
......@@ -43,13 +43,15 @@
{{if !empty($data_list)}}
<ul data-am-widget="gallery" class="am-gallery am-avg-sm-2 am-avg-md-4 am-avg-lg-4 am-gallery-overlay am-container" data-am-gallery="{}">
{{foreach $data_list as $k=>$v}}
<li>
<div class="am-gallery-item">
<a href="{{if empty($v['url'])}}javascript:;{{else /}}{{$v.url}}{{/if}}" {{if isset($v['is_new_window_open']) and $v['is_new_window_open'] eq 1}}target="_blank"{{/if}}>
<img src="{{$v.images_url}}" alt="{{$v.name}}" title="{{$v.name}}" />
</a>
</div>
</li>
{{if isset($v['is_enable']) and $v['is_enable'] eq 1}}
<li>
<div class="am-gallery-item">
<a href="{{if empty($v['url'])}}javascript:;{{else /}}{{$v.url}}{{/if}}" {{if isset($v['is_new_window_open']) and $v['is_new_window_open'] eq 1}}target="_blank"{{/if}}>
<img src="{{$v.images_url}}" alt="{{$v.name}}" title="{{$v.name}}" />
</a>
</div>
</li>
{{/if}}
{{/foreach}}
</ul>
{{else /}}
......
......@@ -2,13 +2,15 @@
<div class="am-container plugins-homemiddleadv-home-adv">
<ul data-am-widget="gallery" class="am-gallery am-avg-sm-2 am-avg-md-4 am-avg-lg-4 am-gallery-overlay" data-am-gallery="{}">
{{foreach $data_list as $k=>$v}}
<li>
<div class="am-gallery-item">
<a href="{{if empty($v['url'])}}javascript:;{{else /}}{{$v.url}}{{/if}}" {{if isset($v['is_new_window_open']) and $v['is_new_window_open'] eq 1}}target="_blank"{{/if}}>
<img src="{{$v.images_url}}" alt="{{$v.name}}" title="{{$v.name}}" />
</a>
</div>
</li>
{{if isset($v['is_enable']) and $v['is_enable'] eq 1}}
<li>
<div class="am-gallery-item">
<a href="{{if empty($v['url'])}}javascript:;{{else /}}{{$v.url}}{{/if}}" {{if isset($v['is_new_window_open']) and $v['is_new_window_open'] eq 1}}target="_blank"{{/if}}>
<img src="{{$v.images_url}}" alt="{{$v.name}}" title="{{$v.name}}" />
</a>
</div>
</li>
{{/if}}
{{/foreach}}
</ul>
</div>
......
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
文件模式从 100644 更改为 100755
......@@ -87,6 +87,7 @@ return array (
0 => 'app\\plugins\\expressforkdn\\Hook',
1 => 'app\\plugins\\touristbuy\\Hook',
2 => 'app\\plugins\\homemiddleadv\\Hook',
3 => 'app\\plugins\\footercustomerservice\\Hook',
),
'plugins_admin_common_header' =>
array (
......@@ -137,5 +138,9 @@ return array (
array (
0 => 'app\\plugins\\homemiddleadv\\Hook',
),
'plugins_view_common_footer_top' =>
array (
0 => 'app\\plugins\\footercustomerservice\\Hook',
),
);
?>
\ No newline at end of file
此差异已折叠。
/**
* 首页
*/
.footercustomerservice-content .items {
margin: 10px 0 20px 0;
border-bottom: 1px dashed #f1f1f1;
padding-bottom: 20px;
}
.footercustomerservice-content .items .immages-tag {
text-align: left;
}
.footercustomerservice-content .items .immages-tag img {
max-width: 100%;
border: 1px dashed #eee;
padding: 5px;
}
.footercustomerservice-content .edit-submit {
margin-bottom: 20px;
}
.footercustomerservice-content img {
max-width: 100%;
}
.footercustomerservice-content .am-slider-c3 .am-slider-counter {
background-color: #d13a49;
}
@media only screen and (min-width:640px) {
.footercustomerservice-data-list .am-gallery-overlay .am-gallery-item img {
width: auto;
max-height: 150px;
}
}
/**
* 服务介绍列表
*/
.customer-service .am-gallery-overlay .am-gallery-item img {
width: 50px;
float: left;
}
.customer-service .am-gallery-overlay .am-gallery-item .base {
margin-left: 60px;
}
.customer-service .am-gallery-overlay .am-gallery-item .base .title {
font-weight: 500;
font-size: 16px;
color: #505050;
margin: 0;
}
.customer-service .am-gallery-overlay .am-gallery-item .base .desc {
color: #999;
margin: 5px 0 0 0;
}
.am-footer-default {
margin-top: 0;
}
@media only screen and (max-width:640px) {
.customer-service .am-gallery-overlay .am-gallery-item {
border-bottom: 1px solid #f0f0f0;
padding-bottom: 10px;
}
}
\ No newline at end of file
......@@ -43,7 +43,7 @@
}
/**
* 幻灯片编辑
* 数据列表编辑
*/
ul.plug-file-upload-view li {
width: 160px;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册