作者 王晓刚
1 个管道 的构建 通过 耗费 37 秒

修改问题文档

@@ -287,19 +287,19 @@ class Goods extends Frontend @@ -287,19 +287,19 @@ class Goods extends Frontend
287 $insurance = '2'; 287 $insurance = '2';
288 $store = $storeModel->findData(['id'=>$vo['store_id']]); 288 $store = $storeModel->findData(['id'=>$vo['store_id']]);
289 $store_user = $userModel->findData(['id'=>$store['user_id']]); 289 $store_user = $userModel->findData(['id'=>$store['user_id']]);
290 - if($store['is_svip'] == '1' || in_array($param['province_id'],$store_user['province_ids'])){ 290 + if($store['is_svip'] == '1' || in_array($param['province_id'],$store['province_ids'])){
291 $insurance = '1'; 291 $insurance = '1';
292 } 292 }
293 $data[$key]['insurance'] = $insurance; 293 $data[$key]['insurance'] = $insurance;
294 //当前用户若不是会员加密部分信息 294 //当前用户若不是会员加密部分信息
295 -// if($encrypt == '2'){ 295 + if($encrypt == '2'){
296 $text = ''; 296 $text = '';
297 if(empty($user_id)){ 297 if(empty($user_id)){
298 $text = "(请您先登录)"; 298 $text = "(请您先登录)";
299 - $data[$key]['store_phone'] = "***********$text";  
300 - $data[$key]['store_address'] = "***********$text";  
301 } 299 }
302 -// } 300 + $data[$key]['store_phone'] = "***********$text";
  301 + $data[$key]['store_address'] = "***********$text";
  302 + }
303 //计算平均分 303 //计算平均分
304 $score_count = $evaluateModel->where(['goods_id'=>$vo['id']])->count(); 304 $score_count = $evaluateModel->where(['goods_id'=>$vo['id']])->count();
305 $score_sum = $evaluateModel->where(['goods_id'=>$vo['id']])->sum('level'); 305 $score_sum = $evaluateModel->where(['goods_id'=>$vo['id']])->sum('level');
@@ -44,7 +44,7 @@ class Shop extends Frontend @@ -44,7 +44,7 @@ class Shop extends Frontend
44 $is_collect = "1"; 44 $is_collect = "1";
45 } 45 }
46 $userModel = new \app\index\model\User(); 46 $userModel = new \app\index\model\User();
47 - $user = $userModel->findData(['id'=>$user_id]); 47 + $user = $userModel->findData(['id'=>$data['user_id']]);
48 if(!empty($user)){ 48 if(!empty($user)){
49 $province_ids = []; 49 $province_ids = [];
50 if($user['province_ids']) { 50 if($user['province_ids']) {