|
|
@@ -20,7 +20,7 @@ class ProductService extends BaseService
|
|
|
|
|
|
//特价
|
|
|
const TJ_CLASS_ID = '-1';
|
|
|
- //常用
|
|
|
+ //满减活动
|
|
|
const OFTEN_CLASS_ID = '-2';
|
|
|
//预售
|
|
|
const PRESELL_CLASS_ID = '-3';
|
|
|
@@ -135,7 +135,13 @@ class ProductService extends BaseService
|
|
|
foreach ($itemInfoData as $v) {
|
|
|
$reachNum = $v['reachNum'] ?? 0;
|
|
|
$reachNumDiscount = $v['reachNumDiscount'] ?? 0;
|
|
|
- if ((isset($v['discountPrice']) && $v['discountPrice'] > 0) || ($reachNum > 0 && $reachNumDiscount > 0)) {
|
|
|
+ if ($reachNum > 0 && $reachNumDiscount > 0) {
|
|
|
+ $v['classId'] = self::OFTEN_CLASS_ID;
|
|
|
+ $v['className'] = '满减活动';
|
|
|
+ $tjItem[] = $v;
|
|
|
+ $itemGroup[] = $v;
|
|
|
+ }
|
|
|
+ if ((isset($v['discountPrice']) && $v['discountPrice'] > 0)) {
|
|
|
$v['classId'] = self::TJ_CLASS_ID;
|
|
|
$v['className'] = '今日推荐';
|
|
|
$tjItem[] = $v;
|