| | |
| | | |
| | | import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; |
| | | import com.yuanchu.limslaboratory.pojo.Inspection; |
| | | import com.yuanchu.limslaboratory.pojo.Report; |
| | | import com.yuanchu.limslaboratory.pojo.vo.InspectionVo; |
| | | import com.yuanchu.limslaboratory.service.LinkBasicInformationService; |
| | | import com.yuanchu.limslaboratory.service.RawMaterialService; |
| | |
| | | import org.springframework.web.bind.annotation.*; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.yuanchu.limslaboratory.service.InspectionService; |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | /** |
| | |
| | | @GetMapping("/selectAll") |
| | | public Result selectAll(Integer type) { |
| | | switch (type) { |
| | | case 0 : |
| | | case 0: |
| | | //原材料 |
| | | return Result.success(rawMaterialService.selectRawmaAll()); |
| | | case 1 : |
| | | case 1: |
| | | //委托单 |
| | | return Result.success(linkBasicInformationService.selectLinkAll()); |
| | | case 2 : |
| | | case 2: |
| | | //成品检验 |
| | | return Result.success("请输入检验信息!"); |
| | | } |
| | | return Result.fail("类型错误!"); |
| | | } |
| | | |
| | | |
| | | @ApiOperation(value = "选择原材料报检") |
| | | @ApiImplicitParams(value = { |
| | | @ApiImplicitParam(name = "id", value = "原材料报检单id", dataTypeClass = Integer.class, required = true), |
| | | @ApiImplicitParam(name = "startTime", value = "检验开始日期", dataTypeClass = String.class, required = true), |
| | | @ApiImplicitParam(name = "endTime", value = "检验结束日期", dataTypeClass = String.class, required = true) |
| | | }) |
| | | @GetMapping("/selectRawmaById") |
| | | public Result selectRawmaById(Integer id, String startTime, String endTime) throws ParseException { |
| | | return Result.success(rawMaterialService.selectRawmaById(id,startTime,endTime)); |
| | | } |
| | | |
| | | |
| | | @ApiOperation(value = "选择委托报检和样品") |
| | | @ApiImplicitParams(value = { |
| | | @ApiImplicitParam(name = "bid", value = "委托报检单id", dataTypeClass = Integer.class, required = true), |
| | | @ApiImplicitParam(name = "did", value = "委托报检样品id", dataTypeClass = Integer.class, required = true) |
| | | }) |
| | | @GetMapping("/selectLinkByid") |
| | | public Result selectLinkByid(Integer bid, Integer did) { |
| | | return Result.success(linkBasicInformationService.selectLinkByid(bid, did)); |
| | | } |
| | | |
| | | |
| | |
| | | } |
| | | return Result.success(inspectionService.updateInspectsById(id)); |
| | | } |
| | | |
| | | |
| | | } |
| | | |