|
@@ -873,8 +873,14 @@
|
|
|
</where>
|
|
|
|
|
|
# order by p.combinationSort != 0 desc, p.combinationSort asc
|
|
|
-
|
|
|
- order by p.sortIndex desc
|
|
|
+ # 在设置重点关注时给排序值1000为了让重点关注始终在列表前端
|
|
|
+ <if test="sortIndex==1000">
|
|
|
+ ORDER BY p.newshowTime DESC
|
|
|
+ </if>
|
|
|
+ <if test="sortIndex!=1000">
|
|
|
+ order by p.sortIndex desc
|
|
|
+ </if>
|
|
|
+# order by p.sortIndex desc
|
|
|
|
|
|
</select>
|
|
|
|
|
@@ -882,6 +888,11 @@
|
|
|
SELECT DISTINCT s.`id`,s.`name` FROM product a
|
|
|
LEFT JOIN `cm_brand` s ON s.id = a.brandID
|
|
|
WHERE a.newvalidFlag = 1
|
|
|
+ AND a.newProductType=1
|
|
|
+ AND a.validFlag = 2
|
|
|
+ AND a.showFlag!=2
|
|
|
+ AND s.id IS NOT NULL
|
|
|
+ AND s.name IS NOT NULL
|
|
|
AND s.id IS NOT NULL
|
|
|
AND s.name IS NOT NULL
|
|
|
|