'', 'value'=>'', 'unit'=>'', 'standard'=>'', 'color'=>'', 'list'=>[] ]; ################################################################接口################################################################ ################################################################接口################################################################ ################################################################接口################################################################ // 查找设备 // $data = ['device_code'=>'asdkljiouoi'] public function device_check($data = ['device_code'=>'asdkljiouoi']){ $data = input(); $result = Db::query(" select adcd.id, adcd.state as activation_state, add.state as device_state, from app_device_code_data as adcd left join app_device_data as add on add.id = adcd.add_id where adcd.machine_code = '{$data['device_code']}' "); if(count($result) == 1){ return $this->msg(0,'success',['device_state'=>$result[0]['device_state'],'activation_state'=>$result[0]['activation_state']]); }else if(count($result) < 1){ return $this->msg(10001,'未找到设备'); }else{ $this->abnormal_data_log_action(0,'device_check-设备查询出错,结果为'.count($result).',合理值应为1或0','app_device_code_data,app_device_data'); return $this->msg(10002,'未找到设备'); } } ################################################################跳绳数据卡片接口################################################################ ################################################################跳绳数据卡片接口################################################################ ################################################################other################################################################ ################################################################other################################################################ ################################################################other################################################################ }