正在显示
1 个修改的文件
包含
1 行增加
和
1 行删除
@@ -19,7 +19,7 @@ class GoodsdetailsController extends WeChatBaseController{ | @@ -19,7 +19,7 @@ class GoodsdetailsController extends WeChatBaseController{ | ||
19 | public function Goods_details(){ | 19 | public function Goods_details(){ |
20 | 20 | ||
21 | $goods_id = $this -> request -> param(); | 21 | $goods_id = $this -> request -> param(); |
22 | - $data = Db::name('goods') -> alias('a') -> join('classification b','a.classify_id = b.id','LEFT') -> where('a.id',$goods_id['goods_id']) -> find(); | 22 | + $data = Db::name('goods') -> alias('a') -> field("a.*,b.name") -> join('classification b','a.classify_id = b.id','LEFT') -> where('a.id',$goods_id['goods_id']) -> find(); |
23 | $price = explode('.',$data['price']); | 23 | $price = explode('.',$data['price']); |
24 | $pricing = explode('.',$data['pricing']); | 24 | $pricing = explode('.',$data['pricing']); |
25 | $data['price0'] = $price[0]; | 25 | $data['price0'] = $price[0]; |
-
请 注册 或 登录 后发表评论