Commit b893e094 authored by zhz's avatar zhz

goods

parent db48279e
...@@ -946,7 +946,10 @@ class GoodsCommonServiceModel extends \Business\AbstractModel ...@@ -946,7 +946,10 @@ class GoodsCommonServiceModel extends \Business\AbstractModel
// if($goodsCommonRedis->tableSIsMember('weekSales:'.$storeId, $goodsCommonId)) { // if($goodsCommonRedis->tableSIsMember('weekSales:'.$storeId, $goodsCommonId)) {
// $tempArr[] = $goodsCommonId; // $tempArr[] = $goodsCommonId;
// } // }
$log = Log::getInstance();
// $log->write(print_r($data, true));
$weekSales = $goodsCommonRedis->smembers('weekSales:'.$storeId); $weekSales = $goodsCommonRedis->smembers('weekSales:'.$storeId);
$log->write(json_encode($weekSales));
if($weekSales) { if($weekSales) {
$arr = array_merge(array_diff($weekSales, $existIds)); $arr = array_merge(array_diff($weekSales, $existIds));
if($arr) { if($arr) {
...@@ -968,6 +971,7 @@ class GoodsCommonServiceModel extends \Business\AbstractModel ...@@ -968,6 +971,7 @@ class GoodsCommonServiceModel extends \Business\AbstractModel
//$commonIds = array_merge($arr,$commonIds); //$commonIds = array_merge($arr,$commonIds);
$weekSaleGoods = $goodsCommonRedis->smembers('weekSaleGoods:'.$storeId); $weekSaleGoods = $goodsCommonRedis->smembers('weekSaleGoods:'.$storeId);
$log->write(json_encode($weekSaleGoods));
if($weekSaleGoods) { if($weekSaleGoods) {
$arr = array_merge(array_diff($weekSaleGoods, $existIds)); $arr = array_merge(array_diff($weekSaleGoods, $existIds));
if($arr) { if($arr) {
...@@ -985,6 +989,7 @@ class GoodsCommonServiceModel extends \Business\AbstractModel ...@@ -985,6 +989,7 @@ class GoodsCommonServiceModel extends \Business\AbstractModel
} }
} }
$recommendGoods = $goodsCommonRedis->smembers('recommendGoods:'.$storeId); $recommendGoods = $goodsCommonRedis->smembers('recommendGoods:'.$storeId);
$log->write(json_encode($recommendGoods));
if($recommendGoods) { if($recommendGoods) {
$arr = array_merge(array_diff($recommendGoods, $existIds)); $arr = array_merge(array_diff($recommendGoods, $existIds));
if($arr) { if($arr) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment