作者 何书鹏

产地

@@ -60,6 +60,9 @@ class Goods extends Api @@ -60,6 +60,9 @@ class Goods extends Api
60 $goods_spec = Db::name('litestore_goods_spec')->where('goods_id',$goods['goods_id'])->find(); 60 $goods_spec = Db::name('litestore_goods_spec')->where('goods_id',$goods['goods_id'])->find();
61 $goods['price'] = $goods_spec['goods_price']; 61 $goods['price'] = $goods_spec['goods_price'];
62 $goods['line_price'] = $goods_spec['line_price']; 62 $goods['line_price'] = $goods_spec['line_price'];
  63 + // 产地
  64 + $makerfor_list = ['1' => '国产','2' => '进口'];
  65 + $goods['makefor'] = isset($makerfor_list[$goods['makefor']]) ? $makerfor_list[$goods['makefor']] : '未知';
63 $this->success('商品详情',$goods); 66 $this->success('商品详情',$goods);
64 } 67 }
65 68