From 358a3f4c519df9b3ff55212b3eede2411ce550e5 Mon Sep 17 00:00:00 2001 From: gongfuxiang Date: Tue, 9 May 2017 18:42:27 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=B0=E5=A2=9E=E6=9B=B4=E5=A4=9A=E5=B9=BB?= =?UTF-8?q?=E7=81=AF=E7=89=87=E7=BB=84=E5=BB=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Admin/Controller/ViewController.class.php | 4 +- .../Admin/View/Default/View/Index.html | 8 +- Application/Common/Common/function.php | 25 + Application/Common/Lang/zh-cn.php | 76 +- .../Controller/CommonController.class.php | 2 +- .../Home/View/Default/User/LoginInfo.html | 14 +- ThinkPHP/Library/My/LayoutModule.class.php | 955 +++++++++++++++++- core.php | 2 +- 8 files changed, 1045 insertions(+), 41 deletions(-) diff --git a/Application/Admin/Controller/ViewController.class.php b/Application/Admin/Controller/ViewController.class.php index 8370f21..f0f59cc 100755 --- a/Application/Admin/Controller/ViewController.class.php +++ b/Application/Admin/Controller/ViewController.class.php @@ -126,7 +126,7 @@ class ViewController extends CommonController $article = $this->GetArticleList($lay->GetLayoutMouleWhere($iv)); // 模块数据生成 - $fun = L('common_view_title_style_list')[$iv['title_style']]['fun']; + $fun = GetViewTitleStyleFun($iv['title_style']); $iv['html'] = method_exists($lay, $fun) ? $lay->$fun($article, $iv) : ''; // 重新赋值 @@ -173,7 +173,7 @@ class ViewController extends CommonController $article = $this->GetArticleList($lay->GetLayoutMouleWhere($_POST)); // 模块数据生成 - $fun = L('common_view_title_style_list')[I('title_style')]['fun']; + $fun = GetViewTitleStyleFun(I('title_style')); if(method_exists($lay, $fun)) { $html = $lay->$fun($article, $_POST); diff --git a/Application/Admin/View/Default/View/Index.html b/Application/Admin/View/Default/View/Index.html index 1b0d532..ed43d56 100755 --- a/Application/Admin/View/Default/View/Index.html +++ b/Application/Admin/View/Default/View/Index.html @@ -108,8 +108,12 @@
diff --git a/Application/Common/Common/function.php b/Application/Common/Common/function.php index 90876b4..cb99334 100755 --- a/Application/Common/Common/function.php +++ b/Application/Common/Common/function.php @@ -8,6 +8,31 @@ * @datetime 2016-12-01T21:51:08+0800 */ +/** + * [GetViewTitleStyleFun 获取页面模块标题样式方法名称] + * @author Devil + * @blog http://gong.gg/ + * @version 0.0.1 + * @datetime 2017-05-09T15:20:54+0800 + * @param [int] $value [样式值] + * @return [string] [方法名称] + */ +function GetViewTitleStyleFun($value) +{ + $list = L('common_view_title_style_list'); + foreach($list as $v) + { + foreach($v['item'] as $vs) + { + if($vs['value'] == $value) + { + return $vs['fun']; + } + } + } + return ''; +} + /** * [FileUploadError 文件上传错误校验] * @author Devil diff --git a/Application/Common/Lang/zh-cn.php b/Application/Common/Lang/zh-cn.php index 02cbe25..19874d0 100755 --- a/Application/Common/Lang/zh-cn.php +++ b/Application/Common/Lang/zh-cn.php @@ -219,6 +219,8 @@ return array( 'common_toview_home_text' => '查看首页', 'common_email_send_user_reg_title' => '用户注册', + 'common_layout_slider_more_text' => '了解更多', + // 性别 'common_gender_list' => array( 0 => array('id' => 0, 'name' => '保密', 'checked' => true), @@ -322,22 +324,64 @@ return array( // 页面设置-有效时间 'common_view_title_style_list' => array( - 0 => array('value' => 0, 'fun' => 'ViewTitle', 'name' => '[内置]文章标题', 'checked' => true), - 1 => array('value' => 1, 'fun' => 'ViewTitleAccess', 'name' => '[内置]文章标题+访问数'), - 2 => array('value' => 2, 'fun' => 'ViewTitleCreateTime', 'name' => '[内置]文章标题+发布时间'), - 3 => array('value' => 3, 'fun' => 'ViewTitleAbstract', 'name' => '[内置]文章标题+摘要'), - 4 => array('value' => 4, 'fun' => 'View_Article_Focus', 'name' => '[内置]焦点模式'), - 5 => array('value' => 5, 'fun' => 'ViewTitleAbstractOne', 'name' => '[内置]文章标题(第一条带摘要)'), - 6 => array('value' => 6, 'fun' => 'ViewImagesContent', 'name' => '[内置]文章图文展示'), - 7 => array('value' => 7, 'fun' => 'ViewOneIntroductionTwoTitle', 'name' => '[内置]一简介+两列标题'), - 8 => array('value' => 8, 'fun' => 'ViewImagesSlide', 'name' => '[内置]文章图片幻灯片'), - 9 => array('value' => 9, 'fun' => 'ViewImagesList112', 'name' => '[内置]文章图片列表 sm[1]md[1]lg[2]'), - 10 => array('value' => 10, 'fun' => 'ViewImagesList122', 'name' => '[内置]文章图片列表 sm[1]md[2]lg[2]'), - 11 => array('value' => 11, 'fun' => 'ViewImagesList123', 'name' => '[内置]文章图片列表 sm[1]md[2]lg[3]'), - 12 => array('value' => 12, 'fun' => 'ViewImagesList222', 'name' => '[内置]文章图片列表 sm[2]md[2]lg[2]'), - 13 => array('value' => 13, 'fun' => 'ViewImagesList223', 'name' => '[内置]文章图片列表 sm[2]md[2]lg[3]'), - 14 => array('value' => 14, 'fun' => 'ViewImagesList234', 'name' => '[内置]文章图片列表 sm[2]md[3]lg[4]'), - 15 => array('value' => 15, 'fun' => 'ViewImagesList236', 'name' => '[内置]文章图片列表 sm[2]md[3]lg[6]'), + // 100开始 + array( + 'name' => '标题列表', + 'item' => array( + array('value' => 0, 'fun' => 'ViewTitle', 'name' => '[内置]文章标题', 'checked' => true), + array('value' => 1, 'fun' => 'ViewTitleAccess', 'name' => '[内置]文章标题+访问数'), + array('value' => 2, 'fun' => 'ViewTitleCreateTime', 'name' => '[内置]文章标题+发布时间'), + array('value' => 3, 'fun' => 'ViewTitleAbstract', 'name' => '[内置]文章标题+摘要'), + array('value' => 5, 'fun' => 'ViewTitleAbstractOne', 'name' => '[内置]文章标题(第一条带摘要)'), + array('value' => 7, 'fun' => 'ViewOneIntroductionTwoTitle', 'name' => '[内置]一简介+两列标题'), + ) + ), + // 200开始 + array( + 'name' => '图文', + 'item' => array( + array('value' => 6, 'fun' => 'ViewImagesContent', 'name' => '[内置]文章图文展示'), + ) + ), + // 300开始 + array( + 'name' => '幻灯片', + 'item' => array( + array('value' => 300, 'fun' => 'ViewImagesSlideDefault', 'name' => '[内置]幻灯片默认'), + array('value' => 301, 'fun' => 'ViewImagesSlideDefaultTitle', 'name' => '[内置]幻灯片默认+标题'), + array('value' => 302, 'fun' => 'ViewImagesSlideDefaultMoreImage', 'name' => '[内置]幻灯片默认+多图'), + array('value' => 303, 'fun' => 'ViewImagesSlideDefaultThumbnailImage', 'name' => '[内置]幻灯片默认+缩略图'), + array('value' => 304, 'fun' => 'ViewImagesSlideRoundPoint', 'name' => '[内置]幻灯片+圆形控制点'), + array('value' => 305, 'fun' => 'ViewImagesSlidePartyPoint', 'name' => '[内置]幻灯片+方形控制点'), + array('value' => 306, 'fun' => 'ViewImagesSlideRoundPointBackBlack', 'name' => '[内置]幻灯片+底部黑边圆形控制点'), + array('value' => 307, 'fun' => 'ViewImagesSlideRoundPointBackWhite', 'name' => '[内置]幻灯片+底部白边圆形控制点'), + array('value' => 308, 'fun' => 'ViewImagesSlideLongPoint', 'name' => '[内置]幻灯片+长条等分控制点'), + array('value' => 309, 'fun' => 'ViewImagesSlideSquareArrow', 'name' => '[内置]幻灯片+方形居中左右箭头'), + array('value' => 310, 'fun' => 'ViewImagesSlideRoundArrow', 'name' => '[内置]幻灯片+圆形居中左右箭头'), + array('value' => 311, 'fun' => 'ViewImagesSlideOutsideArrow', 'name' => '[内置]幻灯片+图片外左右箭头'), + array('value' => 312, 'fun' => 'ViewImagesSlideOutsideRoundArrow', 'name' => '[内置]幻灯片+图片外左右圆形箭头'), + array('value' => 313, 'fun' => 'ViewImagesSlideTitleLongPoint', 'name' => '[内置]幻灯片+标题+长条控制点'), + array('value' => 314, 'fun' => 'ViewImagesSlideTitlePartyPoint', 'name' => '[内置]幻灯片+标题+方形控制点'), + array('value' => 8, 'fun' => 'ViewImagesSlideTitleArrow', 'name' => '[内置]幻灯片+标题+居中左右箭头'), + array('value' => 315, 'fun' => 'ViewImagesSlideTitleBottomArrow', 'name' => '[内置]幻灯片+标题+居底左右箭头'), + array('value' => 316, 'fun' => 'ViewImagesSlideTitleBottomRoundArrow', 'name' => '[内置]幻灯片+标题+底部圆形左右箭头'), + array('value' => 317, 'fun' => 'ViewImagesSlideFloatTitleBottomRoundArrow', 'name' => '[内置]幻灯片+浮层标题+底部圆形控制点'), + array('value' => 318, 'fun' => 'ViewImagesSlideTitleThumbnailImageNav', 'name' => '[内置]幻灯片+标题+缩略图导航'), + ) + ), + // 400开始 + array( + 'name' => '图片画廊自适应板块', + 'item' => array( + array('value' => 9, 'fun' => 'ViewImagesList112', 'name' => '[内置]文章图片列表 sm[1]md[1]lg[2]'), + array('value' => 10, 'fun' => 'ViewImagesList122', 'name' => '[内置]文章图片列表 sm[1]md[2]lg[2]'), + array('value' => 11, 'fun' => 'ViewImagesList123', 'name' => '[内置]文章图片列表 sm[1]md[2]lg[3]'), + array('value' => 12, 'fun' => 'ViewImagesList222', 'name' => '[内置]文章图片列表 sm[2]md[2]lg[2]'), + array('value' => 13, 'fun' => 'ViewImagesList223', 'name' => '[内置]文章图片列表 sm[2]md[2]lg[3]'), + array('value' => 14, 'fun' => 'ViewImagesList234', 'name' => '[内置]文章图片列表 sm[2]md[3]lg[4]'), + array('value' => 15, 'fun' => 'ViewImagesList236', 'name' => '[内置]文章图片列表 sm[2]md[3]lg[6]'), + ) + ), ), // 页面设置-打开方式 diff --git a/Application/Home/Controller/CommonController.class.php b/Application/Home/Controller/CommonController.class.php index e053e43..dee57f5 100755 --- a/Application/Home/Controller/CommonController.class.php +++ b/Application/Home/Controller/CommonController.class.php @@ -358,7 +358,7 @@ class CommonController extends Controller $article = $this->GetArticleList($lay->GetLayoutMouleWhere($iv)); // 模块数据生成 - $fun = L('common_view_title_style_list')[$iv['title_style']]['fun']; + $fun = GetViewTitleStyleFun($iv['title_style']); $html = method_exists($lay, $fun) ? $lay->$fun($article, $iv) : ''; // 重新赋值 diff --git a/Application/Home/View/Default/User/LoginInfo.html b/Application/Home/View/Default/User/LoginInfo.html index 80b0651..1f87ba9 100644 --- a/Application/Home/View/Default/User/LoginInfo.html +++ b/Application/Home/View/Default/User/LoginInfo.html @@ -12,13 +12,15 @@
- {{:L('user_login_on_accounts_text')}} - - {{:L('user_login_immediately_reg_text')}} - - {{:L('user_login_immediately_reg_text')}} + + {{:L('user_login_on_accounts_text')}} + + {{:L('user_login_immediately_reg_text')}} + + {{:L('user_login_immediately_reg_text')}} + +
-
diff --git a/ThinkPHP/Library/My/LayoutModule.class.php b/ThinkPHP/Library/My/LayoutModule.class.php index 527495b..df1f9cd 100644 --- a/ThinkPHP/Library/My/LayoutModule.class.php +++ b/ThinkPHP/Library/My/LayoutModule.class.php @@ -71,7 +71,7 @@ class LayoutModule $where['is_enable'] = 1; // 是否强制带图片 - if(isset($data['title_style']) && in_array($data['title_style'], array(6, 8, 9, 10, 11, 12, 13, 14, 15))) + if(isset($data['title_style']) && (in_array($data['title_style'], array(6, 8, 9, 10, 11, 12, 13, 14, 15)) || ($data['title_style'] >= 200))) { $where['image_count'] = array('egt', 1); } @@ -184,12 +184,21 @@ class LayoutModule * @blog http://gong.gg/ * @version 0.0.1 * @datetime 2017-02-22T18:12:12+0800 + * @param [string] $type [类型(slide幻灯片, list列表)] */ - private function GetTitleContent() + private function GetTitleContent($type = '') { if(!empty($this->rules['name']) || !empty($this->rules['right_title'])) { - $this->html .= '
'; + $this->html .= '
'; if(!empty($this->rules['name'])) { $this->html .= '

'.$this->rules['name'].'

'; @@ -602,7 +611,7 @@ class LayoutModule } /** - * [ViewImagesSlide 文章图片幻灯片] + * [ViewImagesSlideDefault 幻灯片+幻灯片默认] * @author Devil * @blog http://gong.gg/ * @version 0.0.1 @@ -610,7 +619,7 @@ class LayoutModule * @param [array] $data [数据列表] * @param [array] $rules [参数规则] */ - public function ViewImagesSlide($data, $rules) + public function ViewImagesSlideDefault($data, $rules) { // 数据初始化 $this->DataInit($data, $rules); @@ -619,7 +628,7 @@ class LayoutModule $this->html = '
'; // 标题 - $this->GetTitleContent(); + $this->GetTitleContent('slide'); // 数据列表 $this->html .= '
'; @@ -627,24 +636,944 @@ class LayoutModule // 自定义内容为空, 并且数据列表不为空 if(empty($this->rules['summary']) && !empty($data)) { - $this->html .= '
'; + } else { + // 自定义内容 + $this->html .= $this->rules['summary']; + } + + // 内容收尾处理 + $this->html .= '
'; + + // 数据返回 + return $this->html; + } + + /** + * [ViewImagesSlideDefaultTitle 幻灯片+幻灯片默认+标题] + * @author Devil + * @blog http://gong.gg/ + * @version 0.0.1 + * @datetime 2017-02-20T18:06:08+0800 + * @param [array] $data [数据列表] + * @param [array] $rules [参数规则] + */ + public function ViewImagesSlideDefaultTitle($data, $rules) + { + // 数据初始化 + $this->DataInit($data, $rules); + + // 开始处理数据 + $this->html = '
'; + + // 标题 + $this->GetTitleContent('slide'); + + // 数据列表 + $this->html .= '
'; + + // 自定义内容为空, 并且数据列表不为空 + if(empty($this->rules['summary']) && !empty($data)) + { + $this->html .= '
'; + } else { + // 自定义内容 + $this->html .= $this->rules['summary']; + } + + // 内容收尾处理 + $this->html .= '
'; + + // 数据返回 + return $this->html; + } + + /** + * [ViewImagesSlideDefaultMoreImage 幻灯片+幻灯片默认+多图] + * @author Devil + * @blog http://gong.gg/ + * @version 0.0.1 + * @datetime 2017-02-20T18:06:08+0800 + * @param [array] $data [数据列表] + * @param [array] $rules [参数规则] + */ + public function ViewImagesSlideDefaultMoreImage($data, $rules) + { + // 数据初始化 + $this->DataInit($data, $rules); + + // 开始处理数据 + $this->html = '
'; + + // 标题 + $this->GetTitleContent('slide'); + + // 数据列表 + $this->html .= '
'; + + // 自定义内容为空, 并且数据列表不为空 + if(empty($this->rules['summary']) && !empty($data)) + { + $this->html .= '
'; + } else { + // 自定义内容 + $this->html .= $this->rules['summary']; + } + + // 内容收尾处理 + $this->html .= '
'; + + // 数据返回 + return $this->html; + } + + /** + * [ViewImagesSlideDefaultThumbnailImage 幻灯片+缩略图] + * @author Devil + * @blog http://gong.gg/ + * @version 0.0.1 + * @datetime 2017-02-20T18:06:08+0800 + * @param [array] $data [数据列表] + * @param [array] $rules [参数规则] + */ + public function ViewImagesSlideDefaultThumbnailImage($data, $rules) + { + // 数据初始化 + $this->DataInit($data, $rules); + + // 开始处理数据 + $this->html = '
'; + + // 标题 + $this->GetTitleContent('slide'); + + // 数据列表 + $this->html .= '
'; + + // 自定义内容为空, 并且数据列表不为空 + if(empty($this->rules['summary']) && !empty($data)) + { + $this->html .= '
'; + } else { + // 自定义内容 + $this->html .= $this->rules['summary']; + } + + // 内容收尾处理 + $this->html .= '
'; + + // 数据返回 + return $this->html; + } + + /** + * [ViewImagesSlideRoundPoint 幻灯片+圆形控制点] + * @author Devil + * @blog http://gong.gg/ + * @version 0.0.1 + * @datetime 2017-02-20T18:06:08+0800 + * @param [array] $data [数据列表] + * @param [array] $rules [参数规则] + */ + public function ViewImagesSlideRoundPoint($data, $rules) + { + // 数据初始化 + $this->DataInit($data, $rules); + + // 开始处理数据 + $this->html = '
'; + + // 标题 + $this->GetTitleContent('slide'); + + // 数据列表 + $this->html .= '
'; + + // 自定义内容为空, 并且数据列表不为空 + if(empty($this->rules['summary']) && !empty($data)) + { + $this->html .= '
'; + } else { + // 自定义内容 + $this->html .= $this->rules['summary']; + } + + // 内容收尾处理 + $this->html .= '
'; + + // 数据返回 + return $this->html; + } + + /** + * [ViewImagesSlidePartyPoint 幻灯片+方形控制点] + * @author Devil + * @blog http://gong.gg/ + * @version 0.0.1 + * @datetime 2017-02-20T18:06:08+0800 + * @param [array] $data [数据列表] + * @param [array] $rules [参数规则] + */ + public function ViewImagesSlidePartyPoint($data, $rules) + { + // 数据初始化 + $this->DataInit($data, $rules); + + // 开始处理数据 + $this->html = '
'; + + // 标题 + $this->GetTitleContent('slide'); + + // 数据列表 + $this->html .= '
'; + + // 自定义内容为空, 并且数据列表不为空 + if(empty($this->rules['summary']) && !empty($data)) + { + $this->html .= '
'; + } else { + // 自定义内容 + $this->html .= $this->rules['summary']; + } + + // 内容收尾处理 + $this->html .= '
'; + + // 数据返回 + return $this->html; + } + + /** + * [ViewImagesSlideRoundPointBackBlack 幻灯片+底部黑边圆形控制点] + * @author Devil + * @blog http://gong.gg/ + * @version 0.0.1 + * @datetime 2017-02-20T18:06:08+0800 + * @param [array] $data [数据列表] + * @param [array] $rules [参数规则] + */ + public function ViewImagesSlideRoundPointBackBlack($data, $rules) + { + // 数据初始化 + $this->DataInit($data, $rules); + + // 开始处理数据 + $this->html = '
'; + + // 标题 + $this->GetTitleContent('slide'); + + // 数据列表 + $this->html .= '
'; + + // 自定义内容为空, 并且数据列表不为空 + if(empty($this->rules['summary']) && !empty($data)) + { + $this->html .= '
'; } else { // 自定义内容 $this->html .= $this->rules['summary']; } // 内容收尾处理 - $this->html .= '
'; + $this->html .= '
'; + + // 数据返回 + return $this->html; + } + + /** + * [ViewImagesSlideRoundPointBackWhite 幻灯片+底部白边圆形控制点] + * @author Devil + * @blog http://gong.gg/ + * @version 0.0.1 + * @datetime 2017-02-20T18:06:08+0800 + * @param [array] $data [数据列表] + * @param [array] $rules [参数规则] + */ + public function ViewImagesSlideRoundPointBackWhite($data, $rules) + { + // 数据初始化 + $this->DataInit($data, $rules); + + // 开始处理数据 + $this->html = '
'; + + // 标题 + $this->GetTitleContent('slide'); + + // 数据列表 + $this->html .= '
'; + + // 自定义内容为空, 并且数据列表不为空 + if(empty($this->rules['summary']) && !empty($data)) + { + $this->html .= '
'; + } else { + // 自定义内容 + $this->html .= $this->rules['summary']; + } + + // 内容收尾处理 + $this->html .= '
'; + + // 数据返回 + return $this->html; + } + + /** + * [ViewImagesSlideLongPoint 幻灯片+长条等分控制点] + * @author Devil + * @blog http://gong.gg/ + * @version 0.0.1 + * @datetime 2017-02-20T18:06:08+0800 + * @param [array] $data [数据列表] + * @param [array] $rules [参数规则] + */ + public function ViewImagesSlideLongPoint($data, $rules) + { + // 数据初始化 + $this->DataInit($data, $rules); + + // 开始处理数据 + $this->html = '
'; + + // 标题 + $this->GetTitleContent('slide'); + + // 数据列表 + $this->html .= '
'; + + // 自定义内容为空, 并且数据列表不为空 + if(empty($this->rules['summary']) && !empty($data)) + { + $this->html .= '
'; + } else { + // 自定义内容 + $this->html .= $this->rules['summary']; + } + + // 内容收尾处理 + $this->html .= '
'; + + // 数据返回 + return $this->html; + } + + /** + * [ViewImagesSlideSquareArrow 幻灯片+方形居中左右箭头] + * @author Devil + * @blog http://gong.gg/ + * @version 0.0.1 + * @datetime 2017-02-20T18:06:08+0800 + * @param [array] $data [数据列表] + * @param [array] $rules [参数规则] + */ + public function ViewImagesSlideSquareArrow($data, $rules) + { + // 数据初始化 + $this->DataInit($data, $rules); + + // 开始处理数据 + $this->html = '
'; + + // 标题 + $this->GetTitleContent('slide'); + + // 数据列表 + $this->html .= '
'; + + // 自定义内容为空, 并且数据列表不为空 + if(empty($this->rules['summary']) && !empty($data)) + { + $this->html .= '
'; + } else { + // 自定义内容 + $this->html .= $this->rules['summary']; + } + + // 内容收尾处理 + $this->html .= '
'; + + // 数据返回 + return $this->html; + } + + /** + * [ViewImagesSlideRoundArrow 幻灯片+圆形居中左右箭头] + * @author Devil + * @blog http://gong.gg/ + * @version 0.0.1 + * @datetime 2017-02-20T18:06:08+0800 + * @param [array] $data [数据列表] + * @param [array] $rules [参数规则] + */ + public function ViewImagesSlideRoundArrow($data, $rules) + { + // 数据初始化 + $this->DataInit($data, $rules); + + // 开始处理数据 + $this->html = '
'; + + // 标题 + $this->GetTitleContent('slide'); + + // 数据列表 + $this->html .= '
'; + + // 自定义内容为空, 并且数据列表不为空 + if(empty($this->rules['summary']) && !empty($data)) + { + $this->html .= '
'; + } else { + // 自定义内容 + $this->html .= $this->rules['summary']; + } + + // 内容收尾处理 + $this->html .= '
'; + + // 数据返回 + return $this->html; + } + + /** + * [ViewImagesSlideOutsideArrow 幻灯片+图片外左右箭头] + * @author Devil + * @blog http://gong.gg/ + * @version 0.0.1 + * @datetime 2017-02-20T18:06:08+0800 + * @param [array] $data [数据列表] + * @param [array] $rules [参数规则] + */ + public function ViewImagesSlideOutsideArrow($data, $rules) + { + // 数据初始化 + $this->DataInit($data, $rules); + + // 开始处理数据 + $this->html = '
'; + + // 标题 + $this->GetTitleContent('slide'); + + // 数据列表 + $this->html .= '
'; + + // 自定义内容为空, 并且数据列表不为空 + if(empty($this->rules['summary']) && !empty($data)) + { + $this->html .= '
'; + } else { + // 自定义内容 + $this->html .= $this->rules['summary']; + } + + // 内容收尾处理 + $this->html .= '
'; + + // 数据返回 + return $this->html; + } + + /** + * [ViewImagesSlideOutsideRoundArrow 幻灯片+图片外左右圆形箭头] + * @author Devil + * @blog http://gong.gg/ + * @version 0.0.1 + * @datetime 2017-02-20T18:06:08+0800 + * @param [array] $data [数据列表] + * @param [array] $rules [参数规则] + */ + public function ViewImagesSlideOutsideRoundArrow($data, $rules) + { + // 数据初始化 + $this->DataInit($data, $rules); + + // 开始处理数据 + $this->html = '
'; + + // 标题 + $this->GetTitleContent('slide'); + + // 数据列表 + $this->html .= '
'; + + // 自定义内容为空, 并且数据列表不为空 + if(empty($this->rules['summary']) && !empty($data)) + { + $this->html .= '
'; + } else { + // 自定义内容 + $this->html .= $this->rules['summary']; + } + + // 内容收尾处理 + $this->html .= '
'; + + // 数据返回 + return $this->html; + } + + /** + * [ViewImagesSlideTitleLongPoint 幻灯片+标题+长条控制点] + * @author Devil + * @blog http://gong.gg/ + * @version 0.0.1 + * @datetime 2017-02-20T18:06:08+0800 + * @param [array] $data [数据列表] + * @param [array] $rules [参数规则] + */ + public function ViewImagesSlideTitleLongPoint($data, $rules) + { + // 数据初始化 + $this->DataInit($data, $rules); + + // 开始处理数据 + $this->html = '
'; + + // 标题 + $this->GetTitleContent('slide'); + + // 数据列表 + $this->html .= '
'; + + // 自定义内容为空, 并且数据列表不为空 + if(empty($this->rules['summary']) && !empty($data)) + { + $this->html .= '
'; + } else { + // 自定义内容 + $this->html .= $this->rules['summary']; + } + + // 内容收尾处理 + $this->html .= '
'; + + // 数据返回 + return $this->html; + } + + /** + * [ViewImagesSlideTitlePartyPoint 幻灯片+标题+方形控制点] + * @author Devil + * @blog http://gong.gg/ + * @version 0.0.1 + * @datetime 2017-02-20T18:06:08+0800 + * @param [array] $data [数据列表] + * @param [array] $rules [参数规则] + */ + public function ViewImagesSlideTitlePartyPoint($data, $rules) + { + // 数据初始化 + $this->DataInit($data, $rules); + + // 开始处理数据 + $this->html = '
'; + + // 标题 + $this->GetTitleContent('slide'); + + // 数据列表 + $this->html .= '
'; + + // 自定义内容为空, 并且数据列表不为空 + if(empty($this->rules['summary']) && !empty($data)) + { + $this->html .= '
'; + } else { + // 自定义内容 + $this->html .= $this->rules['summary']; + } + + // 内容收尾处理 + $this->html .= '
'; + + // 数据返回 + return $this->html; + } + + /** + * [ViewImagesSlideTitleArrow 幻灯片+标题+居中左右箭头] + * @author Devil + * @blog http://gong.gg/ + * @version 0.0.1 + * @datetime 2017-02-20T18:06:08+0800 + * @param [array] $data [数据列表] + * @param [array] $rules [参数规则] + */ + public function ViewImagesSlideTitleArrow($data, $rules) + { + // 数据初始化 + $this->DataInit($data, $rules); + + // 开始处理数据 + $this->html = '
'; + + // 标题 + $this->GetTitleContent('slide'); + + // 数据列表 + $this->html .= '
'; + + // 自定义内容为空, 并且数据列表不为空 + if(empty($this->rules['summary']) && !empty($data)) + { + $this->html .= '
    '; + $count = count($data); + foreach($data as $k=>$v) + { + // 内容 + $this->html .= '
  • blank.' title="'.$v['title'].'">'.$v['title'].''; + $this->html .= '
    '.($k+1).'/'.$count.'
    '.$v['title'].'
    '; + $this->html .= '
  • '; + } + $this->html .= '
'; + } else { + // 自定义内容 + $this->html .= $this->rules['summary']; + } + + // 内容收尾处理 + $this->html .= '
'; + + // 数据返回 + return $this->html; + } + + /** + * [ViewImagesSlideTitleBottomArrow 幻灯片+标题+居底左右箭头] + * @author Devil + * @blog http://gong.gg/ + * @version 0.0.1 + * @datetime 2017-02-20T18:06:08+0800 + * @param [array] $data [数据列表] + * @param [array] $rules [参数规则] + */ + public function ViewImagesSlideTitleBottomArrow($data, $rules) + { + // 数据初始化 + $this->DataInit($data, $rules); + + // 开始处理数据 + $this->html = '
'; + + // 标题 + $this->GetTitleContent('slide'); + + // 数据列表 + $this->html .= '
'; + + // 自定义内容为空, 并且数据列表不为空 + if(empty($this->rules['summary']) && !empty($data)) + { + $this->html .= '
'; + } else { + // 自定义内容 + $this->html .= $this->rules['summary']; + } + + // 内容收尾处理 + $this->html .= '
'; + + // 数据返回 + return $this->html; + } + + /** + * [ViewImagesSlideTitleBottomRoundArrow 幻灯片+标题+底部圆形左右箭头] + * @author Devil + * @blog http://gong.gg/ + * @version 0.0.1 + * @datetime 2017-02-20T18:06:08+0800 + * @param [array] $data [数据列表] + * @param [array] $rules [参数规则] + */ + public function ViewImagesSlideTitleBottomRoundArrow($data, $rules) + { + // 数据初始化 + $this->DataInit($data, $rules); + + // 开始处理数据 + $this->html = '
'; + + // 标题 + $this->GetTitleContent('slide'); + + // 数据列表 + $this->html .= '
'; + + // 自定义内容为空, 并且数据列表不为空 + if(empty($this->rules['summary']) && !empty($data)) + { + $more = L('common_layout_slider_more_text'); + $this->html .= '
'; + } else { + // 自定义内容 + $this->html .= $this->rules['summary']; + } + + // 内容收尾处理 + $this->html .= '
'; + + // 数据返回 + return $this->html; + } + + /** + * [ViewImagesSlideFloatTitleBottomRoundArrow 幻灯片+标题+底部圆形控制点] + * @author Devil + * @blog http://gong.gg/ + * @version 0.0.1 + * @datetime 2017-02-20T18:06:08+0800 + * @param [array] $data [数据列表] + * @param [array] $rules [参数规则] + */ + public function ViewImagesSlideFloatTitleBottomRoundArrow($data, $rules) + { + // 数据初始化 + $this->DataInit($data, $rules); + + // 开始处理数据 + $this->html = '
'; + + // 标题 + $this->GetTitleContent('slide'); + + // 数据列表 + $this->html .= '
'; + + // 自定义内容为空, 并且数据列表不为空 + if(empty($this->rules['summary']) && !empty($data)) + { + $more = L('common_layout_slider_more_text'); + $this->html .= '
'; + } else { + // 自定义内容 + $this->html .= $this->rules['summary']; + } + + // 内容收尾处理 + $this->html .= '
'; + + // 数据返回 + return $this->html; + } + + /** + * [ViewImagesSlideTitleThumbnailImageNav 幻灯片+标题+缩略图导航] + * @author Devil + * @blog http://gong.gg/ + * @version 0.0.1 + * @datetime 2017-02-20T18:06:08+0800 + * @param [array] $data [数据列表] + * @param [array] $rules [参数规则] + */ + public function ViewImagesSlideTitleThumbnailImageNav($data, $rules) + { + // 数据初始化 + $this->DataInit($data, $rules); + + // 开始处理数据 + $this->html = '
'; + + // 标题 + $this->GetTitleContent('slide'); + + // 数据列表 + $this->html .= '
'; + + // 自定义内容为空, 并且数据列表不为空 + if(empty($this->rules['summary']) && !empty($data)) + { + $this->html .= '
'; + } else { + // 自定义内容 + $this->html .= $this->rules['summary']; + } + + // 内容收尾处理 + $this->html .= '
'; // 数据返回 return $this->html; diff --git a/core.php b/core.php index 1d6d228..1837a4d 100755 --- a/core.php +++ b/core.php @@ -38,7 +38,7 @@ if(is_dir("./Install") && !file_exists("./Install/install.lock")) if(version_compare(PHP_VERSION,'5.3.0','<')) die('require PHP > 5.3.0 !'); // 开启调试模式 建议开发阶段开启 部署阶段注释或者设为false -define('APP_DEBUG', false); +define('APP_DEBUG', true); // 分之模式,master,develop,test,debug define('APP_STATUS', 'master'); -- GitLab