diff --git a/admin/controllers/items/goods/Goods.php b/admin/controllers/items/goods/Goods.php index 6014c5a8..83d70698 100644 --- a/admin/controllers/items/goods/Goods.php +++ b/admin/controllers/items/goods/Goods.php @@ -507,19 +507,27 @@ class Goods extends HD_Controller $info['in_time'] = $re['in_time'] != '0000-00-00 00:00:00' ? $re['in_time'] : ''; $info['out_time'] = $re['out_time'] != '0000-00-00 00:00:00' ? $re['out_time'] : ''; $info['bill_time'] = $re['bill_time'] != '0000-00-00 00:00:00' ? $re['bill_time'] : ''; - if ($info['addr_id']) { + $address = ''; + if ($info['biz_id'] > 0) { + $re_biz = $this->mdBiz->get(array('id' => $info['biz_id'])); + $re_biz && $address = $re_biz['biz_name']; + if ($re_biz['county_id']) { + $re_area = $this->mdArea->get(array('county_id' => $re_biz['county_id'])); + $re_area && $address = "{$re_area['city_name']} {$re_area['county_name']} {$address}"; + } else if ($re_biz['city_id']) { + $re_area = $this->mdArea->get(array('city_id' => $re_biz['city_id'])); + $re_area && $address = "{$re_area['city_name']} {$address}"; + } + } else if ($info['biz_id'] == -1 && $info['addr_id']) { $row_addr = $this->addr_model->get(array('id' => $info['addr_id'])); - $info['address'] = $row_addr['city_name'] . $row_addr['county_name'] . $row_addr['title']; - } else { - $info['address'] = ''; + $row_addr && $address = "{$row_addr['city_name']} {$row_addr['county_name']} 其它 {$row_addr['title']}"; } - + $info['address'] = $address; //获取精品加装 $where = array('item_id' => $id, 'type' => 1, 'status' => 1); $rows_fine = $this->items_relate_model->select($where, '', 0, 0, 'type_id'); $fine_ids = $rows_fine ? array_column($rows_fine, 'type_id') : array(); $info['fine_ids'] = $fine_ids; - $this->data['info'] = $info; return $this->show_view('/items/goods/get_info'); } diff --git a/admin/controllers/items/goods/Logs.php b/admin/controllers/items/goods/Logs.php index 3849778e..bc4a72fb 100644 --- a/admin/controllers/items/goods/Logs.php +++ b/admin/controllers/items/goods/Logs.php @@ -222,7 +222,7 @@ class Logs extends HD_Controller $data['autoList'] = $autoList; $data['statusAry'] = $statusAry; $data['soldAry'] = $soldAry; - $data['_title'] = '门店调拨记录'; + $data['_title'] = '调拨记录'; return $data; } @@ -415,7 +415,7 @@ class Logs extends HD_Controller $params['size'] = 10000; $data = $indexs = array(); $res = $this->dataSelect($params); - $fileName = '门店调拨记录'; + $fileName = $res['_title']; foreach ($res['lists'] as $key => $value) { $temp['address'] = $value['address']; $temp['title'] = $value['title']; diff --git a/admin/views/items/goods/edit.php b/admin/views/items/goods/edit.php index ef2cb2ce..649b2975 100644 --- a/admin/views/items/goods/edit.php +++ b/admin/views/items/goods/edit.php @@ -34,7 +34,7 @@
车型
-