点位绑定设备功能

This commit is contained in:
2023-03-20 19:22:42 +08:00
parent 3a7f999551
commit 2851197af5
6 changed files with 60 additions and 13 deletions

View File

@@ -73,4 +73,12 @@ public class DeviceController {
return new ResponseEntity<>(deviceService.getWorkprocedure(),HttpStatus.OK);
}
@GetMapping("/getDeviceList")
@Log("设备下拉框")
@ApiOperation("设备下拉框")
//@PreAuthorize("@el.check('device:list')")
public ResponseEntity<Object> getDeviceList(){
return new ResponseEntity<>(deviceService.getDeviceList(),HttpStatus.OK);
}
}

View File

@@ -69,4 +69,10 @@ public interface DeviceService {
* @return
*/
JSONArray getWorkprocedure();
/**
* 获取设备下拉框
* @return
*/
JSONArray getDeviceList();
}

View File

@@ -144,4 +144,10 @@ public class DeviceServiceImpl implements DeviceService {
return resultJSONArray;
}
@Override
public JSONArray getDeviceList() {
WQLObject wo = WQLObject.getWQLObject("PDM_BI_Device");
return wo.query("is_delete = '0'", "device_code").getResultJSONArray(0);
}
}