Просмотр исходного кода

最新最热课程前台后台完结

赵启卫 2 лет назад
Родитель
Сommit
9240961d5e

+ 15 - 5
application/wap/model/special/Special.php

xqd
@@ -353,11 +353,21 @@ class Special extends ModelBasic
                 ->group('a.id')->where('uid', $where['uid']);
         } else {
             $model = self::PreWhere();
-            if ($where['subject_id'] && $where['grade_id'] > 0) {
-                $model = $model->where('subject_id', $where['subject_id']);
-            } else if ($where['subject_id'] == 0 && $where['grade_id'] > 0) {
-                $subject_ids = SpecialSubject::subjectId($where['grade_id']);
-                $model = $model->where('subject_id', 'in', $subject_ids);
+            if ($where['grade_id'] == 64) {
+                if ($where['subject_id'] == 65) {
+                    $model = $model->where('isnew', 1);
+                } elseif ($where['subject_id'] == 66) {
+                    $model = $model->where('ishot', 1);
+                } else {
+                    $model = $model->where('ishot|isnew', 1);
+                }
+            } else {
+                if ($where['subject_id'] && $where['grade_id'] > 0) {
+                    $model = $model->where('subject_id', $where['subject_id']);
+                } else if ($where['subject_id'] == 0 && $where['grade_id'] > 0) {
+                    $subject_ids = SpecialSubject::subjectId($where['grade_id']);
+                    $model = $model->where('subject_id', 'in', $subject_ids);
+                }
             }
             if ($where['search']) {
                 $model = $model->where('title|abstract', 'LIKE', "%$where[search]%");

+ 2 - 2
application/wap/view/first/special/special_cate.html

xqd xqd
@@ -29,7 +29,7 @@
 {/block}
 {block name="content"}
 <div v-cloak id="app" class="goodsClass">
-    <div class="header">
+    <div class="header" style="height: 1rem;">
         <div class="search acea-row row-middle">
             <div class="pictrue">{if $homeLogo}<img src="{$homeLogo}">{else}<img src="/wap/first/zsff/images/crmeb.png">{/if}</div>
             <form class="form" @submit.prevent="goSearch">
@@ -40,7 +40,7 @@
                 <input class="submit" type="submit" value="搜索">
             </form>
         </div>
-        <div v-if="gradeCate.length" id="wrapper" class="wrapper">
+        <div v-if="gradeCate.length" style="display: none;" id="wrapper" class="wrapper">
             <div class="scroller">
                 <ul>
                     <li v-for="item in gradeCate" :key="item.id" :data-id="item.id">