Commit d3d11ad8 authored by hujun's avatar hujun

edit

parent d244f731
......@@ -136,7 +136,7 @@ class HouseService
$m_operating->record($agent_id, 6, $remark, $data['id']);
if (empty($data['is_exclusive_type'])) {
$this->delAgentHouse(3, $data['id']);
$this->delAgentHouse(3, $data['id'], 0);
}
}
......@@ -945,10 +945,10 @@ class HouseService
*
* @param $type
* @param $house_id
* @param $agent_id
* @param $id_edit
* @return GHousesToAgents|bool
*/
public function delAgentHouse($type, $house_id) {
public function delAgentHouse($type, $house_id, $id_edit = 1) {
if (empty($type) || empty($house_id)) {
return false;
}
......@@ -961,7 +961,7 @@ class HouseService
$where['houses_id'] = $house_id;
$where['type'] = $type;
$is_ok = $this->agent_house->updateData($where, ['is_del'=>1]);
if ($type == 3) {
if ($id_edit && $type == 3) {
$this->m_house->editData(['is_exclusive_type'=>0], $house_id);
}
return $is_ok;
......
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