Commit 298c01bd authored by hujun's avatar hujun

is_alert

parent a2086378
...@@ -38,6 +38,7 @@ class OfficeRoomService ...@@ -38,6 +38,7 @@ class OfficeRoomService
private $m_building_stations; private $m_building_stations;
private $redis_service; private $redis_service;
private $m_house_file; private $m_house_file;
private $m_office;
public function __construct() public function __construct()
...@@ -52,6 +53,7 @@ class OfficeRoomService ...@@ -52,6 +53,7 @@ class OfficeRoomService
$this->m_building_stations = new OfficeGBuildingStations(); $this->m_building_stations = new OfficeGBuildingStations();
$this->redis_service = new RedisCacheService(); $this->redis_service = new RedisCacheService();
$this->m_house_file = new OfficeGHouseFile(); $this->m_house_file = new OfficeGHouseFile();
$this->m_office = new OfficeGBuilding();
if (CURRENT_URL == 'https://api.tonglianjituan.com/') { if (CURRENT_URL == 'https://api.tonglianjituan.com/') {
$this->internet_path = IMAGES_URL.'/resource/lib/Attachments/images/'; $this->internet_path = IMAGES_URL.'/resource/lib/Attachments/images/';
...@@ -216,8 +218,14 @@ class OfficeRoomService ...@@ -216,8 +218,14 @@ class OfficeRoomService
$m_operating->record($agent_id, 2, $remark, $id); $m_operating->record($agent_id, 2, $remark, $id);
} }
$status = $this->m_office->getFieldOneValue('status', ['id'=>$data['building_id']]);
$is_alert = 0;
if ($status != 1) {
$is_alert = 1;
}
$result['status'] = 'successful'; $result['status'] = 'successful';
$result['data']['house_id'] = $id; $result['data']['house_id'] = $id;
$result['data']['is_alert'] = $is_alert;
} else { } else {
$result['msg'] = '新增或编辑失败!'; $result['msg'] = '新增或编辑失败!';
} }
......
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