zhangfeng
2022-11-21 99968f83982943669af3829ea6bc3bbe745cada4
equipment/equipment-service/src/main/java/com/gkhy/safePlatform/equipment/controller/MaterialClassifyController.java
@@ -2,6 +2,7 @@
import com.alibaba.fastjson.JSONObject;
import com.gkhy.safePlatform.commons.co.ContextCacheUser;
import com.gkhy.safePlatform.commons.enums.ResultCodes;
import com.gkhy.safePlatform.commons.vo.ResultVO;
import com.gkhy.safePlatform.equipment.model.dto.req.SafeMaterialClassifyAddReq;
import com.gkhy.safePlatform.equipment.model.dto.req.SafeMaterialClassifyModReq;
@@ -28,9 +29,9 @@
     * @return
     */
    @PostMapping(value = "/list")
    public ResultVO<List<SafeMaterialClassifyDto>> list(Authentication authentication, @RequestBody SafeMaterialClassifyQuery query){
    public ResultVO<List<SafeMaterialClassifyDto>> list(Authentication authentication){
        ContextCacheUser currentUser = (ContextCacheUser) authentication.getPrincipal();
        return materialClassifyService.list(query);
        return new ResultVO<>(ResultCodes.OK,materialClassifyService.list());
    }
@@ -71,6 +72,6 @@
    @PostMapping(value = "queryById")
    public ResultVO<SafeMaterialClassifyDto> queryById(Authentication authentication, @RequestBody JSONObject jsonObject){
        Long id = jsonObject.getLong("id");
        return materialClassifyService.queryById(id);
        return new ResultVO<>(ResultCodes.OK,materialClassifyService.queryById(id));
    }
}