...
|
...
|
@@ -120,12 +120,14 @@ class PersonalcenterController extends WeChatBaseController{ |
|
|
foreach($data as $key => $val){
|
|
|
$data_goods[] = Db::name('goods') -> where('id',$val['goods_id']) -> find();
|
|
|
}
|
|
|
foreach($data_goods as $key => $val){
|
|
|
$price = explode('.',$val['price']);
|
|
|
$classification_name = Db::name('classification') -> where('id',$val['classify_id']) -> find();
|
|
|
$data_goods[$key]['classification_name'] = $classification_name['name'];
|
|
|
$data_goods[$key]['price0'] = $price[0];
|
|
|
$data_goods[$key]['price1'] = $price[1];
|
|
|
if(!empty($data_goods)){
|
|
|
foreach($data_goods as $key => $val){
|
|
|
$price = explode('.',$val['price']);
|
|
|
$classification_name = Db::name('classification') -> where('id',$val['classify_id']) -> find();
|
|
|
$data_goods[$key]['classification_name'] = $classification_name['name'];
|
|
|
$data_goods[$key]['price0'] = $price[0];
|
|
|
$data_goods[$key]['price1'] = $price[1];
|
|
|
}
|
|
|
}
|
|
|
$this -> assign('data_goods',$data_goods);
|
|
|
return $this -> fetch();
|
...
|
...
|
|