| | |
| | | import com.ruoyi.common.core.domain.entity.SysUser; |
| | | import com.ruoyi.common.enums.BusinessType; |
| | | import com.ruoyi.framework.web.service.TokenService; |
| | | import com.ruoyi.system.dto.AuditStatusDTO; |
| | | import com.ruoyi.system.dto.ExperimentDispatchSignDTO; |
| | | import com.ruoyi.system.dto.TExperimentDispatchDTO; |
| | | import com.ruoyi.system.dto.UpAndDownDTO; |
| | | import com.ruoyi.system.mapper.SysUserMapper; |
| | | import com.ruoyi.system.model.TExperimentDispatch; |
| | | import com.ruoyi.system.model.TExperimentDispatchGroup; |
| | |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.List; |
| | | import java.util.Objects; |
| | | import java.util.stream.Collectors; |
| | | |
| | | /** |
| | |
| | | package com.ruoyi.web.controller.api; |
| | | |
| | | |
| | | import com.alibaba.fastjson.JSON; |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.ruoyi.common.annotation.Log; |
| | | import com.ruoyi.common.basic.PageInfo; |
| | | import com.ruoyi.common.core.domain.R; |
| | | import com.ruoyi.common.enums.BusinessType; |
| | | import com.ruoyi.common.enums.FeasibilityStudyReportStatusEnum; |
| | | import com.ruoyi.common.enums.FeasibilityReportFileEnum; |
| | | import com.ruoyi.framework.web.service.TokenService; |
| | | import com.ruoyi.system.dto.AuditStatusDTO; |
| | | import com.ruoyi.system.dto.TFeasibilityStudyReportDTO; |
| | | import com.ruoyi.system.model.TFeasibilityReportFile; |
| | | import com.ruoyi.system.model.TFeasibilityStudyReport; |
| | | import com.ruoyi.system.query.TFeasibilityStudyReportQuery; |
| | | import com.ruoyi.system.service.TFeasibilityReportFileService; |
| | | import com.ruoyi.system.service.TFeasibilityStudyReportService; |
| | | import com.ruoyi.system.vo.TFeasibilityStudyReportVO; |
| | | import io.swagger.annotations.Api; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * <p> |
| | |
| | | @RequestMapping("/t-feasibility-study-report") |
| | | public class TFeasibilityStudyReportController { |
| | | |
| | | private final TFeasibilityStudyReportService feasibilityStudyReportService; |
| | | private final TFeasibilityReportFileService feasibilityReportFileService; |
| | | private final TokenService tokenService; |
| | | @Autowired |
| | | public TFeasibilityStudyReportController(TFeasibilityStudyReportService feasibilityStudyReportService, TFeasibilityReportFileService feasibilityReportFileService, TokenService tokenService) { |
| | | this.feasibilityStudyReportService = feasibilityStudyReportService; |
| | | this.feasibilityReportFileService = feasibilityReportFileService; |
| | | this.tokenService = tokenService; |
| | | } |
| | | |
| | | /** |
| | | * 获取可研、可行、工艺开发工具、验证发布报告管理列表 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:feasibilityStudyReport:list')") |
| | | @ApiOperation(value = "获取可研、可行、工艺开发工具、验证发布报告管理分页列表") |
| | | @PostMapping(value = "/api/t-feasibility-study-report/pageList") |
| | | public R<PageInfo<TFeasibilityStudyReportVO>> pageList(@RequestBody String param) { |
| | | TFeasibilityStudyReportQuery query = JSON.parseObject(param, TFeasibilityStudyReportQuery.class); |
| | | return R.ok(feasibilityStudyReportService.pageList(query)); |
| | | } |
| | | |
| | | /** |
| | | * 添加可研、可行、工艺开发工具、验证发布报告管理管理 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:feasibilityStudyReport:add')") |
| | | @Log(title = "可研、可行、工艺开发工具、验证发布报告管理信息-新增可研、可行、工艺开发工具、验证发布报告管理", businessType = BusinessType.INSERT) |
| | | @ApiOperation(value = "添加可研、可行、工艺开发工具、验证发布报告管理",response = TFeasibilityStudyReportDTO.class) |
| | | @PostMapping(value = "/api/t-feasibility-study-report/add") |
| | | public R<Boolean> add(@RequestBody String param) { |
| | | TFeasibilityStudyReportDTO dto = JSON.parseObject(param,TFeasibilityStudyReportDTO.class); |
| | | // TODO 生成编号 |
| | | feasibilityStudyReportService.save(dto); |
| | | // 添加检测报告文件 |
| | | List<TFeasibilityReportFile> feasibilityReportFiles = dto.getFeasibilityReportFiles(); |
| | | for (TFeasibilityReportFile feasibilityReportFile : feasibilityReportFiles) { |
| | | feasibilityReportFile.setReportId(dto.getId()); |
| | | switch (FeasibilityReportFileEnum.fromCode(feasibilityReportFile.getReportType())) { |
| | | case FEASIBILITY_STUDY_REPORT: |
| | | feasibilityReportFile.setReportType(FeasibilityReportFileEnum.FEASIBILITY_STUDY_REPORT.getCode()); |
| | | break; |
| | | case FEASIBLE_REPORT: |
| | | feasibilityReportFile.setReportType(FeasibilityReportFileEnum.FEASIBLE_REPORT.getCode()); |
| | | break; |
| | | case PROCESS_DEVELOPMENT_TOOLS: |
| | | feasibilityReportFile.setReportType(FeasibilityReportFileEnum.PROCESS_DEVELOPMENT_TOOLS.getCode()); |
| | | break; |
| | | case VERIFICATION_RELEASE: |
| | | feasibilityReportFile.setReportType(FeasibilityReportFileEnum.VERIFICATION_RELEASE.getCode()); |
| | | break; |
| | | default: |
| | | feasibilityReportFile.setReportType(FeasibilityReportFileEnum.PROJECT_PROPOSAL.getCode()); |
| | | break; |
| | | } |
| | | } |
| | | feasibilityReportFileService.saveBatch(feasibilityReportFiles); |
| | | return R.ok(); |
| | | } |
| | | |
| | | /** |
| | | * 修改可研、可行、工艺开发工具、验证发布报告管理 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:feasibilityStudyReport:edit')") |
| | | @Log(title = "可研、可行、工艺开发工具、验证发布报告管理信息-修改可研、可行、工艺开发工具、验证发布报告管理", businessType = BusinessType.UPDATE) |
| | | @ApiOperation(value = "修改可研、可行、工艺开发工具、验证发布报告管理") |
| | | @PostMapping(value = "/api/t-feasibility-study-report/update") |
| | | public R<Boolean> update(@RequestBody String param) { |
| | | TFeasibilityStudyReportDTO dto = JSON.parseObject(param,TFeasibilityStudyReportDTO.class); |
| | | feasibilityStudyReportService.updateById(dto); |
| | | feasibilityReportFileService.remove(Wrappers.lambdaQuery(TFeasibilityReportFile.class) |
| | | .eq(TFeasibilityReportFile::getReportId, dto.getId())); |
| | | // 添加检测报告文件 |
| | | List<TFeasibilityReportFile> feasibilityReportFiles = dto.getFeasibilityReportFiles(); |
| | | for (TFeasibilityReportFile feasibilityReportFile : feasibilityReportFiles) { |
| | | feasibilityReportFile.setReportId(dto.getId()); |
| | | switch (FeasibilityReportFileEnum.fromCode(feasibilityReportFile.getReportType())) { |
| | | case FEASIBILITY_STUDY_REPORT: |
| | | feasibilityReportFile.setReportType(FeasibilityReportFileEnum.FEASIBILITY_STUDY_REPORT.getCode()); |
| | | break; |
| | | case FEASIBLE_REPORT: |
| | | feasibilityReportFile.setReportType(FeasibilityReportFileEnum.FEASIBLE_REPORT.getCode()); |
| | | break; |
| | | case PROCESS_DEVELOPMENT_TOOLS: |
| | | feasibilityReportFile.setReportType(FeasibilityReportFileEnum.PROCESS_DEVELOPMENT_TOOLS.getCode()); |
| | | break; |
| | | case VERIFICATION_RELEASE: |
| | | feasibilityReportFile.setReportType(FeasibilityReportFileEnum.VERIFICATION_RELEASE.getCode()); |
| | | break; |
| | | default: |
| | | feasibilityReportFile.setReportType(FeasibilityReportFileEnum.PROJECT_PROPOSAL.getCode()); |
| | | break; |
| | | } |
| | | } |
| | | feasibilityReportFileService.saveBatch(feasibilityReportFiles); |
| | | return R.ok(); |
| | | } |
| | | |
| | | /** |
| | | * 查看可研、可行、工艺开发工具、验证发布报告管理详情 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:feasibilityStudyReport:detail')") |
| | | @ApiOperation(value = "查看可研、可行、工艺开发工具、验证发布报告管理详情") |
| | | @GetMapping(value = "/open/t-feasibility-study-report/getDetailById") |
| | | public R<TFeasibilityStudyReportVO> getDetailById(@RequestParam String id) { |
| | | TFeasibilityStudyReport feasibilityStudyReport = feasibilityStudyReportService.getById(id); |
| | | TFeasibilityStudyReportVO feasibilityStudyReportVO = new TFeasibilityStudyReportVO(); |
| | | BeanUtils.copyProperties(feasibilityStudyReport, feasibilityStudyReportVO); |
| | | // 查询检测报告文件 |
| | | List<TFeasibilityReportFile> feasibilityReportFiles = feasibilityReportFileService.list(Wrappers.lambdaQuery(TFeasibilityReportFile.class) |
| | | .eq(TFeasibilityReportFile::getReportId, id)); |
| | | feasibilityStudyReportVO.setFeasibilityReportFiles(feasibilityReportFiles); |
| | | return R.ok(feasibilityStudyReportVO); |
| | | } |
| | | |
| | | /** |
| | | * 删除可研、可行、工艺开发工具、验证发布报告管理 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:feasibilityStudyReport:delete')") |
| | | @Log(title = "可研、可行、工艺开发工具、验证发布报告管理信息-删除可研、可行、工艺开发工具、验证发布报告管理", businessType = BusinessType.DELETE) |
| | | @ApiOperation(value = "删除可研、可行、工艺开发工具、验证发布报告管理") |
| | | @DeleteMapping(value = "/open/t-feasibility-study-report/deleteById") |
| | | public R<Boolean> deleteById(@RequestParam String id) { |
| | | // 删除可研、可行、工艺开发工具、验证发布报告文件 |
| | | feasibilityReportFileService.remove(Wrappers.lambdaQuery(TFeasibilityReportFile.class).eq(TFeasibilityReportFile::getReportId, id)); |
| | | return R.ok(feasibilityStudyReportService.removeById(id)); |
| | | } |
| | | |
| | | /** |
| | | * 批量删除可研、可行、工艺开发工具、验证发布报告管理 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:feasibilityStudyReport:delete')") |
| | | @Log(title = "可研、可行、工艺开发工具、验证发布报告管理信息-删除可研、可行、工艺开发工具、验证发布报告管理", businessType = BusinessType.DELETE) |
| | | @ApiOperation(value = "批量删除可研、可行、工艺开发工具、验证发布报告管理") |
| | | @DeleteMapping(value = "/open/t-feasibility-study-report/deleteByIds") |
| | | public R<Boolean> deleteByIds(@RequestBody List<String> ids) { |
| | | // 删除可研、可行、工艺开发工具、验证发布报告文件 |
| | | feasibilityReportFileService.remove(Wrappers.lambdaQuery(TFeasibilityReportFile.class).in(TFeasibilityReportFile::getReportId, ids)); |
| | | return R.ok(feasibilityStudyReportService.removeByIds(ids)); |
| | | } |
| | | |
| | | /** |
| | | * 撤销可研、可行、工艺开发工具、验证发布报告管理 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:feasibilityStudyReport:revokedReport')") |
| | | @Log(title = "可研、可行、工艺开发工具、验证发布报告管理信息-撤销可研、可行、工艺开发工具、验证发布报告管理状态", businessType = BusinessType.UPDATE) |
| | | @ApiOperation(value = "撤销可研、可行、工艺开发工具、验证发布报告管理状态") |
| | | @PutMapping(value = "/open/t-feasibility-study-report/revokedReport") |
| | | public R<Boolean> revokedReport(@RequestParam String id) { |
| | | TFeasibilityStudyReport feasibilityStudyReport = feasibilityStudyReportService.getById(id); |
| | | feasibilityStudyReport.setStatus(FeasibilityStudyReportStatusEnum.REVOKED.getCode()); |
| | | feasibilityStudyReportService.updateById(feasibilityStudyReport); |
| | | return R.ok(); |
| | | } |
| | | |
| | | /** |
| | | * 审核可研、可行、工艺开发工具、验证发布报告管理 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:feasibilityStudyReport:auditReport')") |
| | | @Log(title = "可研、可行、工艺开发工具、验证发布报告管理信息-审核可研、可行、工艺开发工具、验证发布报告管理状态", businessType = BusinessType.UPDATE) |
| | | @ApiOperation(value = "审核可研、可行、工艺开发工具、验证发布报告管理状态") |
| | | @PostMapping(value = "/api/t-feasibility-study-report/auditReport") |
| | | public R<Boolean> auditReport(@RequestBody String param) { |
| | | Long userId = tokenService.getLoginUser().getUserId(); |
| | | AuditStatusDTO dto = JSON.parseObject(param,AuditStatusDTO.class); |
| | | TFeasibilityStudyReport feasibilityStudyReport = feasibilityStudyReportService.getById(dto.getId()); |
| | | feasibilityStudyReport.setStatus(dto.getAuditStatus()); |
| | | feasibilityStudyReport.setAuditRemark(dto.getAuditRemark()); |
| | | feasibilityStudyReport.setAuditPersonId(userId); |
| | | feasibilityStudyReport.setAuditTime(LocalDateTime.now()); |
| | | feasibilityStudyReportService.updateById(feasibilityStudyReport); |
| | | return R.ok(); |
| | | } |
| | | |
| | | } |
| | | |
| | |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:projectProposal:audit')") |
| | | @Log(title = "项目课题方案信息-审核项目课题方案", businessType = BusinessType.UPDATE) |
| | | @ApiOperation(value = "审核项目课题方案",response = UpAndDownDTO.class) |
| | | @ApiOperation(value = "审核项目课题方案",response = AuditStatusDTO.class) |
| | | @PostMapping(value = "/api/t-project-proposal/audit") |
| | | public R<Boolean> audit(@RequestBody String param) { |
| | | Long userId = tokenService.getLoginUser().getUserId(); |
| | |
| | | package com.ruoyi.web.controller.api; |
| | | |
| | | |
| | | import com.alibaba.fastjson.JSON; |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.ruoyi.common.annotation.Log; |
| | | import com.ruoyi.common.basic.PageInfo; |
| | | import com.ruoyi.common.core.domain.R; |
| | | import com.ruoyi.common.enums.BusinessType; |
| | | import com.ruoyi.common.enums.QAProduceReportStatusEnum; |
| | | import com.ruoyi.common.enums.QaReportFileEnum; |
| | | import com.ruoyi.framework.web.service.TokenService; |
| | | import com.ruoyi.system.dto.AuditStatusDTO; |
| | | import com.ruoyi.system.dto.TQaProduceReportDTO; |
| | | import com.ruoyi.system.model.TQaProduceReport; |
| | | import com.ruoyi.system.model.TQaReportFile; |
| | | import com.ruoyi.system.query.TQaProduceReportQuery; |
| | | import com.ruoyi.system.service.TQaProduceReportService; |
| | | import com.ruoyi.system.service.TQaReportFileService; |
| | | import com.ruoyi.system.vo.TQaProduceReportVO; |
| | | import io.swagger.annotations.Api; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * <p> |
| | |
| | | @RequestMapping("/t-qa-produce-report") |
| | | public class TQaProduceReportController { |
| | | |
| | | private final TQaProduceReportService qaProduceReportService; |
| | | private final TQaReportFileService qaReportFileService; |
| | | private final TokenService tokenService; |
| | | @Autowired |
| | | public TQaProduceReportController(TQaProduceReportService qaProduceReportService, TQaReportFileService qaReportFileService, TokenService tokenService) { |
| | | this.qaProduceReportService = qaProduceReportService; |
| | | this.qaReportFileService = qaReportFileService; |
| | | this.tokenService = tokenService; |
| | | } |
| | | |
| | | /** |
| | | * 获取中试、生产验证分析报告;辅料;产品报告管理列表 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:qaProduceReport:list')") |
| | | @ApiOperation(value = "获取中试、生产验证分析报告;辅料;产品报告管理分页列表") |
| | | @PostMapping(value = "/api/t-qa-produce-report/pageList") |
| | | public R<PageInfo<TQaProduceReportVO>> pageList(@RequestBody String param) { |
| | | TQaProduceReportQuery query = JSON.parseObject(param, TQaProduceReportQuery.class); |
| | | return R.ok(qaProduceReportService.pageList(query)); |
| | | } |
| | | |
| | | /** |
| | | * 添加中试、生产验证分析报告;辅料;产品报告管理管理 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:qaProduceReport:add')") |
| | | @Log(title = "中试、生产验证分析报告;辅料;产品报告管理信息-新增中试、生产验证分析报告;辅料;产品报告管理", businessType = BusinessType.INSERT) |
| | | @ApiOperation(value = "添加中试、生产验证分析报告;辅料;产品报告管理",response = TQaProduceReportDTO.class) |
| | | @PostMapping(value = "/api/t-qa-produce-report/add") |
| | | public R<Boolean> add(@RequestBody String param) { |
| | | TQaProduceReportDTO dto = JSON.parseObject(param,TQaProduceReportDTO.class); |
| | | // TODO 生成编号 |
| | | qaProduceReportService.save(dto); |
| | | // 添加检测报告文件 |
| | | List<TQaReportFile> qaReportFiles = dto.getQaReportFiles(); |
| | | for (TQaReportFile qaReportFile : qaReportFiles) { |
| | | qaReportFile.setReportId(dto.getId()); |
| | | switch (QaReportFileEnum.fromCode(qaReportFile.getReportType())) { |
| | | case TEST_REPORT: |
| | | qaReportFile.setReportType(QaReportFileEnum.TEST_REPORT.getCode()); |
| | | break; |
| | | case PILOT_PRODUCTION_VALIDATION: |
| | | qaReportFile.setReportType(QaReportFileEnum.PILOT_PRODUCTION_VALIDATION.getCode()); |
| | | break; |
| | | case RAW_MATERIAL_REPORT: |
| | | qaReportFile.setReportType(QaReportFileEnum.RAW_MATERIAL_REPORT.getCode()); |
| | | break; |
| | | case PRODUCT_APPROVAL_REPORT: |
| | | qaReportFile.setReportType(QaReportFileEnum.PRODUCT_APPROVAL_REPORT.getCode()); |
| | | break; |
| | | } |
| | | } |
| | | qaReportFileService.saveBatch(qaReportFiles); |
| | | return R.ok(); |
| | | } |
| | | |
| | | /** |
| | | * 修改中试、生产验证分析报告;辅料;产品报告管理 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:qaProduceReport:edit')") |
| | | @Log(title = "中试、生产验证分析报告;辅料;产品报告管理信息-修改中试、生产验证分析报告;辅料;产品报告管理", businessType = BusinessType.UPDATE) |
| | | @ApiOperation(value = "修改中试、生产验证分析报告;辅料;产品报告管理") |
| | | @PostMapping(value = "/api/t-qa-produce-report/update") |
| | | public R<Boolean> update(@RequestBody String param) { |
| | | TQaProduceReportDTO dto = JSON.parseObject(param,TQaProduceReportDTO.class); |
| | | qaProduceReportService.updateById(dto); |
| | | qaReportFileService.remove(Wrappers.lambdaQuery(TQaReportFile.class) |
| | | .eq(TQaReportFile::getReportId, dto.getId())); |
| | | // 添加检测报告文件 |
| | | List<TQaReportFile> qaReportFiles = dto.getQaReportFiles(); |
| | | for (TQaReportFile qaReportFile : qaReportFiles) { |
| | | qaReportFile.setReportId(dto.getId()); |
| | | switch (QaReportFileEnum.fromCode(qaReportFile.getReportType())) { |
| | | case TEST_REPORT: |
| | | qaReportFile.setReportType(QaReportFileEnum.TEST_REPORT.getCode()); |
| | | break; |
| | | case PILOT_PRODUCTION_VALIDATION: |
| | | qaReportFile.setReportType(QaReportFileEnum.PILOT_PRODUCTION_VALIDATION.getCode()); |
| | | break; |
| | | case RAW_MATERIAL_REPORT: |
| | | qaReportFile.setReportType(QaReportFileEnum.RAW_MATERIAL_REPORT.getCode()); |
| | | break; |
| | | case PRODUCT_APPROVAL_REPORT: |
| | | qaReportFile.setReportType(QaReportFileEnum.PRODUCT_APPROVAL_REPORT.getCode()); |
| | | break; |
| | | } |
| | | } |
| | | qaReportFileService.saveBatch(qaReportFiles); |
| | | return R.ok(); |
| | | } |
| | | |
| | | /** |
| | | * 查看中试、生产验证分析报告;辅料;产品报告管理详情 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:qaProduceReport:detail')") |
| | | @ApiOperation(value = "查看中试、生产验证分析报告;辅料;产品报告管理详情") |
| | | @GetMapping(value = "/open/t-qa-produce-report/getDetailById") |
| | | public R<TQaProduceReportVO> getDetailById(@RequestParam String id) { |
| | | TQaProduceReport qaProduceReport = qaProduceReportService.getById(id); |
| | | TQaProduceReportVO qaProduceReportVO = new TQaProduceReportVO(); |
| | | BeanUtils.copyProperties(qaProduceReport, qaProduceReportVO); |
| | | // 查询报告文件 |
| | | List<TQaReportFile> qaReportFiles = qaReportFileService.list(Wrappers.lambdaQuery(TQaReportFile.class) |
| | | .eq(TQaReportFile::getReportId, id) |
| | | .ne(TQaReportFile::getReportType, QaReportFileEnum.TEST_REPORT.getCode())); |
| | | qaProduceReportVO.setQaReportFileList(qaReportFiles); |
| | | return R.ok(qaProduceReportVO); |
| | | } |
| | | |
| | | /** |
| | | * 删除中试、生产验证分析报告;辅料;产品报告管理 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:qaProduceReport:delete')") |
| | | @Log(title = "中试、生产验证分析报告;辅料;产品报告管理信息-删除中试、生产验证分析报告;辅料;产品报告管理", businessType = BusinessType.DELETE) |
| | | @ApiOperation(value = "删除中试、生产验证分析报告;辅料;产品报告管理") |
| | | @DeleteMapping(value = "/open/t-qa-produce-report/deleteById") |
| | | public R<Boolean> deleteById(@RequestParam String id) { |
| | | // 删除中试、生产验证分析报告;辅料;产品报告管理文件 |
| | | qaReportFileService.remove(Wrappers.lambdaQuery(TQaReportFile.class).eq(TQaReportFile::getReportId, id) |
| | | .notIn(TQaReportFile::getReportType, QaReportFileEnum.TEST_REPORT.getCode())); |
| | | return R.ok(qaProduceReportService.removeById(id)); |
| | | } |
| | | |
| | | /** |
| | | * 批量删除中试、生产验证分析报告;辅料;产品报告管理 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:qaProduceReport:delete')") |
| | | @Log(title = "中试、生产验证分析报告;辅料;产品报告管理信息-删除中试、生产验证分析报告;辅料;产品报告管理", businessType = BusinessType.DELETE) |
| | | @ApiOperation(value = "批量删除中试、生产验证分析报告;辅料;产品报告管理") |
| | | @DeleteMapping(value = "/open/t-qa-produce-report/deleteByIds") |
| | | public R<Boolean> deleteByIds(@RequestBody List<String> ids) { |
| | | // 删除QA检测项报告检测报告 |
| | | qaReportFileService.remove(Wrappers.lambdaQuery(TQaReportFile.class).in(TQaReportFile::getReportId, ids) |
| | | .notIn(TQaReportFile::getReportType, QaReportFileEnum.TEST_REPORT.getCode())); |
| | | return R.ok(qaProduceReportService.removeByIds(ids)); |
| | | } |
| | | |
| | | /** |
| | | * 撤销中试、生产验证分析报告;辅料;产品报告管理 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:qaProduceReport:revokedReport')") |
| | | @Log(title = "中试、生产验证分析报告;辅料;产品报告管理信息-撤销中试、生产验证分析报告;辅料;产品报告管理状态", businessType = BusinessType.UPDATE) |
| | | @ApiOperation(value = "撤销中试、生产验证分析报告;辅料;产品报告管理状态") |
| | | @PutMapping(value = "/open/t-qa-produce-report/revokedReport") |
| | | public R<Boolean> revokedReport(@RequestParam String id) { |
| | | TQaProduceReport qaProduceReport = qaProduceReportService.getById(id); |
| | | qaProduceReport.setStatus(QAProduceReportStatusEnum.REVOKED.getCode()); |
| | | qaProduceReportService.updateById(qaProduceReport); |
| | | return R.ok(); |
| | | } |
| | | |
| | | /** |
| | | * 审核中试、生产验证分析报告;辅料;产品报告管理 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:qaProduceReport:auditReport')") |
| | | @Log(title = "中试、生产验证分析报告;辅料;产品报告管理信息-审核中试、生产验证分析报告;辅料;产品报告管理状态", businessType = BusinessType.UPDATE) |
| | | @ApiOperation(value = "审核中试、生产验证分析报告;辅料;产品报告管理状态") |
| | | @PostMapping(value = "/api/t-qa-produce-report/auditReport") |
| | | public R<Boolean> auditReport(@RequestBody String param) { |
| | | Long userId = tokenService.getLoginUser().getUserId(); |
| | | AuditStatusDTO dto = JSON.parseObject(param,AuditStatusDTO.class); |
| | | TQaProduceReport qaProduceReport = qaProduceReportService.getById(dto.getId()); |
| | | qaProduceReport.setStatus(dto.getAuditStatus()); |
| | | qaProduceReport.setAuditRemark(dto.getAuditRemark()); |
| | | qaProduceReport.setAuditPersonId(userId); |
| | | qaProduceReport.setAuditTime(LocalDateTime.now()); |
| | | qaProduceReportService.updateById(qaProduceReport); |
| | | return R.ok(); |
| | | } |
| | | |
| | | } |
| | | |
| | |
| | | import com.ruoyi.common.basic.PageInfo; |
| | | import com.ruoyi.common.core.domain.R; |
| | | import com.ruoyi.common.enums.BusinessType; |
| | | import com.ruoyi.common.enums.QATestItemStatusEnum; |
| | | import com.ruoyi.system.dto.TQaTestItemDTO; |
| | | import com.ruoyi.system.dto.UpAndDownDTO; |
| | | import com.ruoyi.system.model.TQaTestItem; |
| | | import com.ruoyi.system.model.TQaTestItemReport; |
| | | import com.ruoyi.system.query.TQaTestItemQuery; |
| | |
| | | @ApiOperation(value = "查看QA检测项管理详情") |
| | | @GetMapping(value = "/open/t-qa-test-item/getDetailById") |
| | | public R<TQaTestItemVO> getDetailById(@RequestParam String id) { |
| | | TQaTestItem projectTeam = qaTestItemService.getById(id); |
| | | TQaTestItemVO projectTeamVO = new TQaTestItemVO(); |
| | | BeanUtils.copyProperties(projectTeam, projectTeamVO); |
| | | TQaTestItem testItem = qaTestItemService.getById(id); |
| | | TQaTestItemVO testItemVO = new TQaTestItemVO(); |
| | | BeanUtils.copyProperties(testItem, testItemVO); |
| | | // 查询QA检测项检测报告 |
| | | List<TQaTestItemReportVO> qaTestItemReportVOS= qaTestItemReportService.getList(id); |
| | | projectTeamVO.setQaTestItemReportList(qaTestItemReportVOS); |
| | | return R.ok(projectTeamVO); |
| | | testItemVO.setQaTestItemReportList(qaTestItemReportVOS); |
| | | return R.ok(testItemVO); |
| | | } |
| | | |
| | | /** |
| | |
| | | /** |
| | | * 修改QA检测项管理 |
| | | */ |
| | | // @PreAuthorize("@ss.hasPermi('system:qaTestItem:upAndDown')") |
| | | // @Log(title = "QA检测项管理信息-提交评价QA检测项管理状态", businessType = BusinessType.UPDATE) |
| | | // @ApiOperation(value = "修改QA检测项管理状态",response = UpAndDownDTO.class) |
| | | // @PostMapping(value = "/api/t-qa-test-item/upAndDown") |
| | | // public R<Boolean> upAndDown(@RequestBody String param) { |
| | | // UpAndDownDTO dto = JSON.parseObject(param,UpAndDownDTO.class); |
| | | // TQaTestItem projectTeam = qaTestItemService.getById(dto.getId()); |
| | | // projectTeam.setStatus(dto.getStatus()); |
| | | // qaTestItemService.updateById(projectTeam); |
| | | // return R.ok(); |
| | | // } |
| | | @PreAuthorize("@ss.hasPermi('system:qaTestItem:commitEvaluate')") |
| | | @Log(title = "QA检测项管理信息-提交评价QA检测项管理状态", businessType = BusinessType.UPDATE) |
| | | @ApiOperation(value = "修改QA检测项管理状态") |
| | | @PutMapping(value = "/open/t-qa-test-item/commitEvaluate") |
| | | public R<Boolean> commitEvaluate(@RequestParam String id) { |
| | | TQaTestItem testItem = qaTestItemService.getById(id); |
| | | testItem.setStatus(QATestItemStatusEnum.TO_BE_EVALUATED.getCode()); |
| | | qaTestItemService.updateById(testItem); |
| | | return R.ok(); |
| | | } |
| | | |
| | | } |
| | | |
| | |
| | | package com.ruoyi.web.controller.api; |
| | | |
| | | |
| | | import com.alibaba.fastjson.JSON; |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.ruoyi.common.annotation.Log; |
| | | import com.ruoyi.common.basic.PageInfo; |
| | | import com.ruoyi.common.core.domain.R; |
| | | import com.ruoyi.common.enums.BusinessType; |
| | | import com.ruoyi.common.enums.QATestItemReportStatusEnum; |
| | | import com.ruoyi.common.enums.QaReportFileEnum; |
| | | import com.ruoyi.framework.web.service.TokenService; |
| | | import com.ruoyi.system.dto.AuditStatusDTO; |
| | | import com.ruoyi.system.dto.TQaTestItemReportDTO; |
| | | import com.ruoyi.system.mapper.TQaReportFileMapper; |
| | | import com.ruoyi.system.model.TProjectProposal; |
| | | import com.ruoyi.system.model.TQaReportFile; |
| | | import com.ruoyi.system.model.TQaTestItemReport; |
| | | import com.ruoyi.system.query.TQaTestItemReportQuery; |
| | | import com.ruoyi.system.service.TQaReportFileService; |
| | | import com.ruoyi.system.service.TQaTestItemReportService; |
| | | import com.ruoyi.system.vo.TQaTestItemReportVO; |
| | | import io.swagger.annotations.Api; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.List; |
| | | import java.util.stream.Collectors; |
| | | |
| | | /** |
| | | * <p> |
| | | * QA检测项报告 前端控制器 |
| | | * QA检测项报告报告 前端控制器 |
| | | * </p> |
| | | * |
| | | * @author xiaochen |
| | | * @since 2025-04-08 |
| | | */ |
| | | @Api(tags = "QA检测项报告管理") |
| | | @Api(tags = "QA检测项报告报告管理") |
| | | @RestController |
| | | @RequestMapping("/t-qa-test-item-report") |
| | | @RequestMapping("") |
| | | public class TQaTestItemReportController { |
| | | |
| | | private final TQaTestItemReportService qaTestItemReportService; |
| | | private final TQaReportFileService qaReportFileService; |
| | | private final TokenService tokenService; |
| | | @Autowired |
| | | public TQaTestItemReportController(TQaTestItemReportService qaTestItemReportService, TQaReportFileService qaReportFileService, TokenService tokenService) { |
| | | this.qaTestItemReportService = qaTestItemReportService; |
| | | this.qaReportFileService = qaReportFileService; |
| | | this.tokenService = tokenService; |
| | | } |
| | | |
| | | /** |
| | | * 获取QA检测项报告管理列表 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:qaTestItemReport:list')") |
| | | @ApiOperation(value = "获取QA检测项报告管理分页列表-工艺工程师使用") |
| | | @PostMapping(value = "/api/t-qa-test-item-report/pageList") |
| | | public R<PageInfo<TQaTestItemReportVO>> pageList(@RequestBody String param) { |
| | | TQaTestItemReportQuery query = JSON.parseObject(param, TQaTestItemReportQuery.class); |
| | | return R.ok(qaTestItemReportService.pageList(query)); |
| | | } |
| | | |
| | | /** |
| | | * 获取QA检测项报告管理列表 |
| | | */ |
| | | @ApiOperation(value = "获取QA检测项报告管理下拉列表-化验师使用") |
| | | @GetMapping(value = "/open/t-qa-test-item-report/getListByItemId") |
| | | public R<List<TQaTestItemReport>> getListByItemId(@RequestParam String itemId) { |
| | | List<TQaTestItemReport> list = qaTestItemReportService.list(Wrappers.lambdaQuery(TQaTestItemReport.class) |
| | | .eq(TQaTestItemReport::getItemId, itemId)); |
| | | return R.ok(list); |
| | | } |
| | | |
| | | /** |
| | | * 添加QA检测项报告管理管理 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:qaTestItemReport:add')") |
| | | @Log(title = "QA检测项报告管理信息-新增QA检测项报告管理", businessType = BusinessType.INSERT) |
| | | @ApiOperation(value = "添加QA检测项报告管理",response = TQaTestItemReportDTO.class) |
| | | @PostMapping(value = "/api/t-qa-test-item-report/add") |
| | | public R<Boolean> add(@RequestBody String param) { |
| | | TQaTestItemReportDTO dto = JSON.parseObject(param,TQaTestItemReportDTO.class); |
| | | // TODO 生成编号 |
| | | qaTestItemReportService.save(dto); |
| | | // 添加检测报告文件 |
| | | List<TQaReportFile> qaReportFiles = dto.getQaReportFiles(); |
| | | for (TQaReportFile qaReportFile : qaReportFiles) { |
| | | qaReportFile.setReportId(dto.getId()); |
| | | qaReportFile.setReportType(QaReportFileEnum.TEST_REPORT.getCode()); |
| | | } |
| | | qaReportFileService.saveBatch(qaReportFiles); |
| | | return R.ok(); |
| | | } |
| | | |
| | | /** |
| | | * 修改QA检测项报告管理 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:qaTestItemReport:edit')") |
| | | @Log(title = "QA检测项报告管理信息-修改QA检测项报告管理", businessType = BusinessType.UPDATE) |
| | | @ApiOperation(value = "修改QA检测项报告管理") |
| | | @PostMapping(value = "/api/t-qa-test-item-report/update") |
| | | public R<Boolean> update(@RequestBody String param) { |
| | | TQaTestItemReportDTO dto = JSON.parseObject(param,TQaTestItemReportDTO.class); |
| | | qaTestItemReportService.updateById(dto); |
| | | qaReportFileService.remove(Wrappers.lambdaQuery(TQaReportFile.class) |
| | | .eq(TQaReportFile::getReportId, dto.getId())); |
| | | // 添加检测报告文件 |
| | | List<TQaReportFile> qaReportFiles = dto.getQaReportFiles(); |
| | | for (TQaReportFile qaReportFile : qaReportFiles) { |
| | | qaReportFile.setReportId(dto.getId()); |
| | | qaReportFile.setReportType(QaReportFileEnum.TEST_REPORT.getCode()); |
| | | } |
| | | qaReportFileService.saveBatch(qaReportFiles); |
| | | return R.ok(); |
| | | } |
| | | |
| | | /** |
| | | * 查看QA检测项报告管理详情 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:qaTestItemReport:detail')") |
| | | @ApiOperation(value = "查看QA检测项报告管理详情") |
| | | @GetMapping(value = "/open/t-qa-test-item-report/getDetailById") |
| | | public R<TQaTestItemReportVO> getDetailById(@RequestParam String id) { |
| | | TQaTestItemReport testItemReport = qaTestItemReportService.getById(id); |
| | | TQaTestItemReportVO testItemReportVO = new TQaTestItemReportVO(); |
| | | BeanUtils.copyProperties(testItemReport, testItemReportVO); |
| | | // 查询检测报告文件 |
| | | List<TQaReportFile> qaReportFiles = qaReportFileService.list(Wrappers.lambdaQuery(TQaReportFile.class) |
| | | .eq(TQaReportFile::getReportId, id) |
| | | .eq(TQaReportFile::getReportType, QaReportFileEnum.TEST_REPORT.getCode())); |
| | | testItemReportVO.setQaReportFileList(qaReportFiles); |
| | | return R.ok(testItemReportVO); |
| | | } |
| | | |
| | | /** |
| | | * 删除QA检测项报告管理 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:qaTestItemReport:delete')") |
| | | @Log(title = "QA检测项报告管理信息-删除QA检测项报告管理", businessType = BusinessType.DELETE) |
| | | @ApiOperation(value = "删除QA检测项报告管理") |
| | | @DeleteMapping(value = "/open/t-qa-test-item-report/deleteById") |
| | | public R<Boolean> deleteById(@RequestParam String id) { |
| | | // 删除QA检测项报告文件 |
| | | qaReportFileService.remove(Wrappers.lambdaQuery(TQaReportFile.class).eq(TQaReportFile::getReportId, id) |
| | | .in(TQaReportFile::getReportType, QaReportFileEnum.TEST_REPORT.getCode())); |
| | | return R.ok(qaTestItemReportService.removeById(id)); |
| | | } |
| | | |
| | | /** |
| | | * 批量删除QA检测项报告管理 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:qaTestItemReport:delete')") |
| | | @Log(title = "QA检测项报告管理信息-删除QA检测项报告管理", businessType = BusinessType.DELETE) |
| | | @ApiOperation(value = "批量删除QA检测项报告管理") |
| | | @DeleteMapping(value = "/open/t-qa-test-item-report/deleteByIds") |
| | | public R<Boolean> deleteByIds(@RequestBody List<String> ids) { |
| | | // 删除QA检测项报告检测报告文件 |
| | | qaReportFileService.remove(Wrappers.lambdaQuery(TQaReportFile.class).in(TQaReportFile::getReportId, ids) |
| | | .in(TQaReportFile::getReportType, QaReportFileEnum.TEST_REPORT.getCode())); |
| | | return R.ok(qaTestItemReportService.removeByIds(ids)); |
| | | } |
| | | |
| | | /** |
| | | * 撤销QA检测项报告管理 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:qaTestItemReport:revokedReport')") |
| | | @Log(title = "QA检测项报告管理信息-撤销QA检测项报告管理状态", businessType = BusinessType.UPDATE) |
| | | @ApiOperation(value = "撤销QA检测项报告管理状态") |
| | | @PutMapping(value = "/open/t-qa-test-item-report/revokedReport") |
| | | public R<Boolean> revokedReport(@RequestParam String id) { |
| | | TQaTestItemReport testItemReport = qaTestItemReportService.getById(id); |
| | | testItemReport.setStatus(QATestItemReportStatusEnum.REVOKED.getCode()); |
| | | qaTestItemReportService.updateById(testItemReport); |
| | | return R.ok(); |
| | | } |
| | | |
| | | /** |
| | | * 审核QA检测项报告管理 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:qaTestItemReport:auditReport')") |
| | | @Log(title = "QA检测项报告管理信息-审核QA检测项报告管理状态", businessType = BusinessType.UPDATE) |
| | | @ApiOperation(value = "审核QA检测项报告管理状态") |
| | | @PostMapping(value = "/api/t-qa-test-item-report/auditReport") |
| | | public R<Boolean> auditReport(@RequestBody String param) { |
| | | Long userId = tokenService.getLoginUser().getUserId(); |
| | | AuditStatusDTO dto = JSON.parseObject(param,AuditStatusDTO.class); |
| | | TQaTestItemReport testItemReport = qaTestItemReportService.getById(dto.getId()); |
| | | testItemReport.setStatus(dto.getAuditStatus()); |
| | | testItemReport.setAuditRemark(dto.getAuditRemark()); |
| | | testItemReport.setAuditPersonId(userId); |
| | | testItemReport.setAuditTime(LocalDateTime.now()); |
| | | qaTestItemReportService.updateById(testItemReport); |
| | | return R.ok(); |
| | | } |
| | | |
| | | } |
| | | |
New file |
| | |
| | | package com.ruoyi.common.enums; |
| | | |
| | | import lombok.Getter; |
| | | |
| | | /** |
| | | * @author xiaochen |
| | | * @ClassName Disable |
| | | * @Description |
| | | * @date 2022-06-08 16:55 |
| | | */ |
| | | public enum FeasibilityReportFileEnum { |
| | | /*报告类型 1=可研报告 2=可行报告 3=工艺开发工具 4=验证与发布 5=立项报告*/ |
| | | FEASIBILITY_STUDY_REPORT(1, "可研报告"), |
| | | FEASIBLE_REPORT(2, "可行报告"), |
| | | PROCESS_DEVELOPMENT_TOOLS(3, "工艺开发工具"), |
| | | VERIFICATION_RELEASE(4, "验证与发布"), |
| | | PROJECT_PROPOSAL(5, "立项报告"); |
| | | |
| | | @Getter |
| | | private String desc; |
| | | |
| | | |
| | | @Getter |
| | | private int code; |
| | | |
| | | |
| | | FeasibilityReportFileEnum(int code, String desc) { |
| | | this.code = code; |
| | | this.desc = desc; |
| | | } |
| | | |
| | | /** |
| | | * 通过code获取枚举 |
| | | * |
| | | * @param code |
| | | * @return |
| | | */ |
| | | public static FeasibilityReportFileEnum fromCode(Integer code) { |
| | | FeasibilityReportFileEnum[] resultTypes = FeasibilityReportFileEnum.values(); |
| | | for (FeasibilityReportFileEnum resultType : resultTypes) { |
| | | if (code.equals(resultType.getCode())) { |
| | | return resultType; |
| | | } |
| | | } |
| | | return null; |
| | | } |
| | | } |
New file |
| | |
| | | package com.ruoyi.common.enums; |
| | | |
| | | import lombok.Getter; |
| | | |
| | | /** |
| | | * @author xiaochen |
| | | * @ClassName Disable |
| | | * @Description |
| | | * @date 2022-06-08 16:55 |
| | | */ |
| | | public enum FeasibilityStudyReportStatusEnum { |
| | | /*状态 -1=草稿箱 1=待审核 2=待评定 3=已评定 4=已驳回 5=已撤回*/ |
| | | DRAFTS(-1, "草稿箱"), |
| | | PENDING_APPROVAL(1, "待审核"), |
| | | PASSED(2, "待评定"), |
| | | EVALUATED(3, "已评定"), |
| | | REJECTED(4, "已驳回"), |
| | | REVOKED(5, "已撤销"); |
| | | |
| | | @Getter |
| | | private String desc; |
| | | |
| | | |
| | | @Getter |
| | | private int code; |
| | | |
| | | |
| | | FeasibilityStudyReportStatusEnum(int code, String desc) { |
| | | this.code = code; |
| | | this.desc = desc; |
| | | } |
| | | |
| | | /** |
| | | * 通过code获取枚举 |
| | | * |
| | | * @param code |
| | | * @return |
| | | */ |
| | | public static FeasibilityStudyReportStatusEnum fromCode(Integer code) { |
| | | FeasibilityStudyReportStatusEnum[] resultTypes = FeasibilityStudyReportStatusEnum.values(); |
| | | for (FeasibilityStudyReportStatusEnum resultType : resultTypes) { |
| | | if (code.equals(resultType.getCode())) { |
| | | return resultType; |
| | | } |
| | | } |
| | | return null; |
| | | } |
| | | } |
New file |
| | |
| | | package com.ruoyi.common.enums; |
| | | |
| | | import lombok.Getter; |
| | | |
| | | /** |
| | | * @author xiaochen |
| | | * @ClassName Disable |
| | | * @Description |
| | | * @date 2022-06-08 16:55 |
| | | */ |
| | | public enum QAProduceReportStatusEnum { |
| | | /*状态 -1=草稿箱 1=待审核 2=已通过待评定 3=已评定 4=已驳回 5=已撤销*/ |
| | | DRAFTS(-1, "草稿箱"), |
| | | PENDING_APPROVAL(1, "待审核"), |
| | | PASSED(2, "已通过"), |
| | | EVALUATED(3, "已评定"), |
| | | REJECTED(4, "已驳回"), |
| | | REVOKED(5, "已撤销"); |
| | | |
| | | @Getter |
| | | private String desc; |
| | | |
| | | |
| | | @Getter |
| | | private int code; |
| | | |
| | | |
| | | QAProduceReportStatusEnum(int code, String desc) { |
| | | this.code = code; |
| | | this.desc = desc; |
| | | } |
| | | |
| | | /** |
| | | * 通过code获取枚举 |
| | | * |
| | | * @param code |
| | | * @return |
| | | */ |
| | | public static QAProduceReportStatusEnum fromCode(Integer code) { |
| | | QAProduceReportStatusEnum[] resultTypes = QAProduceReportStatusEnum.values(); |
| | | for (QAProduceReportStatusEnum resultType : resultTypes) { |
| | | if (code.equals(resultType.getCode())) { |
| | | return resultType; |
| | | } |
| | | } |
| | | return null; |
| | | } |
| | | } |
New file |
| | |
| | | package com.ruoyi.common.enums; |
| | | |
| | | import lombok.Getter; |
| | | |
| | | /** |
| | | * @author xiaochen |
| | | * @ClassName Disable |
| | | * @Description |
| | | * @date 2022-06-08 16:55 |
| | | */ |
| | | public enum QATestItemReportStatusEnum { |
| | | /*状态 -1=草稿箱 1=待审核 2=已通过 3=已驳回 4=已撤销*/ |
| | | DRAFTS(-1, "草稿箱"), |
| | | PENDING_APPROVAL(1, "待审核"), |
| | | PASSED(2, "已通过"), |
| | | REJECTED(3, "已驳回"), |
| | | REVOKED(4, "已撤销"); |
| | | |
| | | @Getter |
| | | private String desc; |
| | | |
| | | |
| | | @Getter |
| | | private int code; |
| | | |
| | | |
| | | QATestItemReportStatusEnum(int code, String desc) { |
| | | this.code = code; |
| | | this.desc = desc; |
| | | } |
| | | |
| | | /** |
| | | * 通过code获取枚举 |
| | | * |
| | | * @param code |
| | | * @return |
| | | */ |
| | | public static QATestItemReportStatusEnum fromCode(Integer code) { |
| | | QATestItemReportStatusEnum[] resultTypes = QATestItemReportStatusEnum.values(); |
| | | for (QATestItemReportStatusEnum resultType : resultTypes) { |
| | | if (code.equals(resultType.getCode())) { |
| | | return resultType; |
| | | } |
| | | } |
| | | return null; |
| | | } |
| | | } |
New file |
| | |
| | | package com.ruoyi.common.enums; |
| | | |
| | | import lombok.Getter; |
| | | |
| | | /** |
| | | * @author xiaochen |
| | | * @ClassName Disable |
| | | * @Description |
| | | * @date 2022-06-08 16:55 |
| | | */ |
| | | public enum QATestItemStatusEnum { |
| | | /*状态 -1=草稿箱 1=已提交 2=待评定 3=已评定*/ |
| | | DRAFTS(-1, "草稿箱"), |
| | | SUBMITTED(1, "已提交"), |
| | | TO_BE_EVALUATED(2, "待评定"), |
| | | EVALUATED(3, "已评定"); |
| | | |
| | | @Getter |
| | | private String desc; |
| | | |
| | | |
| | | @Getter |
| | | private int code; |
| | | |
| | | |
| | | QATestItemStatusEnum(int code, String desc) { |
| | | this.code = code; |
| | | this.desc = desc; |
| | | } |
| | | |
| | | /** |
| | | * 通过code获取枚举 |
| | | * |
| | | * @param code |
| | | * @return |
| | | */ |
| | | public static QATestItemStatusEnum fromCode(Integer code) { |
| | | QATestItemStatusEnum[] resultTypes = QATestItemStatusEnum.values(); |
| | | for (QATestItemStatusEnum resultType : resultTypes) { |
| | | if (code.equals(resultType.getCode())) { |
| | | return resultType; |
| | | } |
| | | } |
| | | return null; |
| | | } |
| | | } |
| | |
| | | import java.io.Serializable; |
| | | |
| | | @Data |
| | | @ApiModel(value = "启用禁用DTO") |
| | | @ApiModel(value = "(项目课题方案)、(检测项检测报告)、(审核中试、生产验证分析报告;辅料;产品报告管理状态)、(可研、可行、工艺开发工具、验证发布报告)审核DTO") |
| | | public class AuditStatusDTO implements Serializable { |
| | | |
| | | @ApiModelProperty(value = "id") |
New file |
| | |
| | | package com.ruoyi.system.dto; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | |
| | | @Data |
| | | @ApiModel(value = "QA检测项提交评审DTO") |
| | | public class QaCommitEvaluateDTO implements Serializable { |
| | | |
| | | @ApiModelProperty(value = "id") |
| | | private String id; |
| | | |
| | | @ApiModelProperty(value = "状态 1=正常 2=封存") |
| | | private Integer status; |
| | | |
| | | |
| | | } |
New file |
| | |
| | | package com.ruoyi.system.dto; |
| | | |
| | | import com.ruoyi.system.model.TFeasibilityReportFile; |
| | | import com.ruoyi.system.model.TFeasibilityStudyReport; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.util.List; |
| | | |
| | | @Data |
| | | @ApiModel(value="可研、可行、工艺开发工具、验证发布报告新增编辑DTO", description="可研、可行、工艺开发工具、验证发布报告") |
| | | public class TFeasibilityStudyReportDTO extends TFeasibilityStudyReport { |
| | | |
| | | @ApiModelProperty(value = "报告文件") |
| | | private List<TFeasibilityReportFile> feasibilityReportFiles; |
| | | |
| | | @ApiModelProperty(value = "检测报告文件类型 1=检测报告 2=中试生产验证 3=原辅料报告 4=产品报批报告") |
| | | private Integer reportType; |
| | | |
| | | } |
New file |
| | |
| | | package com.ruoyi.system.dto; |
| | | |
| | | import com.ruoyi.system.model.TQaProduceReport; |
| | | import com.ruoyi.system.model.TQaReportFile; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.util.List; |
| | | |
| | | @Data |
| | | @ApiModel(value = "中试、生产验证分析报告;辅料;产品报告新增编辑DTO") |
| | | public class TQaProduceReportDTO extends TQaProduceReport { |
| | | |
| | | @ApiModelProperty(value = "检测报告文件") |
| | | private List<TQaReportFile> qaReportFiles; |
| | | |
| | | @ApiModelProperty(value = "检测报告文件类型 1=检测报告 2=中试生产验证 3=原辅料报告 4=产品报批报告") |
| | | private Integer reportType; |
| | | |
| | | } |
New file |
| | |
| | | package com.ruoyi.system.dto; |
| | | |
| | | import com.ruoyi.system.model.TQaReportFile; |
| | | import com.ruoyi.system.model.TQaTestItemReport; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.util.List; |
| | | |
| | | @Data |
| | | @ApiModel(value = "QA检测项报告管理新增编辑DTO") |
| | | public class TQaTestItemReportDTO extends TQaTestItemReport { |
| | | |
| | | @ApiModelProperty(value = "检测报告文件") |
| | | private List<TQaReportFile> qaReportFiles; |
| | | |
| | | } |
| | |
| | | import java.io.Serializable; |
| | | |
| | | @Data |
| | | @ApiModel(value = "启用禁用DTO") |
| | | @ApiModel(value = "项目组、项目课题方案、启用禁用DTO") |
| | | public class UpAndDownDTO implements Serializable { |
| | | |
| | | @ApiModelProperty(value = "id") |
| | |
| | | package com.ruoyi.system.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.ruoyi.common.basic.PageInfo; |
| | | import com.ruoyi.system.model.TFeasibilityStudyReport; |
| | | import com.ruoyi.system.query.TFeasibilityStudyReportQuery; |
| | | import com.ruoyi.system.vo.TFeasibilityStudyReportVO; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * <p> |
| | |
| | | */ |
| | | public interface TFeasibilityStudyReportMapper extends BaseMapper<TFeasibilityStudyReport> { |
| | | |
| | | /** |
| | | * 分页查询可研、可行、工艺开发工具、验证发布报告管理 |
| | | * @param query |
| | | * @param pageInfo |
| | | * @return |
| | | */ |
| | | List<TFeasibilityStudyReportVO> pageList(@Param("query") TFeasibilityStudyReportQuery query, @Param("pageInfo")PageInfo<TFeasibilityStudyReportVO> pageInfo); |
| | | } |
| | |
| | | package com.ruoyi.system.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.ruoyi.common.basic.PageInfo; |
| | | import com.ruoyi.system.model.TQaProduceReport; |
| | | import com.ruoyi.system.query.TQaProduceReportQuery; |
| | | import com.ruoyi.system.vo.TQaProduceReportVO; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * <p> |
| | |
| | | */ |
| | | public interface TQaProduceReportMapper extends BaseMapper<TQaProduceReport> { |
| | | |
| | | /** |
| | | * 分页查询 |
| | | * @param query |
| | | * @param pageInfo |
| | | * @return |
| | | */ |
| | | List<TQaProduceReportVO> pageList(@Param("query") TQaProduceReportQuery query, @Param("pageInfo")PageInfo<TQaProduceReportVO> pageInfo); |
| | | } |
| | |
| | | package com.ruoyi.system.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.ruoyi.common.basic.PageInfo; |
| | | import com.ruoyi.system.model.TQaTestItemReport; |
| | | import com.ruoyi.system.query.TQaTestItemReportQuery; |
| | | import com.ruoyi.system.vo.TQaTestItemReportVO; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | |
| | | * @return |
| | | */ |
| | | List<TQaTestItemReportVO> getList(@Param("itemId") String itemId); |
| | | |
| | | /** |
| | | * 获取分页列表 |
| | | * @param query |
| | | * @param pageInfo |
| | | * @return |
| | | */ |
| | | List<TQaTestItemReportVO> pageList(@Param("query")TQaTestItemReportQuery query, @Param("pageInfo")PageInfo<TQaTestItemReportVO> pageInfo); |
| | | } |
New file |
| | |
| | | package com.ruoyi.system.query; |
| | | |
| | | import com.ruoyi.common.core.domain.model.TimeRangeQueryBody; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | @Data |
| | | @ApiModel(value="可研、可行、工艺开发工具、验证发布报告管理查询参数query") |
| | | public class TFeasibilityStudyReportQuery extends TimeRangeQueryBody { |
| | | |
| | | @ApiModelProperty(value = "项目组名称") |
| | | private String teamName; |
| | | |
| | | @ApiModelProperty(value = "报告标题") |
| | | private String reportTitle; |
| | | |
| | | @ApiModelProperty(value = "报告编号") |
| | | private String reportCode; |
| | | |
| | | @ApiModelProperty(value = "状态 -1=草稿箱 1=待审核 2=待评定 3=已评定 4=已驳回 5=已撤回") |
| | | private Integer status; |
| | | |
| | | } |
New file |
| | |
| | | package com.ruoyi.system.query; |
| | | |
| | | import com.ruoyi.common.core.domain.BasePage; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | @Data |
| | | @ApiModel(value = "中试、生产验证分析报告;辅料;产品报告查询条件query") |
| | | public class TQaProduceReportQuery extends BasePage { |
| | | |
| | | @ApiModelProperty(value = "项目组名称") |
| | | private String teamName; |
| | | |
| | | @ApiModelProperty(value = "报告标题") |
| | | private String reportTitle; |
| | | |
| | | @ApiModelProperty(value = "报告编号") |
| | | private String reportCode; |
| | | |
| | | @ApiModelProperty(value = "状态 -1=草稿箱 1=待审核 2=已通过待评定 3=已评定 4=已驳回 5=已撤销 ") |
| | | private Integer status; |
| | | |
| | | } |
| | |
| | | @ApiModel(value = "检测项查询分页query") |
| | | public class TQaTestItemQuery extends BasePage { |
| | | |
| | | @ApiModelProperty(value = "项目组名称") |
| | | private String teamName; |
| | | |
| | | @ApiModelProperty(value = "检测项名称") |
| | | private String itemName; |
| | | |
| | |
| | | @ApiModelProperty(value = "状态 -1=草稿箱 1=已提交 2=待评定 3=已评定") |
| | | private Integer status; |
| | | |
| | | @ApiModelProperty(value = "组名称") |
| | | private String teamName; |
| | | } |
New file |
| | |
| | | package com.ruoyi.system.query; |
| | | |
| | | import com.ruoyi.common.core.domain.BasePage; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | @Data |
| | | @ApiModel(value = "QA检测项检测报告分页query") |
| | | public class TQaTestItemReportQuery extends BasePage { |
| | | |
| | | @ApiModelProperty(value = "项目组名称") |
| | | private String teamName; |
| | | |
| | | @ApiModelProperty(value = "检测项名称") |
| | | private String itemName; |
| | | |
| | | @ApiModelProperty(value = "检测项编号") |
| | | private String itemCode; |
| | | |
| | | @ApiModelProperty(value = "报告内容 1=国家标准 2=分析方法开发 3=方法验证报告 4=方法确认 5=操作规程 6=方法转移记录清单") |
| | | private String reportContent; |
| | | |
| | | @ApiModelProperty(value = "状态 -1=草稿箱 1=待审核 2=已通过 3=已驳回 4=已撤销") |
| | | private Integer status; |
| | | |
| | | } |
| | |
| | | package com.ruoyi.system.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.common.basic.PageInfo; |
| | | import com.ruoyi.system.model.TFeasibilityStudyReport; |
| | | import com.ruoyi.system.query.TFeasibilityStudyReportQuery; |
| | | import com.ruoyi.system.vo.TFeasibilityStudyReportVO; |
| | | |
| | | /** |
| | | * <p> |
| | |
| | | */ |
| | | public interface TFeasibilityStudyReportService extends IService<TFeasibilityStudyReport> { |
| | | |
| | | /** |
| | | * 获取可研、可行、工艺开发工具、验证发布报告管理分页列表 |
| | | * @param query |
| | | * @return |
| | | */ |
| | | PageInfo<TFeasibilityStudyReportVO> pageList(TFeasibilityStudyReportQuery query); |
| | | } |
| | |
| | | package com.ruoyi.system.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.common.basic.PageInfo; |
| | | import com.ruoyi.system.model.TQaProduceReport; |
| | | import com.ruoyi.system.query.TQaProduceReportQuery; |
| | | import com.ruoyi.system.vo.TQaProduceReportVO; |
| | | |
| | | /** |
| | | * <p> |
| | |
| | | */ |
| | | public interface TQaProduceReportService extends IService<TQaProduceReport> { |
| | | |
| | | /** |
| | | * 获取中试、生产验证分析报告;辅料;产品报告管理分页列表 |
| | | * @param query |
| | | * @return |
| | | */ |
| | | PageInfo<TQaProduceReportVO> pageList(TQaProduceReportQuery query); |
| | | } |
| | |
| | | package com.ruoyi.system.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.common.basic.PageInfo; |
| | | import com.ruoyi.system.model.TQaTestItemReport; |
| | | import com.ruoyi.system.query.TQaTestItemReportQuery; |
| | | import com.ruoyi.system.vo.TQaTestItemReportVO; |
| | | |
| | | import java.util.List; |
| | |
| | | * @return |
| | | */ |
| | | List<TQaTestItemReportVO> getList(String itemId); |
| | | |
| | | /** |
| | | * 获取检测项报告分页列表 |
| | | * @param query |
| | | * @return |
| | | */ |
| | | PageInfo<TQaTestItemReportVO> pageList(TQaTestItemReportQuery query); |
| | | } |
| | |
| | | package com.ruoyi.system.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.common.basic.PageInfo; |
| | | import com.ruoyi.system.mapper.TFeasibilityStudyReportMapper; |
| | | import com.ruoyi.system.model.TFeasibilityStudyReport; |
| | | import com.ruoyi.system.query.TFeasibilityStudyReportQuery; |
| | | import com.ruoyi.system.service.TFeasibilityStudyReportService; |
| | | import com.ruoyi.system.vo.TFeasibilityStudyReportVO; |
| | | import com.ruoyi.system.vo.TQaTestItemVO; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * <p> |
| | |
| | | @Service |
| | | public class TFeasibilityStudyReportServiceImpl extends ServiceImpl<TFeasibilityStudyReportMapper, TFeasibilityStudyReport> implements TFeasibilityStudyReportService { |
| | | |
| | | @Override |
| | | public PageInfo<TFeasibilityStudyReportVO> pageList(TFeasibilityStudyReportQuery query) { |
| | | PageInfo<TFeasibilityStudyReportVO> pageInfo = new PageInfo<>(query.getPageNum(), query.getPageSize()); |
| | | List<TFeasibilityStudyReportVO> list = this.baseMapper.pageList(query,pageInfo); |
| | | pageInfo.setRecords(list); |
| | | return pageInfo; |
| | | } |
| | | } |
| | |
| | | package com.ruoyi.system.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.common.basic.PageInfo; |
| | | import com.ruoyi.system.mapper.TQaProduceReportMapper; |
| | | import com.ruoyi.system.model.TQaProduceReport; |
| | | import com.ruoyi.system.query.TQaProduceReportQuery; |
| | | import com.ruoyi.system.service.TQaProduceReportService; |
| | | import com.ruoyi.system.vo.TExperimentResultReportVO; |
| | | import com.ruoyi.system.vo.TQaProduceReportVO; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * <p> |
| | |
| | | @Service |
| | | public class TQaProduceReportServiceImpl extends ServiceImpl<TQaProduceReportMapper, TQaProduceReport> implements TQaProduceReportService { |
| | | |
| | | @Override |
| | | public PageInfo<TQaProduceReportVO> pageList(TQaProduceReportQuery query) { |
| | | PageInfo<TQaProduceReportVO> pageInfo = new PageInfo<>(query.getPageNum(), query.getPageSize()); |
| | | List<TQaProduceReportVO> list = this.baseMapper.pageList(query,pageInfo); |
| | | pageInfo.setRecords(list); |
| | | return pageInfo; |
| | | } |
| | | } |
| | |
| | | |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.common.basic.PageInfo; |
| | | import com.ruoyi.common.enums.QaReportFileEnum; |
| | | import com.ruoyi.system.mapper.TQaReportFileMapper; |
| | | import com.ruoyi.system.mapper.TQaTestItemReportMapper; |
| | | import com.ruoyi.system.model.TQaReportFile; |
| | | import com.ruoyi.system.model.TQaTestItemReport; |
| | | import com.ruoyi.system.query.TQaTestItemReportQuery; |
| | | import com.ruoyi.system.service.TQaTestItemReportService; |
| | | import com.ruoyi.system.vo.TExperimentSchemeVO; |
| | | import com.ruoyi.system.vo.TQaTestItemReportVO; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | |
| | | } |
| | | return list; |
| | | } |
| | | |
| | | @Override |
| | | public PageInfo<TQaTestItemReportVO> pageList(TQaTestItemReportQuery query) { |
| | | PageInfo<TQaTestItemReportVO> pageInfo = new PageInfo<>(query.getPageNum(), query.getPageSize()); |
| | | List<TQaTestItemReportVO> list = this.baseMapper.pageList(query,pageInfo); |
| | | pageInfo.setRecords(list); |
| | | return pageInfo; |
| | | } |
| | | } |
New file |
| | |
| | | package com.ruoyi.system.vo; |
| | | |
| | | import com.ruoyi.system.model.TFeasibilityReportFile; |
| | | import com.ruoyi.system.model.TFeasibilityStudyReport; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.util.List; |
| | | |
| | | @Data |
| | | @ApiModel(value = "可研、可行、工艺开发工具、验证发布报告管理VO") |
| | | public class TFeasibilityStudyReportVO extends TFeasibilityStudyReport { |
| | | |
| | | @ApiModelProperty(value = "项目组名称") |
| | | private String teamName; |
| | | |
| | | @ApiModelProperty(value = "报告文件") |
| | | private List<TFeasibilityReportFile> feasibilityReportFiles; |
| | | |
| | | } |
New file |
| | |
| | | package com.ruoyi.system.vo; |
| | | |
| | | import com.ruoyi.system.model.TQaProduceReport; |
| | | import com.ruoyi.system.model.TQaReportFile; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.util.List; |
| | | |
| | | @Data |
| | | @ApiModel(value = "中试、生产验证分析报告;辅料;产品报告VO") |
| | | public class TQaProduceReportVO extends TQaProduceReport { |
| | | |
| | | @ApiModelProperty(value = "项目组名称") |
| | | private String teamName; |
| | | |
| | | @ApiModelProperty(value = "检测报告文件") |
| | | private List<TQaReportFile> qaReportFileList; |
| | | } |
| | |
| | | @ApiModelProperty(value = "项目组信息") |
| | | private TProjectTeam projectTeam; |
| | | |
| | | @ApiModelProperty(value = "组名称") |
| | | @ApiModelProperty(value = "项目组名称") |
| | | private String teamName; |
| | | |
| | | @ApiModelProperty(value = "检测报告列表") |
| | |
| | | <sql id="Base_Column_List"> |
| | | id, team_id, report_code, report_name, report_text, report_type, status, audit_person_id, audit_time, audit_remark, evaluate_person_id, evaluate_time, evaluate_score, create_time, update_time, create_by, update_by, disabled |
| | | </sql> |
| | | <select id="pageList" resultType="com.ruoyi.system.vo.TFeasibilityStudyReportVO"> |
| | | select tfsr.id, tfsr.team_id, tfsr.report_code, tfsr.report_name, tfsr.report_text, tfsr.report_type, tfsr.status, |
| | | tfsr.audit_person_id, tfsr.audit_time, tfsr.audit_remark, tfsr.evaluate_person_id, tfsr.evaluate_time, tfsr.evaluate_score, |
| | | tfsr.create_time, tfsr.update_time, tfsr.create_by, tfsr.update_by, tfsr.disabled, tpt.team_name as teamName |
| | | from t_feasibility_study_report tfsr |
| | | left join t_project_team tpt on tpt.id = tfsr.team_id |
| | | <where> |
| | | <if test="query.reportName != null and query.reportName != ''"> |
| | | and tfsr.report_name like concat('%', #{query.reportName}, '%') |
| | | </if> |
| | | <if test="query.reportCode != null and query.reportCode != ''"> |
| | | and tfsr.report_code like concat('%', #{query.reportCode}, '%') |
| | | </if> |
| | | <if test="query.teamName != null and query.teamName != ''"> |
| | | and tpt.team_name like concat('%', #{query.teamName}) |
| | | </if> |
| | | <if test="query.status != null"> |
| | | and tfsr.status = #{query.status} |
| | | </if> |
| | | <if test="query.startTime != null and query.startTime != '' and query.endTime != null and query.endTime != ''"> |
| | | AND tfsr.create_time BETWEEN #{query.startTime} AND #{query.endTime} |
| | | </if> |
| | | AND tfsr.disabled = ${@com.ruoyi.common.enums.DisabledEnum@NO.getCode()} |
| | | </where> |
| | | ORDER BY tfsr.create_time DESC |
| | | </select> |
| | | |
| | | </mapper> |
| | |
| | | <sql id="Base_Column_List"> |
| | | id, team_id, report_title, report_code, develop_person, develop_date, report_text, report_type, audit_person_id, audit_time, audit_remark, status, evaluate_person_id, evaluate_time, evaluate_score, create_time, update_time, create_by, update_by, disabled |
| | | </sql> |
| | | <select id="pageList" resultType="com.ruoyi.system.vo.TQaProduceReportVO"> |
| | | select tqpr.id, tqpr.team_id, tqpr.report_title, tqpr.report_code, tqpr.develop_person, tqpr.develop_date, |
| | | tqpr.report_text, tqpr.report_type, tqpr.audit_person_id, tqpr.audit_time, tqpr.audit_remark, tqpr.status, |
| | | tqpr.evaluate_person_id, tqpr.evaluate_time, tqpr.evaluate_score, tqpr.create_time, tqpr.update_time, |
| | | tqpr.create_by, tqpr.update_by, tqpr.disabled, tpt.team_name as teamName |
| | | from t_qa_produce_report tqpr |
| | | left join t_project_team tpt on tpt.id = tqpr.team_id |
| | | <where> |
| | | <if test="query.reportTitle != null and query.reportTitle != ''"> |
| | | and tqpr.report_title like concat('%', #{query.reportTitle}, '%') |
| | | </if> |
| | | <if test="query.reportCode != null and query.reportCode != ''"> |
| | | and tqpr.report_code like concat('%', #{query.reportCode}, '%') |
| | | </if> |
| | | <if test="query.teamName != null and query.teamName != ''"> |
| | | and tpt.team_name like concat('%', #{query.teamName}, '%') |
| | | </if> |
| | | <if test="query.status != null"> |
| | | and tqpr.status = #{query.status} |
| | | </if> |
| | | AND tqpr.disabled = ${@com.ruoyi.common.enums.DisabledEnum@NO.getCode()} |
| | | </where> |
| | | ORDER BY tqpr.create_time DESC |
| | | </select> |
| | | |
| | | </mapper> |
| | |
| | | where item_id = #{itemId} |
| | | order by create_time desc |
| | | </select> |
| | | <select id="pageList" resultType="com.ruoyi.system.vo.TQaTestItemReportVO"> |
| | | select tqtir.id, tqtir.item_id, tqtir.report_content, tqtir.develop_person, tqtir.develop_date, tqtir.report_text, |
| | | tqtir.audit_person_id, tqtir.audit_time, tqtir.audit_remark, tqtir.status, tqtir.create_time, tqtir.update_time, |
| | | tqtir.create_by, tqtir.update_by, tqtir.disabled,tqti.item_name as itemName, tqti.item_code as itemCode, |
| | | tpt.team_name as teamName |
| | | from t_qa_test_item_report tqtir |
| | | left join t_qa_test_item tqti on tqti.id = tqtir.item_id |
| | | left join t_project_team tpt on tpt.id = tqti.team_id |
| | | <where> |
| | | <if test="query.teamName != null and query.teamName != ''"> |
| | | and tpt.team_name like concat('%', #{query.teamName}, '%') |
| | | </if> |
| | | <if test="query.itemName != null and query.itemName != ''"> |
| | | and tqti.item_name like concat('%', #{query.itemName}, '%') |
| | | </if> |
| | | <if test="query.itemCode != null and query.itemCode != ''"> |
| | | and tqti.item_code like concat('%', #{query.itemCode}, '%') |
| | | </if> |
| | | <if test="query.reportContent != null and query.reportContent != ''"> |
| | | and tqtir.report_content = #{query.reportContent} |
| | | </if> |
| | | <if test="query.status != null"> |
| | | and tqtir.status = #{query.status} |
| | | </if> |
| | | AND tqtir.disabled = ${@com.ruoyi.common.enums.DisabledEnum@NO.getCode()} |
| | | </where> |
| | | ORDER BY tqtir.create_time DESC |
| | | </select> |
| | | |
| | | </mapper> |