作者 景龙
1 个管道 的构建 通过 耗费 0 秒

修改点赞相反

@@ -51,16 +51,19 @@ class IndexController extends HomeBaseController @@ -51,16 +51,19 @@ class IndexController extends HomeBaseController
51 51
52 //星享体验 52 //星享体验
53 $res_month = $this->getMonthArticle(); 53 $res_month = $this->getMonthArticle();
  54 + $month = [];
54 foreach($res_month['data'] as &$value){ 55 foreach($res_month['data'] as &$value){
  56 + $month[$value['month']]['id'] = $value['id'];
  57 + $month[$value['month']]['month'] = $value['month'];
  58 + $month[$value['month']]['post_title'] = $value['post_title'];
  59 + $month[$value['month']]['index_thumbnail'] = $value['index_thumbnail'];
55 foreach($res_month['category_name'] as $value1){ 60 foreach($res_month['category_name'] as $value1){
56 if($value['id'] == $value1['post_id']){ 61 if($value['id'] == $value1['post_id']){
57 - $value['category_name'] = $value1['name']; 62 + $month[$value['month']]['category_name'] = $value1['name'];
58 } 63 }
59 } 64 }
60 } 65 }
61 - $last_names = array_column($res_month['data'],'month');  
62 - array_multisort($last_names,SORT_ASC,$res_month['data']);  
63 - $this->assign('res_month',$res_month['data']); 66 + $this->assign('res_month',$month);
64 67
65 //星域秀场->星球影院 68 //星域秀场->星球影院
66 $position = CityCategoryModel::xqyy; 69 $position = CityCategoryModel::xqyy;
@@ -231,18 +234,14 @@ class IndexController extends HomeBaseController @@ -231,18 +234,14 @@ class IndexController extends HomeBaseController
231 ->select() 234 ->select()
232 ->toArray(); 235 ->toArray();
233 $c_id = array_column($category_id,'id'); 236 $c_id = array_column($category_id,'id');
234 - //查询文章id  
235 - $post_id = Db::table($pre.'portal_category_post')  
236 - ->whereIn('category_id',$c_id)  
237 - ->field('post_id')  
238 - ->select()  
239 - ->toArray();  
240 - $post_id = array_column($post_id,'post_id');  
241 //查询文章 237 //查询文章
242 - $res = Db::table($pre.'portal_post')  
243 - ->whereIn('id',$post_id)  
244 - ->where('delete_time', 0)  
245 - ->field('id,month,post_title,index_thumbnail') 238 + $res = Db::name('portal_post')
  239 + ->alias('p')
  240 + ->join('portal_category_post c','p.id = c.post_id','LEFT')
  241 + ->whereIn('c.category_id',$c_id)
  242 + ->where('p.is_show',1)
  243 + ->where('p.delete_time', 0)
  244 + ->field('p.id,p.month,p.post_title,p.index_thumbnail')
246 ->order('weigh desc') 245 ->order('weigh desc')
247 ->group('month') 246 ->group('month')
248 ->select() 247 ->select()
@@ -57,6 +57,14 @@ @@ -57,6 +57,14 @@
57 </td> 57 </td>
58 </tr> 58 </tr>
59 <tr> 59 <tr>
  60 + <th>是否显示首页<span class="form-required">*</span></th>
  61 + <td>
  62 + 否:<input class="" type="radio" name="post[is_show]" checked value="0"/>
  63 + &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  64 + 是:<input class="" type="radio" name="post[is_show]" value="1"/>
  65 + </td>
  66 + </tr>
  67 + <tr>
60 <th>简介<span class="form-required">*</span></th> 68 <th>简介<span class="form-required">*</span></th>
61 <td> 69 <td>
62 <textarea class="form-control" required name="post[post_excerpt]" style="height: 50px;" 70 <textarea class="form-control" required name="post[post_excerpt]" style="height: 50px;"
@@ -40,7 +40,7 @@ @@ -40,7 +40,7 @@
40 <div class="col-md-9"> 40 <div class="col-md-9">
41 <table class="table table-bordered"> 41 <table class="table table-bordered">
42 <tr class="city" id="city1"> 42 <tr class="city" id="city1">
43 - <th width="100">城市分类<span class="form-required">*</span></th> 43 + <th width="150">城市分类<span class="form-required">*</span></th>
44 <td> 44 <td>
45 <select class="form-control check_city" name="post[city_id]" id="input-parent" style="width:400px;"> 45 <select class="form-control check_city" name="post[city_id]" id="input-parent" style="width:400px;">
46 <option value="">请选择城市</option> 46 <option value="">请选择城市</option>
@@ -61,6 +61,14 @@ @@ -61,6 +61,14 @@
61 </td> 61 </td>
62 </tr> 62 </tr>
63 <tr> 63 <tr>
  64 + <th>是否显示首页<span class="form-required">*</span></th>
  65 + <td>
  66 + 否:<input class="" type="radio" name="post[is_show]" value="0" <eq name="0" value="$post.is_show">checked</eq>/>
  67 + &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  68 + 是:<input class="" type="radio" name="post[is_show]" value="1" <eq name="1" value="$post.is_show">checked</eq>/>
  69 + </td>
  70 + </tr>
  71 + <tr>
64 <th>简介<span class="form-required">*</span></th> 72 <th>简介<span class="form-required">*</span></th>
65 <td> 73 <td>
66 <textarea class="form-control" required name="post[post_excerpt]" style="height: 50px;" 74 <textarea class="form-control" required name="post[post_excerpt]" style="height: 50px;"
@@ -45,6 +45,7 @@ @@ -45,6 +45,7 @@
45 <!--</notempty>--> 45 <!--</notempty>-->
46 <th width="50">ID</th> 46 <th width="50">ID</th>
47 <th width="400">标题</th> 47 <th width="400">标题</th>
  48 + <th width="200">是否显示首页</th>
48 <th width="100">月份</th> 49 <th width="100">月份</th>
49 <th width="100">缩略图</th> 50 <th width="100">缩略图</th>
50 <th width="80">所属城市</th> 51 <th width="80">所属城市</th>
@@ -75,6 +76,17 @@ @@ -75,6 +76,17 @@
75 {$vo.post_title} 76 {$vo.post_title}
76 </notempty> 77 </notempty>
77 </td> 78 </td>
  79 + <td>
  80 + <empty name="vo.is_show">
  81 + <span class="label label-default">
  82 + 隐藏
  83 + </span>
  84 + <else/>
  85 + <span class="label label-success">
  86 + 显示
  87 + </span>
  88 + </empty>
  89 + </td>
78 <td>{$vo.month}</td> 90 <td>{$vo.month}</td>
79 <td> 91 <td>
80 <notempty name="vo.more.thumbnail"> 92 <notempty name="vo.more.thumbnail">
@@ -57,6 +57,14 @@ @@ -57,6 +57,14 @@
57 </td> 57 </td>
58 </tr> 58 </tr>
59 <tr> 59 <tr>
  60 + <th>是否显示首页<span class="form-required">*</span></th>
  61 + <td>
  62 + 否:<input class="" type="radio" name="post[is_show]" checked value="0"/>
  63 + &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  64 + 是:<input class="" type="radio" name="post[is_show]" value="1"/>
  65 + </td>
  66 + </tr>
  67 + <tr>
60 <th>简介<span class="form-required">*</span></th> 68 <th>简介<span class="form-required">*</span></th>
61 <td> 69 <td>
62 <textarea class="form-control" required name="post[post_excerpt]" style="height: 50px;" 70 <textarea class="form-control" required name="post[post_excerpt]" style="height: 50px;"
@@ -40,7 +40,7 @@ @@ -40,7 +40,7 @@
40 <div class="col-md-9"> 40 <div class="col-md-9">
41 <table class="table table-bordered"> 41 <table class="table table-bordered">
42 <tr class="city" id="city1"> 42 <tr class="city" id="city1">
43 - <th width="100">城市分类<span class="form-required">*</span></th> 43 + <th width="150">城市分类<span class="form-required">*</span></th>
44 <td> 44 <td>
45 <select class="form-control check_city" name="post[city_id]" id="input-parent" style="width:400px;"> 45 <select class="form-control check_city" name="post[city_id]" id="input-parent" style="width:400px;">
46 <option value="">请选择城市</option> 46 <option value="">请选择城市</option>
@@ -61,6 +61,14 @@ @@ -61,6 +61,14 @@
61 </td> 61 </td>
62 </tr> 62 </tr>
63 <tr> 63 <tr>
  64 + <th>是否显示首页<span class="form-required">*</span></th>
  65 + <td>
  66 + 否:<input class="" type="radio" name="post[is_show]" value="0" <eq name="0" value="$post.is_show">checked</eq>/>
  67 + &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  68 + 是:<input class="" type="radio" name="post[is_show]" value="1" <eq name="1" value="$post.is_show">checked</eq>/>
  69 + </td>
  70 + </tr>
  71 + <tr>
64 <th>简介<span class="form-required">*</span></th> 72 <th>简介<span class="form-required">*</span></th>
65 <td> 73 <td>
66 <textarea class="form-control" required name="post[post_excerpt]" style="height: 50px;" 74 <textarea class="form-control" required name="post[post_excerpt]" style="height: 50px;"
@@ -45,6 +45,7 @@ @@ -45,6 +45,7 @@
45 <!--</notempty>--> 45 <!--</notempty>-->
46 <th width="50">ID</th> 46 <th width="50">ID</th>
47 <th width="400">标题</th> 47 <th width="400">标题</th>
  48 + <th width="200">是否显示首页</th>
48 <th width="100">月份</th> 49 <th width="100">月份</th>
49 <th width="100">缩略图</th> 50 <th width="100">缩略图</th>
50 <th width="80">所属城市</th> 51 <th width="80">所属城市</th>
@@ -75,6 +76,17 @@ @@ -75,6 +76,17 @@
75 {$vo.post_title} 76 {$vo.post_title}
76 </notempty> 77 </notempty>
77 </td> 78 </td>
  79 + <td>
  80 + <empty name="vo.is_show">
  81 + <span class="label label-default">
  82 + 隐藏
  83 + </span>
  84 + <else/>
  85 + <span class="label label-success">
  86 + 显示
  87 + </span>
  88 + </empty>
  89 + </td>
78 <td>{$vo.month}</td> 90 <td>{$vo.month}</td>
79 <td> 91 <td>
80 <notempty name="vo.more.thumbnail"> 92 <notempty name="vo.more.thumbnail">
@@ -57,6 +57,14 @@ @@ -57,6 +57,14 @@
57 </td> 57 </td>
58 </tr> 58 </tr>
59 <tr> 59 <tr>
  60 + <th>是否显示首页<span class="form-required">*</span></th>
  61 + <td>
  62 + 否:<input class="" type="radio" name="post[is_show]" checked value="0"/>
  63 + &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  64 + 是:<input class="" type="radio" name="post[is_show]" value="1"/>
  65 + </td>
  66 + </tr>
  67 + <tr>
60 <th>简介<span class="form-required">*</span></th> 68 <th>简介<span class="form-required">*</span></th>
61 <td> 69 <td>
62 <textarea class="form-control" required name="post[post_excerpt]" style="height: 50px;" 70 <textarea class="form-control" required name="post[post_excerpt]" style="height: 50px;"
@@ -40,7 +40,7 @@ @@ -40,7 +40,7 @@
40 <div class="col-md-9"> 40 <div class="col-md-9">
41 <table class="table table-bordered"> 41 <table class="table table-bordered">
42 <tr class="city" id="city1"> 42 <tr class="city" id="city1">
43 - <th width="100">城市分类<span class="form-required">*</span></th> 43 + <th width="150">城市分类<span class="form-required">*</span></th>
44 <td> 44 <td>
45 <select class="form-control check_city" name="post[city_id]" id="input-parent" style="width:400px;"> 45 <select class="form-control check_city" name="post[city_id]" id="input-parent" style="width:400px;">
46 <option value="">请选择城市</option> 46 <option value="">请选择城市</option>
@@ -61,6 +61,14 @@ @@ -61,6 +61,14 @@
61 </td> 61 </td>
62 </tr> 62 </tr>
63 <tr> 63 <tr>
  64 + <th>是否显示首页<span class="form-required">*</span></th>
  65 + <td>
  66 + 否:<input class="" type="radio" name="post[is_show]" value="0" <eq name="0" value="$post.is_show">checked</eq>/>
  67 + &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  68 + 是:<input class="" type="radio" name="post[is_show]" value="1" <eq name="1" value="$post.is_show">checked</eq>/>
  69 + </td>
  70 + </tr>
  71 + <tr>
64 <th>简介<span class="form-required">*</span></th> 72 <th>简介<span class="form-required">*</span></th>
65 <td> 73 <td>
66 <textarea class="form-control" required name="post[post_excerpt]" style="height: 50px;" 74 <textarea class="form-control" required name="post[post_excerpt]" style="height: 50px;"
@@ -45,6 +45,7 @@ @@ -45,6 +45,7 @@
45 <!--</notempty>--> 45 <!--</notempty>-->
46 <th width="50">ID</th> 46 <th width="50">ID</th>
47 <th width="400">标题</th> 47 <th width="400">标题</th>
  48 + <th width="200">是否显示首页</th>
48 <th width="100">月份</th> 49 <th width="100">月份</th>
49 <th width="100">缩略图</th> 50 <th width="100">缩略图</th>
50 <th width="80">所属城市</th> 51 <th width="80">所属城市</th>
@@ -75,6 +76,17 @@ @@ -75,6 +76,17 @@
75 {$vo.post_title} 76 {$vo.post_title}
76 </notempty> 77 </notempty>
77 </td> 78 </td>
  79 + <td>
  80 + <empty name="vo.is_show">
  81 + <span class="label label-default">
  82 + 隐藏
  83 + </span>
  84 + <else/>
  85 + <span class="label label-success">
  86 + 显示
  87 + </span>
  88 + </empty>
  89 + </td>
78 <td>{$vo.month}</td> 90 <td>{$vo.month}</td>
79 <td> 91 <td>
80 <notempty name="vo.more.thumbnail"> 92 <notempty name="vo.more.thumbnail">
@@ -37,7 +37,7 @@ @@ -37,7 +37,7 @@
37 <div class="col-md-9"> 37 <div class="col-md-9">
38 <table class="table table-bordered"> 38 <table class="table table-bordered">
39 <tr class="city" id="city1"> 39 <tr class="city" id="city1">
40 - <th width="100">城市分类<span class="form-required">*</span></th> 40 + <th width="150">城市分类<span class="form-required">*</span></th>
41 <td> 41 <td>
42 <select class="form-control check_city" name="post[city_id]" id="input-parent" style="width:400px;"> 42 <select class="form-control check_city" name="post[city_id]" id="input-parent" style="width:400px;">
43 <option value="">请选择城市</option> 43 <option value="">请选择城市</option>
@@ -57,6 +57,14 @@ @@ -57,6 +57,14 @@
57 </td> 57 </td>
58 </tr> 58 </tr>
59 <tr> 59 <tr>
  60 + <th>是否显示首页<span class="form-required">*</span></th>
  61 + <td>
  62 + 否:<input class="" type="radio" name="post[is_show]" checked value="0"/>
  63 + &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  64 + 是:<input class="" type="radio" name="post[is_show]" value="1"/>
  65 + </td>
  66 + </tr>
  67 + <tr>
60 <th width="100">月份<span class="form-required">*</span></th> 68 <th width="100">月份<span class="form-required">*</span></th>
61 <td> 69 <td>
62 <select class="form-control" name="post[month]" style="width:400px;"> 70 <select class="form-control" name="post[month]" style="width:400px;">
@@ -40,7 +40,7 @@ @@ -40,7 +40,7 @@
40 <div class="col-md-9"> 40 <div class="col-md-9">
41 <table class="table table-bordered"> 41 <table class="table table-bordered">
42 <tr class="city" id="city1"> 42 <tr class="city" id="city1">
43 - <th width="100">城市分类<span class="form-required">*</span></th> 43 + <th width="150">城市分类<span class="form-required">*</span></th>
44 <td> 44 <td>
45 <select class="form-control check_city" name="post[city_id]" id="input-parent" style="width:400px;"> 45 <select class="form-control check_city" name="post[city_id]" id="input-parent" style="width:400px;">
46 <option value="">请选择城市</option> 46 <option value="">请选择城市</option>
@@ -61,6 +61,14 @@ @@ -61,6 +61,14 @@
61 </td> 61 </td>
62 </tr> 62 </tr>
63 <tr> 63 <tr>
  64 + <th>是否显示首页<span class="form-required">*</span></th>
  65 + <td>
  66 + 否:<input class="" type="radio" name="post[is_show]" value="0" <eq name="0" value="$post.is_show">checked</eq>/>
  67 + &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  68 + 是:<input class="" type="radio" name="post[is_show]" value="1" <eq name="1" value="$post.is_show">checked</eq>/>
  69 + </td>
  70 + </tr>
  71 + <tr>
64 <th>简介<span class="form-required">*</span></th> 72 <th>简介<span class="form-required">*</span></th>
65 <td> 73 <td>
66 <textarea class="form-control" required name="post[post_excerpt]" style="height: 50px;" 74 <textarea class="form-control" required name="post[post_excerpt]" style="height: 50px;"
@@ -45,6 +45,7 @@ @@ -45,6 +45,7 @@
45 <!--</notempty>--> 45 <!--</notempty>-->
46 <th width="50">ID</th> 46 <th width="50">ID</th>
47 <th width="400">标题</th> 47 <th width="400">标题</th>
  48 + <th width="200">是否显示首页</th>
48 <th width="100">月份</th> 49 <th width="100">月份</th>
49 <th width="100">缩略图</th> 50 <th width="100">缩略图</th>
50 <th width="80">所属城市</th> 51 <th width="80">所属城市</th>
@@ -75,6 +76,17 @@ @@ -75,6 +76,17 @@
75 {$vo.post_title} 76 {$vo.post_title}
76 </notempty> 77 </notempty>
77 </td> 78 </td>
  79 + <td>
  80 + <empty name="vo.is_show">
  81 + <span class="label label-default">
  82 + 隐藏
  83 + </span>
  84 + <else/>
  85 + <span class="label label-success">
  86 + 显示
  87 + </span>
  88 + </empty>
  89 + </td>
78 <td>{$vo.month}</td> 90 <td>{$vo.month}</td>
79 <td> 91 <td>
80 <notempty name="vo.more.thumbnail"> 92 <notempty name="vo.more.thumbnail">
@@ -45,6 +45,7 @@ @@ -45,6 +45,7 @@
45 <!--</notempty>--> 45 <!--</notempty>-->
46 <th width="50">ID</th> 46 <th width="50">ID</th>
47 <th width="400">标题</th> 47 <th width="400">标题</th>
  48 + <th width="200">是否显示更多页</th>
48 <th width="100">缩略图</th> 49 <th width="100">缩略图</th>
49 <th width="80">所属城市</th> 50 <th width="80">所属城市</th>
50 <th width="65">点击量</th> 51 <th width="65">点击量</th>
@@ -75,6 +76,17 @@ @@ -75,6 +76,17 @@
75 </notempty> 76 </notempty>
76 </td> 77 </td>
77 <td> 78 <td>
  79 + <empty name="vo.is_show">
  80 + <span class="label label-default">
  81 + 隐藏
  82 + </span>
  83 + <else/>
  84 + <span class="label label-success">
  85 + 显示
  86 + </span>
  87 + </empty>
  88 + </td>
  89 + <td>
78 <notempty name="vo.more.thumbnail"> 90 <notempty name="vo.more.thumbnail">
79 <a href="javascript:parent.imagePreviewDialog('{:cmf_get_image_preview_url($vo.more.thumbnail)}');"> 91 <a href="javascript:parent.imagePreviewDialog('{:cmf_get_image_preview_url($vo.more.thumbnail)}');">
80 <i class="fa fa-photo fa-fw"></i> 92 <i class="fa fa-photo fa-fw"></i>
@@ -58,13 +58,15 @@ @@ -58,13 +58,15 @@
58 </head> 58 </head>
59 59
60 <body> 60 <body>
61 -<!-- 弹框视频 -->  
62 -<div class="mask" id="mask">  
63 - <div class="mask_video" >  
64 - <img id="nos" src="__TMPL__/public/assets/starImg/nos.png" alt="">  
65 - <video id="video2" src="{:cmf_get_file_download_url($res_djxq.video)}"></video>  
66 - </div>  
67 -</div> 61 + <!-- 弹框视频 -->
  62 + <notempty name="res_djxq.video">
  63 + <div class="mask" id="mask">
  64 + <div class="mask_video" >
  65 + <img id="nos" src="__TMPL__/public/assets/starImg/nos.png" alt="">
  66 + <video id="video2" src="{:cmf_get_file_download_url($res_djxq.video)}"></video>
  67 + </div>
  68 + </div>
  69 + </notempty>
68 <!-- 侧边 --> 70 <!-- 侧边 -->
69 <div class="index_sidebar"> 71 <div class="index_sidebar">
70 <a target="_blank" href="http://wpa.qq.com/msgrd?v=3&uin=1309572580&site=qq&menu=yes"> 72 <a target="_blank" href="http://wpa.qq.com/msgrd?v=3&uin=1309572580&site=qq&menu=yes">
@@ -223,15 +225,15 @@ @@ -223,15 +225,15 @@
223 <p>January</p> 225 <p>January</p>
224 </div> 226 </div>
225 <!-- 图片 --> 227 <!-- 图片 -->
226 - <notempty name="res_month.0"> 228 + <notempty name="res_month.1">
227 <div class="reverse_Imgs"> 229 <div class="reverse_Imgs">
228 - <img src="{:cmf_get_image_url($res_month.0.index_thumbnail)}"/> 230 + <img src="{:cmf_get_image_url($res_month.1.index_thumbnail)}"/>
229 </div> 231 </div>
230 <!-- 图片下方文字 --> 232 <!-- 图片下方文字 -->
231 - <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.0.id}"> 233 + <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.1.id}">
232 <div class="img_bottom"> 234 <div class="img_bottom">
233 - <p>{$res_month.0.post_title}</p>  
234 - <p>{$res_month.0.category_name}</p> 235 + <p>{$res_month.1.post_title}</p>
  236 + <p>{$res_month.1.category_name}</p>
235 </div> 237 </div>
236 </a> 238 </a>
237 <else/> 239 <else/>
@@ -260,15 +262,15 @@ @@ -260,15 +262,15 @@
260 <p>February</p> 262 <p>February</p>
261 </div> 263 </div>
262 <!-- 图片 --> 264 <!-- 图片 -->
263 - <notempty name="res_month.1"> 265 + <notempty name="res_month.2">
264 <div class="reverse_Imgs"> 266 <div class="reverse_Imgs">
265 - <img src="{:cmf_get_image_url($res_month.1.index_thumbnail)}"/> 267 + <img src="{:cmf_get_image_url($res_month.2.index_thumbnail)}"/>
266 </div> 268 </div>
267 <!-- 图片下方文字 --> 269 <!-- 图片下方文字 -->
268 - <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.1.id}"> 270 + <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.2.id}">
269 <div class="img_bottom"> 271 <div class="img_bottom">
270 - <p>{$res_month.1.post_title}</p>  
271 - <p>{$res_month.1.category_name}</p> 272 + <p>{$res_month.2.post_title}</p>
  273 + <p>{$res_month.2.category_name}</p>
272 </div> 274 </div>
273 </a> 275 </a>
274 <else/> 276 <else/>
@@ -298,15 +300,15 @@ @@ -298,15 +300,15 @@
298 <p>March</p> 300 <p>March</p>
299 </div> 301 </div>
300 <!-- 图片 --> 302 <!-- 图片 -->
301 - <notempty name="res_month.2"> 303 + <notempty name="res_month.3">
302 <div class="reverse_Imgs"> 304 <div class="reverse_Imgs">
303 - <img src="{:cmf_get_image_url($res_month.2.index_thumbnail)}"/> 305 + <img src="{:cmf_get_image_url($res_month.3.index_thumbnail)}"/>
304 </div> 306 </div>
305 <!-- 图片下方文字 --> 307 <!-- 图片下方文字 -->
306 - <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.2.id}"> 308 + <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.3.id}">
307 <div class="img_bottom"> 309 <div class="img_bottom">
308 - <p>{$res_month.2.post_title}</p>  
309 - <p>{$res_month.2.category_name}</p> 310 + <p>{$res_month.3.post_title}</p>
  311 + <p>{$res_month.3.category_name}</p>
310 </div> 312 </div>
311 </a> 313 </a>
312 <else/> 314 <else/>
@@ -337,15 +339,15 @@ @@ -337,15 +339,15 @@
337 <p>April</p> 339 <p>April</p>
338 </div> 340 </div>
339 <!-- 图片 --> 341 <!-- 图片 -->
340 - <notempty name="res_month.3"> 342 + <notempty name="res_month.4">
341 <div class="reverse_Imgs"> 343 <div class="reverse_Imgs">
342 - <img src="{:cmf_get_image_url($res_month.3.index_thumbnail)}"/> 344 + <img src="{:cmf_get_image_url($res_month.4.index_thumbnail)}"/>
343 </div> 345 </div>
344 <!-- 图片下方文字 --> 346 <!-- 图片下方文字 -->
345 - <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.3.id}"> 347 + <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.4.id}">
346 <div class="img_bottom"> 348 <div class="img_bottom">
347 - <p>{$res_month.3.post_title}</p>  
348 - <p>{$res_month.3.category_name}</p> 349 + <p>{$res_month.4.post_title}</p>
  350 + <p>{$res_month.4.category_name}</p>
349 </div> 351 </div>
350 </a> 352 </a>
351 <else/> 353 <else/>
@@ -375,15 +377,15 @@ @@ -375,15 +377,15 @@
375 <p>May</p> 377 <p>May</p>
376 </div> 378 </div>
377 <!-- 图片 --> 379 <!-- 图片 -->
378 - <notempty name="res_month.4"> 380 + <notempty name="res_month.5">
379 <div class="reverse_Imgs"> 381 <div class="reverse_Imgs">
380 - <img src="{:cmf_get_image_url($res_month.4.index_thumbnail)}"/> 382 + <img src="{:cmf_get_image_url($res_month.5.index_thumbnail)}"/>
381 </div> 383 </div>
382 <!-- 图片下方文字 --> 384 <!-- 图片下方文字 -->
383 - <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.4.id}"> 385 + <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.5.id}">
384 <div class="img_bottom"> 386 <div class="img_bottom">
385 - <p>{$res_month.4.post_title}</p>  
386 - <p>{$res_month.4.category_name}</p> 387 + <p>{$res_month.5.post_title}</p>
  388 + <p>{$res_month.5.category_name}</p>
387 </div> 389 </div>
388 </a> 390 </a>
389 <else/> 391 <else/>
@@ -412,15 +414,15 @@ @@ -412,15 +414,15 @@
412 <p>June</p> 414 <p>June</p>
413 </div> 415 </div>
414 <!-- 图片 --> 416 <!-- 图片 -->
415 - <notempty name="res_month.5"> 417 + <notempty name="res_month.6">
416 <div class="reverse_Imgs"> 418 <div class="reverse_Imgs">
417 - <img src="{:cmf_get_image_url($res_month.5.index_thumbnail)}"/> 419 + <img src="{:cmf_get_image_url($res_month.6.index_thumbnail)}"/>
418 </div> 420 </div>
419 <!-- 图片下方文字 --> 421 <!-- 图片下方文字 -->
420 - <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.5.id}"> 422 + <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.6.id}">
421 <div class="img_bottom"> 423 <div class="img_bottom">
422 - <p>{$res_month.5.post_title}</p>  
423 - <p>{$res_month.5.category_name}</p> 424 + <p>{$res_month.6.post_title}</p>
  425 + <p>{$res_month.6.category_name}</p>
424 </div> 426 </div>
425 </a> 427 </a>
426 <else/> 428 <else/>
@@ -451,15 +453,15 @@ @@ -451,15 +453,15 @@
451 <p>July</p> 453 <p>July</p>
452 </div> 454 </div>
453 <!-- 图片 --> 455 <!-- 图片 -->
454 - <notempty name="res_month.6"> 456 + <notempty name="res_month.7">
455 <div class="reverse_Imgs"> 457 <div class="reverse_Imgs">
456 - <img src="{:cmf_get_image_url($res_month.6.index_thumbnail)}"/> 458 + <img src="{:cmf_get_image_url($res_month.7.index_thumbnail)}"/>
457 </div> 459 </div>
458 <!-- 图片下方文字 --> 460 <!-- 图片下方文字 -->
459 - <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.6.id}"> 461 + <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.7.id}">
460 <div class="img_bottom"> 462 <div class="img_bottom">
461 - <p>{$res_month.6.post_title}</p>  
462 - <p>{$res_month.6.category_name}</p> 463 + <p>{$res_month.7.post_title}</p>
  464 + <p>{$res_month.7.category_name}</p>
463 </div> 465 </div>
464 </a> 466 </a>
465 <else/> 467 <else/>
@@ -490,15 +492,15 @@ @@ -490,15 +492,15 @@
490 <p>August</p> 492 <p>August</p>
491 </div> 493 </div>
492 <!-- 图片 --> 494 <!-- 图片 -->
493 - <notempty name="res_month.7"> 495 + <notempty name="res_month.8">
494 <div class="reverse_Imgs"> 496 <div class="reverse_Imgs">
495 - <img src="{:cmf_get_image_url($res_month.7.index_thumbnail)}"/> 497 + <img src="{:cmf_get_image_url($res_month.8.index_thumbnail)}"/>
496 </div> 498 </div>
497 <!-- 图片下方文字 --> 499 <!-- 图片下方文字 -->
498 - <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.7.id}"> 500 + <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.8.id}">
499 <div class="img_bottom"> 501 <div class="img_bottom">
500 - <p>{$res_month.7.post_title}</p>  
501 - <p>{$res_month.7.category_name}</p> 502 + <p>{$res_month.8.post_title}</p>
  503 + <p>{$res_month.8.category_name}</p>
502 </div> 504 </div>
503 </a> 505 </a>
504 <else/> 506 <else/>
@@ -529,15 +531,15 @@ @@ -529,15 +531,15 @@
529 <p>September</p> 531 <p>September</p>
530 </div> 532 </div>
531 <!-- 图片 --> 533 <!-- 图片 -->
532 - <notempty name="res_month.8"> 534 + <notempty name="res_month.9">
533 <div class="reverse_Imgs"> 535 <div class="reverse_Imgs">
534 - <img src="{:cmf_get_image_url($res_month.8.index_thumbnail)}"/> 536 + <img src="{:cmf_get_image_url($res_month.9.index_thumbnail)}"/>
535 </div> 537 </div>
536 <!-- 图片下方文字 --> 538 <!-- 图片下方文字 -->
537 - <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.8.id}"> 539 + <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.9.id}">
538 <div class="img_bottom"> 540 <div class="img_bottom">
539 - <p>{$res_month.8.post_title}</p>  
540 - <p>{$res_month.8.category_name}</p> 541 + <p>{$res_month.9.post_title}</p>
  542 + <p>{$res_month.9.category_name}</p>
541 </div> 543 </div>
542 </a> 544 </a>
543 <else/> 545 <else/>
@@ -566,15 +568,15 @@ @@ -566,15 +568,15 @@
566 <p>October</p> 568 <p>October</p>
567 </div> 569 </div>
568 <!-- 图片 --> 570 <!-- 图片 -->
569 - <notempty name="res_month.9"> 571 + <notempty name="res_month.10">
570 <div class="reverse_Imgs"> 572 <div class="reverse_Imgs">
571 - <img src="{:cmf_get_image_url($res_month.9.index_thumbnail)}"/> 573 + <img src="{:cmf_get_image_url($res_month.10.index_thumbnail)}"/>
572 </div> 574 </div>
573 <!-- 图片下方文字 --> 575 <!-- 图片下方文字 -->
574 - <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.9.id}"> 576 + <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.10.id}">
575 <div class="img_bottom"> 577 <div class="img_bottom">
576 - <p>{$res_month.9.post_title}</p>  
577 - <p>{$res_month.9.category_name}</p> 578 + <p>{$res_month.10.post_title}</p>
  579 + <p>{$res_month.10.category_name}</p>
578 </div> 580 </div>
579 </a> 581 </a>
580 <else/> 582 <else/>
@@ -605,15 +607,15 @@ @@ -605,15 +607,15 @@
605 <p>November</p> 607 <p>November</p>
606 </div> 608 </div>
607 <!-- 图片 --> 609 <!-- 图片 -->
608 - <notempty name="res_month.10"> 610 + <notempty name="res_month.11">
609 <div class="reverse_Imgs"> 611 <div class="reverse_Imgs">
610 - <img src="{:cmf_get_image_url($res_month.10.index_thumbnail)}"/> 612 + <img src="{:cmf_get_image_url($res_month.11.index_thumbnail)}"/>
611 </div> 613 </div>
612 <!-- 图片下方文字 --> 614 <!-- 图片下方文字 -->
613 - <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.10.id}"> 615 + <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.11.id}">
614 <div class="img_bottom"> 616 <div class="img_bottom">
615 - <p>{$res_month.10.post_title}</p>  
616 - <p>{$res_month.10.category_name}</p> 617 + <p>{$res_month.11.post_title}</p>
  618 + <p>{$res_month.11.category_name}</p>
617 </div> 619 </div>
618 </a> 620 </a>
619 <else/> 621 <else/>
@@ -644,15 +646,15 @@ @@ -644,15 +646,15 @@
644 <p>December</p> 646 <p>December</p>
645 </div> 647 </div>
646 <!-- 图片 --> 648 <!-- 图片 -->
647 - <notempty name="res_month.11"> 649 + <notempty name="res_month.12">
648 <div class="reverse_Imgs"> 650 <div class="reverse_Imgs">
649 - <img src="{:cmf_get_image_url($res_month.11.index_thumbnail)}"/> 651 + <img src="{:cmf_get_image_url($res_month.12.index_thumbnail)}"/>
650 </div> 652 </div>
651 <!-- 图片下方文字 --> 653 <!-- 图片下方文字 -->
652 - <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.11.id}"> 654 + <a href="/portal/enjoy/getEnjoyDetail?id={$res_month.12.id}">
653 <div class="img_bottom"> 655 <div class="img_bottom">
654 - <p>{$res_month.11.post_title}</p>  
655 - <p>{$res_month.11.category_name}</p> 656 + <p>{$res_month.12.post_title}</p>
  657 + <p>{$res_month.12.category_name}</p>
656 </div> 658 </div>
657 </a> 659 </a>
658 <else/> 660 <else/>
1 $(function(){ 1 $(function(){
2 var host = 'http://'+window.location.host; 2 var host = 'http://'+window.location.host;
3 - // 点赞  
4 - $('.likes').click(function() { 3 + // 收藏
  4 + $('.collections').click(function() {
5 if ($(this).children('img').attr('src') == host+'/themes/simpleboot3/public/assets/starImg/bicon_02.png') { 5 if ($(this).children('img').attr('src') == host+'/themes/simpleboot3/public/assets/starImg/bicon_02.png') {
6 - var login = operation('/portal/star/like'); 6 + var login = operation('/portal/star/collection');
7 if(login == 0){ 7 if(login == 0){
8 return false; 8 return false;
9 } 9 }
10 $(this).children('img').attr('src', host+'/themes/simpleboot3/public/assets/starImg/bicon_15.png'); 10 $(this).children('img').attr('src', host+'/themes/simpleboot3/public/assets/starImg/bicon_15.png');
11 } else { 11 } else {
12 - var login = operation('/portal/star/cancelLike'); 12 + var login = operation('/portal/star/cancelCollection');
13 if(login == 0){ 13 if(login == 0){
14 return false; 14 return false;
15 } 15 }
16 $(this).children('img').attr('src', host+'/themes/simpleboot3/public/assets/starImg/bicon_02.png'); 16 $(this).children('img').attr('src', host+'/themes/simpleboot3/public/assets/starImg/bicon_02.png');
17 } 17 }
18 }); 18 });
19 - //收藏  
20 - $('.collections').click(function() { 19 + //点赞
  20 + $('.likes').click(function() {
21 if ($(this).children('img').attr('src') == host+'/themes/simpleboot3/public/assets/starImg/bicon_03.png') { 21 if ($(this).children('img').attr('src') == host+'/themes/simpleboot3/public/assets/starImg/bicon_03.png') {
22 - var login = operation('/portal/star/collection'); 22 + var login = operation('/portal/star/like');
23 if(login == 0){ 23 if(login == 0){
24 return false; 24 return false;
25 } 25 }
26 $(this).children('img').attr('src', host+'/themes/simpleboot3/public/assets/starImg/bicon_16.png'); 26 $(this).children('img').attr('src', host+'/themes/simpleboot3/public/assets/starImg/bicon_16.png');
27 } else { 27 } else {
28 - var login = operation('/portal/star/cancelCollection'); 28 + var login = operation('/portal/star/cancelLike');
29 if(login == 0){ 29 if(login == 0){
30 return false; 30 return false;
31 } 31 }
1 <div class="sidebar"> 1 <div class="sidebar">
2 - <!-- 点赞 -->  
3 - <div class="likes">  
4 - <notempty name="is_like"> 2 + <!-- 收藏 -->
  3 + <div class="collections">
  4 + <notempty name="is_collection">
5 <img src="__TMPL__/public/assets/starImg/bicon_15.png" alt=""> 5 <img src="__TMPL__/public/assets/starImg/bicon_15.png" alt="">
6 <else/> 6 <else/>
7 <img src="__TMPL__/public/assets/starImg/bicon_02.png" alt=""> 7 <img src="__TMPL__/public/assets/starImg/bicon_02.png" alt="">
8 </notempty> 8 </notempty>
9 9
10 </div> 10 </div>
11 - <!-- 收藏 -->  
12 - <div class="collections">  
13 - <notempty name="is_collection"> 11 + <!-- 点赞 -->
  12 + <div class="likes">
  13 + <notempty name="is_like">
14 <img src="__TMPL__/public/assets/starImg/bicon_16.png" alt=""> 14 <img src="__TMPL__/public/assets/starImg/bicon_16.png" alt="">
15 <else/> 15 <else/>
16 <img src="__TMPL__/public/assets/starImg/bicon_03.png" alt=""> 16 <img src="__TMPL__/public/assets/starImg/bicon_03.png" alt="">