app设备类型查询
This commit is contained in:
@ -1,5 +1,8 @@
|
||||
package com.fuyuanshen.app.controller;
|
||||
|
||||
import com.fuyuanshen.app.domain.dto.APPReNameDTO;
|
||||
import com.fuyuanshen.app.domain.vo.APPDeviceTypeVo;
|
||||
import com.fuyuanshen.app.service.equipment.APPDeviceService;
|
||||
import com.fuyuanshen.common.core.domain.R;
|
||||
import com.fuyuanshen.common.mybatis.core.page.PageQuery;
|
||||
import com.fuyuanshen.common.mybatis.core.page.TableDataInfo;
|
||||
@ -9,10 +12,11 @@ import com.fuyuanshen.equipment.domain.query.DeviceQueryCriteria;
|
||||
import com.fuyuanshen.equipment.domain.vo.AppDeviceVo;
|
||||
import com.fuyuanshen.equipment.service.DeviceService;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.apache.ibatis.annotations.Delete;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* APP 设备信息管理
|
||||
*/
|
||||
@ -24,6 +28,9 @@ public class AppDeviceController extends BaseController {
|
||||
|
||||
private final DeviceService deviceService;
|
||||
|
||||
|
||||
private final APPDeviceService appDeviceService;
|
||||
|
||||
/**
|
||||
* 查询文件列表
|
||||
*/
|
||||
@ -45,8 +52,28 @@ public class AppDeviceController extends BaseController {
|
||||
/**
|
||||
* 解绑设备
|
||||
*/
|
||||
@Delete("/unBind")
|
||||
@DeleteMapping("/unBind")
|
||||
public R<Void> unBind(Long id) {
|
||||
return toAjax(deviceService.unBindDevice(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询设备类型列表
|
||||
*/
|
||||
@GetMapping(value = "/typeList")
|
||||
public R<List<APPDeviceTypeVo>> getTypeList() {
|
||||
List<APPDeviceTypeVo> typeList = appDeviceService.getTypeList();
|
||||
return R.ok(typeList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 重命名设备
|
||||
* @param reNameDTO
|
||||
* @return
|
||||
*/
|
||||
@PostMapping(value = "/reName")
|
||||
public R<String> reName(@Validated @RequestBody APPReNameDTO reNameDTO) {
|
||||
appDeviceService.reName(reNameDTO);
|
||||
return R.ok("重命名成功!!!");
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user