Commit bd4ea5e7 authored by hujun's avatar hujun

去除设备状态处理

parent c2bfa1ed
......@@ -182,30 +182,6 @@ class BrokerService
return $result;
}
if ($data['status'] != 0) {
$is_forbidden = 1;
} else {
$is_forbidden = 0;
}
//同时修改设备绑定表
try {
$m_agent_device = new ABindingDevice();
if ($is_forbidden) {
$update_where['agent_id'] = $data['id'];
$update_where['is_forbidden'] = 0;
} else {
$update_where['agent_id'] = $data['id'];
}
$m_agent_device->updateDate(['is_forbidden' => $is_forbidden], $update_where);
} catch (\Exception $e) {
$result['status'] = 'fail';
$result['msg'] = '设备解绑失败';
return $result;
}
if ($data['status'] != 0) {
$where['a.id'] = $data['id'];
$where['b.status'] = 1;
......
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