Commit 18ab9c66 authored by zw's avatar zw

bug

parent bf18f815
...@@ -79,8 +79,9 @@ class AttentionShop extends Basic ...@@ -79,8 +79,9 @@ class AttentionShop extends Basic
$order_ = 'a.create_time desc'; $order_ = 'a.create_time desc';
//b.room_num_left 前端显示已下架,不可点击到详情 //b.room_num_left 前端显示已下架,不可点击到详情
$field = "a.id,a.house_id,b.external_title as title,b.shop_area_start as room_area,b.shop_area_end as room_area2,b.rent_price as price, $field = "a.id,a.house_id,b.external_title as title,b.shop_area_start as room_area,b.shop_area_end as room_area2,
b.shop_sign as shangpu_tags,b.shop_type as shangpu_type,b.residue_num as room_num_left,b.rent_type,b.external_image_id"; b.rent_price as price, b.shop_sign as shangpu_tags,b.shop_type as shangpu_type,b.residue_num as room_num_left,
b.rent_type,b.external_image_id,b.is_show_image";
if (!isset($params["user_id"])) { if (!isset($params["user_id"])) {
return $this->response("101", "用户id不能为空"); return $this->response("101", "用户id不能为空");
...@@ -98,17 +99,24 @@ class AttentionShop extends Basic ...@@ -98,17 +99,24 @@ class AttentionShop extends Basic
$imgParam["img_type"] = 1; //默认主图 $imgParam["img_type"] = 1; //默认主图
$imgArr = $this->imgModel->getHouseImages($imgParam, 1); $imgArr = $this->imgModel->getHouseImages($imgParam, 1);
$result[$key]["images"] = $imgArr;*/ $result[$key]["images"] = $imgArr;*/
if ($val["external_image_id"]) {
$param["id"] = array( "in", $val["external_image_id"] );
$param["img_status"] = 0;
$field = 'id,0 as house_id,img_type,label,img_name,img_status'; if (empty($val['is_show_image'])) {
if ($val["external_image_id"]) {
$res = $this->imageDepotModel->getImageDepotById($field, $param,1); $param["id"] = array("in", $val["external_image_id"]);
$result[$key]["images"] = count($res) > 0 ? $res : []; $param["img_status"] = 0;
$field = 'id,0 as house_id,img_type,label,img_name,img_status';
$res = $this->imageDepotModel->getImageDepotById($field, $param, 1);
$result[$key]["images"] = count($res) > 0 ? $res : [];
}
} else {
$result[$key]["api_path"] = CK_IMG_URL.'images/';
$house_img_where["house_id"] = $val["id"];
$house_img_where["img_type"] = 2; //默认主图 产品盼盼于11.16号修改
$result[$key]["images"] = $this->gHousesImgModel->getHouseImages($house_img_where, 1);
} }
} }
return $this->response("200", "request success", $result); return $this->response("200", "request success", $result);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment