| | |
| | | package org.jeecg.modules.dnc.controller; |
| | | |
| | | import cn.hutool.core.util.StrUtil; |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.extern.slf4j.Slf4j; |
| | |
| | | |
| | | import javax.servlet.http.HttpServletRequest; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.util.List; |
| | | |
| | | @Slf4j |
| | | @Api(tags = "刀具信息") |
| | |
| | | } |
| | | |
| | | /** |
| | | * 查询刀具List |
| | | * @param cutter |
| | | * @return |
| | | */ |
| | | @AutoLog(value = "刀具信息-查询刀具List") |
| | | @ApiOperation(value = "刀具信息-查询刀具List", notes = "刀具信息-查询刀具List") |
| | | @GetMapping("/getList") |
| | | public Result<?> getList( Cutter cutter){ |
| | | QueryWrapper<Cutter> queryWrapper = new QueryWrapper<>(); |
| | | queryWrapper.eq(StrUtil.isNotEmpty(cutter.getDocId()),"doc_id",cutter.getDocId()); |
| | | queryWrapper.like(StrUtil.isNotEmpty(cutter.getCutterName()),"cutter_name",cutter.getCutterName()); |
| | | queryWrapper.like(StrUtil.isNotEmpty(cutter.getCutterType()),"cutter_type",cutter.getCutterType()); |
| | | queryWrapper.like(StrUtil.isNotEmpty(cutter.getCutterSpacing()),"cutter_spacing",cutter.getCutterSpacing()); |
| | | queryWrapper.orderByDesc("create_time"); |
| | | List<Cutter> list = service.list(queryWrapper); |
| | | return Result.OK(list); |
| | | } |
| | | |
| | | /** |
| | | * 新增刀具信息 |
| | | * @param cutter |
| | | * @return |