Commit 3b577905 authored by clone's avatar clone

1

parent 335f79ed
......@@ -30,7 +30,7 @@ class Square extends Basic
return $this->response("101", "参数不全");
}
$result= $this->s_square->saveSquare($this->agentId,$params['title'],$params['content'],$params['cover_img'],$params['site_id'],$params['district_lable_id']);
$result= $this->s_square->saveSquare($this->agentId,$params['title'],$params['house_id'],$params['content'],$params['cover_img'],$params['site_id'],$params['district_lable_id']);
return $this->response("200", "request success", $result);
}
......
......@@ -111,8 +111,17 @@ class SquareService
$field .= 'Square.cover_img,';
$field .= 'Site.name as site_name,';
$field .= 'Square.create_time';//发布时间
$field .= 'Square.house_id';
$field .= 'house.external_title as title';
$field .= 'house.shop_area_start';
$field .= 'house.shop_area_end';
$field .= 'house.rent_type';
$field .= 'house.rent_price';
$field .= 'house.shop_sign';
$field .= 'house.industry_type';
$get_params['Square.status'] = 0;
$get_params['house.status'] = 1;//上架的商铺
$res = $this->m_square->getSquareList($pageNo, $pageSize, $field, $get_params);
$res_total = $this->m_square->getSquareListTotal($field, $get_params);
......
......@@ -51,6 +51,7 @@ class BSquare extends Model
->field($field)
->alias('Square')
->join('a_site Site', 'Site.id = Square.site_id', 'left')
->join('g_houses house', 'house.id = Square.house_id', 'left')
->where($params)
->limit($pageSize)
->page($pageNo)
......
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