| | |
| | | import com.alibaba.fastjson.JSON; |
| | | import com.alibaba.fastjson.JSONArray; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.common.annotation.Log; |
| | | import com.ruoyi.common.core.domain.Result; |
| | | import com.ruoyi.common.enums.BusinessType; |
| | | import com.ruoyi.common.utils.JackSonUtil; |
| | | import com.ruoyi.inspect.dto.*; |
| | | import com.ruoyi.inspect.pojo.InsOrder; |
| | |
| | | return Result.success(insOrderService.selectInsOrderParameter(page, sampleOrderDto)); |
| | | } |
| | | |
| | | |
| | | |
| | | //用于检验下单区别查看所有订单和只查看同一个委托单位的订单 |
| | | @ApiOperation(value = "判断当前客户紧急额度是否用完") |
| | | @GetMapping("/hasSendUrgentOrder") |
| | |
| | | |
| | | @ApiOperation(value = "分配按钮") |
| | | @PostMapping("/upInsOrder") |
| | | @Log(title = "检验下单", businessType = BusinessType.UPDATE) |
| | | public Result<?> upInsOrder(@RequestBody UpInsOrderDTO upInsOrderDTO) { |
| | | return Result.success(insOrderService.upInsOrder(upInsOrderDTO)); |
| | | } |
| | | |
| | | @ApiOperation(value = "下单按钮") |
| | | @PostMapping("/addInsOrder") |
| | | @Log(title = "检验下单", businessType = BusinessType.INSERT) |
| | | public Result<?> addInsOrder(String str) { |
| | | Map<String, Object> map = JSON.parseObject(str, Map.class); |
| | | JSONArray jsonArray = JSON.parseArray(map.get("list")+""); |
| | |
| | | |
| | | @ApiOperation(value = "查询检验下单内容详情") |
| | | @GetMapping("/getInsOrder") |
| | | @Log(title = "检验下单", businessType = BusinessType.OTHER) |
| | | public Result<?> getInsOrder(Integer orderId) { |
| | | return Result.success(insOrderService.getInsOrder(orderId)); |
| | | } |
| | |
| | | @ApiImplicitParam(name = "state", value = "审核结果 1:通过 2:不通过", dataTypeClass = Integer.class) |
| | | }) |
| | | @PostMapping("/upInsOrderOfState") |
| | | @Log(title = "检验下单", businessType = BusinessType.UPDATE) |
| | | public Result<?> upInsOrderOfState(@RequestBody InsOrder insOrder) { |
| | | return Result.success(insOrderService.upInsOrderOfState(insOrder)); |
| | | } |
| | | |
| | | @ApiOperation(value = "保存检验模板按钮") |
| | | @PostMapping("/addInsOrderTemplate") |
| | | @Log(title = "检验下单", businessType = BusinessType.INSERT) |
| | | public Result<?> addInsOrderTemplate(@RequestBody InsOrderTemplate insOrderTemplate) { |
| | | return Result.success(insOrderTemplateService.addInsOrderTemplate(insOrderTemplate)); |
| | | } |
| | | |
| | | @ApiOperation(value = "删除检验模板按钮") |
| | | @PostMapping("/delInsOrderTemplate") |
| | | @Log(title = "检验下单", businessType = BusinessType.DELETE) |
| | | public Result<?> delInsOrderTemplate(Integer id) { |
| | | return Result.success(insOrderTemplateService.delInsOrderTemplate(id)); |
| | | } |
| | |
| | | |
| | | @ApiOperation(value = "通过检验单查询检验数据(数据查看)") |
| | | @GetMapping("/selectSampleAndProductByOrderId") |
| | | public Result<?> selectSampleAndProductByOrderId(@RequestBody Map<String, Object> data) throws Exception { |
| | | SampleProductDto2 sampleProductDto = JackSonUtil.unmarshal(JackSonUtil.marshal(data.get("entity")), SampleProductDto2.class); |
| | | public Result<?> selectSampleAndProductByOrderId(SampleProductDto2 sampleProductDto) { |
| | | return Result.success(insOrderService.selectSampleAndProductByOrderId(sampleProductDto)); |
| | | } |
| | | //数据查看下的查看详情(单根垂直燃烧和松套管 |
| | |
| | | |
| | | @ApiOperation(value = "导出已检委托单") |
| | | @PostMapping("/exportChecked") |
| | | @Log(title = "检验下单", businessType = BusinessType.EXPORT) |
| | | public void exportChecked(@RequestBody Map<String, Object> data, HttpServletResponse response) { |
| | | insOrderService.exportChecked(data,response); |
| | | } |
| | |
| | | |
| | | @ApiOperation(value = "撤销按钮") |
| | | @PutMapping("/updateStatus") |
| | | @Log(title = "检验下单", businessType = BusinessType.UPDATE) |
| | | public Result<?> updateStatus(Integer id) { |
| | | insOrderService.updateStatus(id); |
| | | return Result.success(); |
| | |
| | | * @param data |
| | | * @return |
| | | */ |
| | | @Log(title = "检验下单", businessType = BusinessType.UPDATE) |
| | | @PostMapping("/revoke") |
| | | public Result<?> revoke(@RequestBody Map<String, Object> data) { |
| | | insProductService.revoke(data); |
| | |
| | | return Result.success(insProductService.revokeReviewProduct(orderId,sampleId)); |
| | | } |
| | | |
| | | |
| | | |
| | | /** |
| | | * 撤销审核通过 |
| | | * @param orderId |
| | | * @return |
| | | */ |
| | | @Log(title = "检验下单", businessType = BusinessType.UPDATE) |
| | | @GetMapping("/revocationPassed") |
| | | public Result<?> revocationPassed(Integer orderId){ |
| | | insProductService.revocationPassed(orderId); |
| | |
| | | * @param orderId |
| | | * @return |
| | | */ |
| | | @Log(title = "检验下单", businessType = BusinessType.UPDATE) |
| | | @GetMapping("/revocationCancel") |
| | | public Result<?> revocationCancel(Integer orderId){ |
| | | insProductService.revocationCancel(orderId); |
| | |
| | | |
| | | @ApiOperation(value = "待检的撤销") |
| | | @PutMapping("/updateInspected") |
| | | @Log(title = "检验下单", businessType = BusinessType.UPDATE) |
| | | public Result<?> updateInspected(Integer orderId,String ids){ |
| | | insProductService.updateInspected(orderId,ids); |
| | | return Result.success(); |
| | |
| | | |
| | | @ApiOperation(value = "撤销审核按钮") |
| | | @PostMapping("/checkUpdate") |
| | | @Log(title = "检验下单", businessType = BusinessType.UPDATE) |
| | | public Result<?> checkUpdate(Integer orderId,Integer state){ |
| | | insProductService.checkUpdate(orderId,state); |
| | | return Result.success(); |