| | |
| | | * @author 江苏鵷雏网络科技有限公司 |
| | | * @since 2023-07-17 |
| | | */ |
| | | @Api(tags = "检验模块") |
| | | @Api(tags = "检验模块-->检验单") |
| | | @RestController |
| | | @RequestMapping("/inspection") |
| | | public class InspectionController { |
| | |
| | | }) |
| | | @PostMapping("/addInspection") |
| | | public Result addInspection(@RequestHeader("X-Token") String token, int type) throws Exception { |
| | | System.out.println(token); |
| | | System.out.println(type); |
| | | Object object = RedisUtil.get(token); |
| | | System.out.println(object); |
| | | Map<String, Object> unmarshal = JackSonUtil.unmarshal(JackSonUtil.marshal(object), Map.class); |
| | | return Result.success(inspectionService.addInspection("" + unmarshal.get("name"), type)); |
| | | } |
| | |
| | | return Result.success(materialService.selectMaterialById(materialId)); |
| | | } |
| | | |
| | | @ApiOperation("提交申请") |
| | | @ApiOperation("提交检验单申请") |
| | | @ApiImplicitParams(value = { |
| | | @ApiImplicitParam(name = "inspectionId", value = "检验单ID", dataTypeClass = String.class, required = true), |
| | | }) |
| | |
| | | return Result.success(inspectionService.subInspectionByInsId(inspectionId)); |
| | | } |
| | | |
| | | @ApiOperation("作废申请") |
| | | @ApiOperation("作废检验单申请") |
| | | @ApiImplicitParams(value = { |
| | | @ApiImplicitParam(name = "inspectionId", value = "检验单ID", dataTypeClass = String.class, required = true), |
| | | }) |