¶Ô±ÈÐÂÎļþ |
| | |
| | | package org.jeecg.modules.qms.controller; |
| | | |
| | | import java.util.Arrays; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | import java.util.stream.Collectors; |
| | | import java.io.IOException; |
| | | import java.io.UnsupportedEncodingException; |
| | | import java.net.URLDecoder; |
| | | import javax.servlet.http.HttpServletRequest; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import org.jeecg.common.api.vo.Result; |
| | | import org.jeecg.common.constant.CommonConstant; |
| | | import org.jeecg.common.system.query.QueryGenerator; |
| | | import org.jeecg.common.util.oConvertUtils; |
| | | import org.jeecg.modules.qms.entity.Defect; |
| | | import org.jeecg.modules.qms.entity.InspectionItem; |
| | | import org.jeecg.modules.qms.service.IDefectService; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | |
| | | import org.jeecgframework.poi.excel.ExcelImportUtil; |
| | | import org.jeecgframework.poi.excel.def.NormalExcelConstants; |
| | | import org.jeecgframework.poi.excel.entity.ExportParams; |
| | | import org.jeecgframework.poi.excel.entity.ImportParams; |
| | | import org.jeecgframework.poi.excel.view.JeecgEntityExcelView; |
| | | import org.jeecg.common.system.base.controller.JeecgController; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | import org.springframework.web.multipart.MultipartHttpServletRequest; |
| | | import org.springframework.web.servlet.ModelAndView; |
| | | import com.alibaba.fastjson.JSON; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.jeecg.common.aspect.annotation.AutoLog; |
| | | |
| | | /** |
| | | * @Description: 缺é·ç»´æ¤ |
| | | * @Author: jeecg-boot |
| | | * @Date: 2025-07-02 |
| | | * @Version: V1.0 |
| | | */ |
| | | @Api(tags="缺é·ç»´æ¤") |
| | | @RestController |
| | | @RequestMapping("/qms/defect") |
| | | @Slf4j |
| | | public class DefectController extends JeecgController<Defect, IDefectService> { |
| | | @Autowired |
| | | private IDefectService defectService; |
| | | |
| | | /** |
| | | * å页å表æ¥è¯¢ |
| | | * |
| | | * @param defect |
| | | * @param pageNo |
| | | * @param pageSize |
| | | * @param req |
| | | * @return |
| | | */ |
| | | //@AutoLog(value = "缺é·ç»´æ¤-å页å表æ¥è¯¢") |
| | | @ApiOperation(value="缺é·ç»´æ¤-å页å表æ¥è¯¢", notes="缺é·ç»´æ¤-å页å表æ¥è¯¢") |
| | | @GetMapping(value = "/list") |
| | | public Result<IPage<Defect>> queryPageList(Defect defect, |
| | | @RequestParam(name="pageNo", defaultValue="1") Integer pageNo, |
| | | @RequestParam(name="pageSize", defaultValue="10") Integer pageSize, |
| | | HttpServletRequest req) { |
| | | QueryWrapper<Defect> queryWrapper = QueryGenerator.initQueryWrapper(defect, req.getParameterMap()); |
| | | Page<Defect> page = new Page<Defect>(pageNo, pageSize); |
| | | IPage<Defect> pageList = defectService.page(page, queryWrapper); |
| | | return Result.OK(pageList); |
| | | } |
| | | |
| | | /** |
| | | * æ·»å |
| | | * |
| | | * @param defect |
| | | * @return |
| | | */ |
| | | @AutoLog(value = "缺é·ç»´æ¤-æ·»å ") |
| | | @ApiOperation(value="缺é·ç»´æ¤-æ·»å ", notes="缺é·ç»´æ¤-æ·»å ") |
| | | //@RequiresPermissions("org.jeecg.modules:qms_defect:add") |
| | | @PostMapping(value = "/add") |
| | | public Result<String> add(@RequestBody Defect defect) { |
| | | defect.setDefectStatus(CommonConstant.STATUS_1); |
| | | defectService.save(defect); |
| | | return Result.OK("æ·»å æåï¼"); |
| | | } |
| | | |
| | | /** |
| | | * ç¼è¾ |
| | | * |
| | | * @param defect |
| | | * @return |
| | | */ |
| | | @AutoLog(value = "缺é·ç»´æ¤-ç¼è¾") |
| | | @ApiOperation(value="缺é·ç»´æ¤-ç¼è¾", notes="缺é·ç»´æ¤-ç¼è¾") |
| | | //@RequiresPermissions("org.jeecg.modules:qms_defect:edit") |
| | | @RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST}) |
| | | public Result<String> edit(@RequestBody Defect defect) { |
| | | defectService.updateById(defect); |
| | | return Result.OK("ç¼è¾æå!"); |
| | | } |
| | | |
| | | /** |
| | | * éè¿idå é¤ |
| | | * |
| | | * @param id |
| | | * @return |
| | | */ |
| | | @AutoLog(value = "缺é·ç»´æ¤-éè¿idå é¤") |
| | | @ApiOperation(value="缺é·ç»´æ¤-éè¿idå é¤", notes="缺é·ç»´æ¤-éè¿idå é¤") |
| | | //@RequiresPermissions("org.jeecg.modules:qms_defect:delete") |
| | | @DeleteMapping(value = "/delete") |
| | | public Result<String> delete(@RequestParam(name="id",required=true) String id) { |
| | | defectService.removeById(id); |
| | | return Result.OK("å 餿å!"); |
| | | } |
| | | |
| | | /** |
| | | * æ¹éå é¤ |
| | | * |
| | | * @param ids |
| | | * @return |
| | | */ |
| | | @AutoLog(value = "缺é·ç»´æ¤-æ¹éå é¤") |
| | | @ApiOperation(value="缺é·ç»´æ¤-æ¹éå é¤", notes="缺é·ç»´æ¤-æ¹éå é¤") |
| | | //@RequiresPermissions("org.jeecg.modules:qms_defect:deleteBatch") |
| | | @DeleteMapping(value = "/deleteBatch") |
| | | public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) { |
| | | this.defectService.removeByIds(Arrays.asList(ids.split(","))); |
| | | return Result.OK("æ¹éå 餿å!"); |
| | | } |
| | | |
| | | /** |
| | | * éè¿idæ¥è¯¢ |
| | | * |
| | | * @param id |
| | | * @return |
| | | */ |
| | | //@AutoLog(value = "缺é·ç»´æ¤-éè¿idæ¥è¯¢") |
| | | @ApiOperation(value="缺é·ç»´æ¤-éè¿idæ¥è¯¢", notes="缺é·ç»´æ¤-éè¿idæ¥è¯¢") |
| | | @GetMapping(value = "/queryById") |
| | | public Result<Defect> queryById(@RequestParam(name="id",required=true) String id) { |
| | | Defect defect = defectService.getById(id); |
| | | if(defect==null) { |
| | | return Result.error("æªæ¾å°å¯¹åºæ°æ®"); |
| | | } |
| | | return Result.OK(defect); |
| | | } |
| | | |
| | | /** |
| | | * 导åºexcel |
| | | * |
| | | * @param request |
| | | * @param defect |
| | | */ |
| | | //@RequiresPermissions("org.jeecg.modules:qms_defect:exportXls") |
| | | @RequestMapping(value = "/exportXls") |
| | | public ModelAndView exportXls(HttpServletRequest request, Defect defect) { |
| | | return super.exportXls(request, defect, Defect.class, "缺é·ç»´æ¤"); |
| | | } |
| | | |
| | | /** |
| | | * éè¿excel导å
¥æ°æ® |
| | | * |
| | | * @param request |
| | | * @param response |
| | | * @return |
| | | */ |
| | | //@RequiresPermissions("qms_defect:importExcel") |
| | | @RequestMapping(value = "/importExcel", method = RequestMethod.POST) |
| | | public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) { |
| | | return super.importExcel(request, response, Defect.class); |
| | | } |
| | | |
| | | @AutoLog(value = "缺é·ç»´æ¤-å¯ç¨&ç¦ç¨") |
| | | @ApiOperation(value = "缺é·ç»´æ¤-å¯ç¨&ç¦ç¨", notes = "缺é·ç»´æ¤-å¯ç¨&ç¦ç¨") |
| | | @PutMapping(value = "/active") |
| | | public Result<?> active(@RequestParam(name = "id", required = true) String id) { |
| | | Defect defect = defectService.getById(id); |
| | | if (CommonConstant.STATUS_1.equals(defect.getDefectStatus())) { |
| | | defect.setDefectStatus(CommonConstant.STATUS_0); |
| | | } else { |
| | | defect.setDefectStatus(CommonConstant.STATUS_1); |
| | | } |
| | | defectService.updateById(defect); |
| | | return Result.ok("æä½æåï¼"); |
| | | } |
| | | |
| | | } |
| | |
| | | package org.jeecg.modules.qms.controller; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.Arrays; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | |
| | | import java.net.URLDecoder; |
| | | import javax.servlet.http.HttpServletRequest; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | |
| | | import org.apache.commons.lang3.StringUtils; |
| | | import org.jeecg.common.api.vo.Result; |
| | | import org.jeecg.common.constant.CommonConstant; |
| | | import org.jeecg.common.system.query.QueryGenerator; |
| | | import org.jeecg.common.util.oConvertUtils; |
| | | import org.jeecg.modules.qms.entity.InspectionItem; |
| | | import org.jeecg.modules.qms.entity.InspectionTools; |
| | | import org.jeecg.modules.qms.service.IInspectionItemService; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | |
| | | import org.jeecg.modules.qms.service.IInspectionToolsService; |
| | | import org.jeecgframework.poi.excel.ExcelImportUtil; |
| | | import org.jeecgframework.poi.excel.def.NormalExcelConstants; |
| | | import org.jeecgframework.poi.excel.entity.ExportParams; |
| | |
| | | public class InspectionItemController extends JeecgController<InspectionItem, IInspectionItemService> { |
| | | @Autowired |
| | | private IInspectionItemService inspectionItemService; |
| | | |
| | | @Autowired |
| | | private IInspectionToolsService inspectionToolsService; |
| | | |
| | | /** |
| | | * å页å表æ¥è¯¢ |
| | |
| | | return super.importExcel(request, response, InspectionItem.class); |
| | | } |
| | | |
| | | @AutoLog(value = "æ£éªé¡¹ç®-å¯ç¨&ç¦ç¨") |
| | | @ApiOperation(value = "æ£éªé¡¹ç®-å¯ç¨&ç¦ç¨", notes = "æ£éªé¡¹ç®-å¯ç¨&ç¦ç¨") |
| | | @PutMapping(value = "/active") |
| | | public Result<?> active(@RequestParam(name = "id", required = true) String id) { |
| | | InspectionItem inspectionItem = inspectionItemService.getById(id); |
| | | if (CommonConstant.STATUS_1.equals(inspectionItem.getItemStatus())) { |
| | | inspectionItem.setItemStatus(CommonConstant.STATUS_0); |
| | | } else { |
| | | inspectionItem.setItemStatus(CommonConstant.STATUS_1); |
| | | } |
| | | inspectionItemService.updateById(inspectionItem); |
| | | return Result.ok("æä½æåï¼"); |
| | | } |
| | | |
| | | /** |
| | | * å页å表æ¥è¯¢ |
| | | * |
| | | * @param inspectionItem |
| | | * @param pageNo |
| | | * @param pageSize |
| | | * @param query |
| | | * @return |
| | | */ |
| | | @ApiOperation(value="æ£éªé¡¹ç®-å页å表æ¥è¯¢", notes="æ£éªé¡¹ç®-å页å表æ¥è¯¢") |
| | | @GetMapping(value = "/queryList") |
| | | public Result<?> queryList(InspectionItem inspectionItem, |
| | | @RequestParam(name="pageNo", defaultValue="1") Integer pageNo, |
| | | @RequestParam(name="pageSize", defaultValue="10") Integer pageSize, |
| | | @RequestParam Map<String, String> query) { |
| | | IPage<Map<String, Object>> pageList = inspectionItemService.queryList(pageNo,pageSize, query); |
| | | for(Map<String, Object> r : pageList.getRecords()){ |
| | | String inspectionTools = (String) r.get("inspectionTools"); |
| | | if(StringUtils.isNotBlank(inspectionTools)){ |
| | | List<String> inspectionToolsList = Arrays.asList(inspectionTools.split(",")); |
| | | List<String> inspectionToolsNameList = new ArrayList<>(); |
| | | String inspectionToolsNames = ""; |
| | | for(String inspectionTool : inspectionToolsList){ |
| | | InspectionTools inspectionTools1 = inspectionToolsService.getById(inspectionTool); |
| | | if(inspectionTools1 != null){ |
| | | inspectionToolsNameList.add(inspectionTools1.getToolName()); |
| | | } |
| | | } |
| | | inspectionToolsNames = inspectionToolsNameList.stream() |
| | | .collect(Collectors.joining(",")); |
| | | r.put("inspectionToolsNames",inspectionToolsNames); |
| | | |
| | | } |
| | | |
| | | } |
| | | |
| | | return Result.OK(pageList); |
| | | } |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package org.jeecg.modules.qms.controller; |
| | | |
| | | import java.util.Arrays; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | import java.util.stream.Collectors; |
| | | import java.io.IOException; |
| | | import java.io.UnsupportedEncodingException; |
| | | import java.net.URLDecoder; |
| | | import javax.servlet.http.HttpServletRequest; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import org.jeecg.common.api.vo.Result; |
| | | import org.jeecg.common.constant.CommonConstant; |
| | | import org.jeecg.common.system.query.QueryGenerator; |
| | | import org.jeecg.common.util.oConvertUtils; |
| | | import org.jeecg.modules.qms.entity.Defect; |
| | | import org.jeecg.modules.qms.entity.InspectionPlan; |
| | | import org.jeecg.modules.qms.service.IInspectionPlanService; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | |
| | | import org.jeecgframework.poi.excel.ExcelImportUtil; |
| | | import org.jeecgframework.poi.excel.def.NormalExcelConstants; |
| | | import org.jeecgframework.poi.excel.entity.ExportParams; |
| | | import org.jeecgframework.poi.excel.entity.ImportParams; |
| | | import org.jeecgframework.poi.excel.view.JeecgEntityExcelView; |
| | | import org.jeecg.common.system.base.controller.JeecgController; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | import org.springframework.web.multipart.MultipartHttpServletRequest; |
| | | import org.springframework.web.servlet.ModelAndView; |
| | | import com.alibaba.fastjson.JSON; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.jeecg.common.aspect.annotation.AutoLog; |
| | | |
| | | /** |
| | | * @Description: æ£éªæ¹æ¡ |
| | | * @Author: jeecg-boot |
| | | * @Date: 2025-07-02 |
| | | * @Version: V1.0 |
| | | */ |
| | | @Api(tags="æ£éªæ¹æ¡") |
| | | @RestController |
| | | @RequestMapping("/qms/inspectionPlan") |
| | | @Slf4j |
| | | public class InspectionPlanController extends JeecgController<InspectionPlan, IInspectionPlanService> { |
| | | @Autowired |
| | | private IInspectionPlanService inspectionPlanService; |
| | | |
| | | /** |
| | | * å页å表æ¥è¯¢ |
| | | * |
| | | * @param inspectionPlan |
| | | * @param pageNo |
| | | * @param pageSize |
| | | * @param req |
| | | * @return |
| | | */ |
| | | //@AutoLog(value = "æ£éªæ¹æ¡-å页å表æ¥è¯¢") |
| | | @ApiOperation(value="æ£éªæ¹æ¡-å页å表æ¥è¯¢", notes="æ£éªæ¹æ¡-å页å表æ¥è¯¢") |
| | | @GetMapping(value = "/list") |
| | | public Result<IPage<InspectionPlan>> queryPageList(InspectionPlan inspectionPlan, |
| | | @RequestParam(name="pageNo", defaultValue="1") Integer pageNo, |
| | | @RequestParam(name="pageSize", defaultValue="10") Integer pageSize, |
| | | HttpServletRequest req) { |
| | | QueryWrapper<InspectionPlan> queryWrapper = QueryGenerator.initQueryWrapper(inspectionPlan, req.getParameterMap()); |
| | | Page<InspectionPlan> page = new Page<InspectionPlan>(pageNo, pageSize); |
| | | IPage<InspectionPlan> pageList = inspectionPlanService.page(page, queryWrapper); |
| | | return Result.OK(pageList); |
| | | } |
| | | |
| | | /** |
| | | * æ·»å |
| | | * |
| | | * @param inspectionPlan |
| | | * @return |
| | | */ |
| | | @AutoLog(value = "æ£éªæ¹æ¡-æ·»å ") |
| | | @ApiOperation(value="æ£éªæ¹æ¡-æ·»å ", notes="æ£éªæ¹æ¡-æ·»å ") |
| | | //@RequiresPermissions("org.jeecg.modules:qms_inspection_plan:add") |
| | | @PostMapping(value = "/add") |
| | | public Result<String> add(@RequestBody InspectionPlan inspectionPlan) { |
| | | inspectionPlan.setPlanStatus(CommonConstant.STATUS_1); |
| | | inspectionPlanService.save(inspectionPlan); |
| | | return Result.OK("æ·»å æåï¼"); |
| | | } |
| | | |
| | | /** |
| | | * ç¼è¾ |
| | | * |
| | | * @param inspectionPlan |
| | | * @return |
| | | */ |
| | | @AutoLog(value = "æ£éªæ¹æ¡-ç¼è¾") |
| | | @ApiOperation(value="æ£éªæ¹æ¡-ç¼è¾", notes="æ£éªæ¹æ¡-ç¼è¾") |
| | | //@RequiresPermissions("org.jeecg.modules:qms_inspection_plan:edit") |
| | | @RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST}) |
| | | public Result<String> edit(@RequestBody InspectionPlan inspectionPlan) { |
| | | inspectionPlanService.updateById(inspectionPlan); |
| | | return Result.OK("ç¼è¾æå!"); |
| | | } |
| | | |
| | | /** |
| | | * éè¿idå é¤ |
| | | * |
| | | * @param id |
| | | * @return |
| | | */ |
| | | @AutoLog(value = "æ£éªæ¹æ¡-éè¿idå é¤") |
| | | @ApiOperation(value="æ£éªæ¹æ¡-éè¿idå é¤", notes="æ£éªæ¹æ¡-éè¿idå é¤") |
| | | //@RequiresPermissions("org.jeecg.modules:qms_inspection_plan:delete") |
| | | @DeleteMapping(value = "/delete") |
| | | public Result<String> delete(@RequestParam(name="id",required=true) String id) { |
| | | inspectionPlanService.removeById(id); |
| | | return Result.OK("å 餿å!"); |
| | | } |
| | | |
| | | /** |
| | | * æ¹éå é¤ |
| | | * |
| | | * @param ids |
| | | * @return |
| | | */ |
| | | @AutoLog(value = "æ£éªæ¹æ¡-æ¹éå é¤") |
| | | @ApiOperation(value="æ£éªæ¹æ¡-æ¹éå é¤", notes="æ£éªæ¹æ¡-æ¹éå é¤") |
| | | //@RequiresPermissions("org.jeecg.modules:qms_inspection_plan:deleteBatch") |
| | | @DeleteMapping(value = "/deleteBatch") |
| | | public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) { |
| | | this.inspectionPlanService.removeByIds(Arrays.asList(ids.split(","))); |
| | | return Result.OK("æ¹éå 餿å!"); |
| | | } |
| | | |
| | | /** |
| | | * éè¿idæ¥è¯¢ |
| | | * |
| | | * @param id |
| | | * @return |
| | | */ |
| | | //@AutoLog(value = "æ£éªæ¹æ¡-éè¿idæ¥è¯¢") |
| | | @ApiOperation(value="æ£éªæ¹æ¡-éè¿idæ¥è¯¢", notes="æ£éªæ¹æ¡-éè¿idæ¥è¯¢") |
| | | @GetMapping(value = "/queryById") |
| | | public Result<InspectionPlan> queryById(@RequestParam(name="id",required=true) String id) { |
| | | InspectionPlan inspectionPlan = inspectionPlanService.getById(id); |
| | | if(inspectionPlan==null) { |
| | | return Result.error("æªæ¾å°å¯¹åºæ°æ®"); |
| | | } |
| | | return Result.OK(inspectionPlan); |
| | | } |
| | | |
| | | /** |
| | | * 导åºexcel |
| | | * |
| | | * @param request |
| | | * @param inspectionPlan |
| | | */ |
| | | //@RequiresPermissions("org.jeecg.modules:qms_inspection_plan:exportXls") |
| | | @RequestMapping(value = "/exportXls") |
| | | public ModelAndView exportXls(HttpServletRequest request, InspectionPlan inspectionPlan) { |
| | | return super.exportXls(request, inspectionPlan, InspectionPlan.class, "æ£éªæ¹æ¡"); |
| | | } |
| | | |
| | | /** |
| | | * éè¿excel导å
¥æ°æ® |
| | | * |
| | | * @param request |
| | | * @param response |
| | | * @return |
| | | */ |
| | | //@RequiresPermissions("qms_inspection_plan:importExcel") |
| | | @RequestMapping(value = "/importExcel", method = RequestMethod.POST) |
| | | public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) { |
| | | return super.importExcel(request, response, InspectionPlan.class); |
| | | } |
| | | |
| | | @AutoLog(value = "æ£éªæ¹æ¡-å¯ç¨&ç¦ç¨") |
| | | @ApiOperation(value = "æ£éªæ¹æ¡-å¯ç¨&ç¦ç¨", notes = "æ£éªæ¹æ¡-å¯ç¨&ç¦ç¨") |
| | | @PutMapping(value = "/active") |
| | | public Result<?> active(@RequestParam(name = "id", required = true) String id) { |
| | | InspectionPlan inspectionPlan = inspectionPlanService.getById(id); |
| | | if (CommonConstant.STATUS_1.equals(inspectionPlan.getPlanStatus())) { |
| | | inspectionPlan.setPlanStatus(CommonConstant.STATUS_0); |
| | | } else { |
| | | inspectionPlan.setPlanStatus(CommonConstant.STATUS_1); |
| | | } |
| | | inspectionPlanService.updateById(inspectionPlan); |
| | | return Result.ok("æä½æåï¼"); |
| | | } |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package org.jeecg.modules.qms.controller; |
| | | |
| | | import java.util.Arrays; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | import java.util.stream.Collectors; |
| | | import java.io.IOException; |
| | | import java.io.UnsupportedEncodingException; |
| | | import java.net.URLDecoder; |
| | | import javax.servlet.http.HttpServletRequest; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import org.jeecg.common.api.vo.Result; |
| | | import org.jeecg.common.system.query.QueryGenerator; |
| | | import org.jeecg.common.util.oConvertUtils; |
| | | import org.jeecg.modules.qms.entity.InspectionPlanItem; |
| | | import org.jeecg.modules.qms.service.IInspectionPlanItemService; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | |
| | | import org.jeecgframework.poi.excel.ExcelImportUtil; |
| | | import org.jeecgframework.poi.excel.def.NormalExcelConstants; |
| | | import org.jeecgframework.poi.excel.entity.ExportParams; |
| | | import org.jeecgframework.poi.excel.entity.ImportParams; |
| | | import org.jeecgframework.poi.excel.view.JeecgEntityExcelView; |
| | | import org.jeecg.common.system.base.controller.JeecgController; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | import org.springframework.web.multipart.MultipartHttpServletRequest; |
| | | import org.springframework.web.servlet.ModelAndView; |
| | | import com.alibaba.fastjson.JSON; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.jeecg.common.aspect.annotation.AutoLog; |
| | | |
| | | /** |
| | | * @Description: æ£éªæ¹æ¡æ£éªé¡¹ |
| | | * @Author: jeecg-boot |
| | | * @Date: 2025-07-02 |
| | | * @Version: V1.0 |
| | | */ |
| | | @Api(tags="æ£éªæ¹æ¡æ£éªé¡¹") |
| | | @RestController |
| | | @RequestMapping("/qms/inspectionPlanItem") |
| | | @Slf4j |
| | | public class InspectionPlanItemController extends JeecgController<InspectionPlanItem, IInspectionPlanItemService> { |
| | | @Autowired |
| | | private IInspectionPlanItemService inspectionPlanItemService; |
| | | |
| | | /** |
| | | * å页å表æ¥è¯¢ |
| | | * |
| | | * @param inspectionPlanItem |
| | | * @param pageNo |
| | | * @param pageSize |
| | | * @param req |
| | | * @return |
| | | */ |
| | | //@AutoLog(value = "æ£éªæ¹æ¡æ£éªé¡¹-å页å表æ¥è¯¢") |
| | | @ApiOperation(value="æ£éªæ¹æ¡æ£éªé¡¹-å页å表æ¥è¯¢", notes="æ£éªæ¹æ¡æ£éªé¡¹-å页å表æ¥è¯¢") |
| | | @GetMapping(value = "/list") |
| | | public Result<IPage<InspectionPlanItem>> queryPageList(InspectionPlanItem inspectionPlanItem, |
| | | @RequestParam(name="pageNo", defaultValue="1") Integer pageNo, |
| | | @RequestParam(name="pageSize", defaultValue="10") Integer pageSize, |
| | | HttpServletRequest req) { |
| | | QueryWrapper<InspectionPlanItem> queryWrapper = QueryGenerator.initQueryWrapper(inspectionPlanItem, req.getParameterMap()); |
| | | Page<InspectionPlanItem> page = new Page<InspectionPlanItem>(pageNo, pageSize); |
| | | IPage<InspectionPlanItem> pageList = inspectionPlanItemService.page(page, queryWrapper); |
| | | return Result.OK(pageList); |
| | | } |
| | | |
| | | /** |
| | | * æ·»å |
| | | * |
| | | * @param inspectionPlanItem |
| | | * @return |
| | | */ |
| | | @AutoLog(value = "æ£éªæ¹æ¡æ£éªé¡¹-æ·»å ") |
| | | @ApiOperation(value="æ£éªæ¹æ¡æ£éªé¡¹-æ·»å ", notes="æ£éªæ¹æ¡æ£éªé¡¹-æ·»å ") |
| | | //@RequiresPermissions("org.jeecg.modules:qms_inspection_plan_item:add") |
| | | @PostMapping(value = "/add") |
| | | public Result<String> add(@RequestBody InspectionPlanItem inspectionPlanItem) { |
| | | inspectionPlanItemService.save(inspectionPlanItem); |
| | | return Result.OK("æ·»å æåï¼"); |
| | | } |
| | | |
| | | /** |
| | | * ç¼è¾ |
| | | * |
| | | * @param inspectionPlanItem |
| | | * @return |
| | | */ |
| | | @AutoLog(value = "æ£éªæ¹æ¡æ£éªé¡¹-ç¼è¾") |
| | | @ApiOperation(value="æ£éªæ¹æ¡æ£éªé¡¹-ç¼è¾", notes="æ£éªæ¹æ¡æ£éªé¡¹-ç¼è¾") |
| | | //@RequiresPermissions("org.jeecg.modules:qms_inspection_plan_item:edit") |
| | | @RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST}) |
| | | public Result<String> edit(@RequestBody InspectionPlanItem inspectionPlanItem) { |
| | | inspectionPlanItemService.updateById(inspectionPlanItem); |
| | | return Result.OK("ç¼è¾æå!"); |
| | | } |
| | | |
| | | /** |
| | | * éè¿idå é¤ |
| | | * |
| | | * @param id |
| | | * @return |
| | | */ |
| | | @AutoLog(value = "æ£éªæ¹æ¡æ£éªé¡¹-éè¿idå é¤") |
| | | @ApiOperation(value="æ£éªæ¹æ¡æ£éªé¡¹-éè¿idå é¤", notes="æ£éªæ¹æ¡æ£éªé¡¹-éè¿idå é¤") |
| | | //@RequiresPermissions("org.jeecg.modules:qms_inspection_plan_item:delete") |
| | | @DeleteMapping(value = "/delete") |
| | | public Result<String> delete(@RequestParam(name="id",required=true) String id) { |
| | | inspectionPlanItemService.removeById(id); |
| | | return Result.OK("å 餿å!"); |
| | | } |
| | | |
| | | /** |
| | | * æ¹éå é¤ |
| | | * |
| | | * @param ids |
| | | * @return |
| | | */ |
| | | @AutoLog(value = "æ£éªæ¹æ¡æ£éªé¡¹-æ¹éå é¤") |
| | | @ApiOperation(value="æ£éªæ¹æ¡æ£éªé¡¹-æ¹éå é¤", notes="æ£éªæ¹æ¡æ£éªé¡¹-æ¹éå é¤") |
| | | //@RequiresPermissions("org.jeecg.modules:qms_inspection_plan_item:deleteBatch") |
| | | @DeleteMapping(value = "/deleteBatch") |
| | | public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) { |
| | | this.inspectionPlanItemService.removeByIds(Arrays.asList(ids.split(","))); |
| | | return Result.OK("æ¹éå 餿å!"); |
| | | } |
| | | |
| | | /** |
| | | * éè¿idæ¥è¯¢ |
| | | * |
| | | * @param id |
| | | * @return |
| | | */ |
| | | //@AutoLog(value = "æ£éªæ¹æ¡æ£éªé¡¹-éè¿idæ¥è¯¢") |
| | | @ApiOperation(value="æ£éªæ¹æ¡æ£éªé¡¹-éè¿idæ¥è¯¢", notes="æ£éªæ¹æ¡æ£éªé¡¹-éè¿idæ¥è¯¢") |
| | | @GetMapping(value = "/queryById") |
| | | public Result<InspectionPlanItem> queryById(@RequestParam(name="id",required=true) String id) { |
| | | InspectionPlanItem inspectionPlanItem = inspectionPlanItemService.getById(id); |
| | | if(inspectionPlanItem==null) { |
| | | return Result.error("æªæ¾å°å¯¹åºæ°æ®"); |
| | | } |
| | | return Result.OK(inspectionPlanItem); |
| | | } |
| | | |
| | | /** |
| | | * 导åºexcel |
| | | * |
| | | * @param request |
| | | * @param inspectionPlanItem |
| | | */ |
| | | //@RequiresPermissions("org.jeecg.modules:qms_inspection_plan_item:exportXls") |
| | | @RequestMapping(value = "/exportXls") |
| | | public ModelAndView exportXls(HttpServletRequest request, InspectionPlanItem inspectionPlanItem) { |
| | | return super.exportXls(request, inspectionPlanItem, InspectionPlanItem.class, "æ£éªæ¹æ¡æ£éªé¡¹"); |
| | | } |
| | | |
| | | /** |
| | | * éè¿excel导å
¥æ°æ® |
| | | * |
| | | * @param request |
| | | * @param response |
| | | * @return |
| | | */ |
| | | //@RequiresPermissions("qms_inspection_plan_item:importExcel") |
| | | @RequestMapping(value = "/importExcel", method = RequestMethod.POST) |
| | | public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) { |
| | | return super.importExcel(request, response, InspectionPlanItem.class); |
| | | } |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package org.jeecg.modules.qms.controller; |
| | | |
| | | import java.util.Arrays; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | import java.util.stream.Collectors; |
| | | import java.io.IOException; |
| | | import java.io.UnsupportedEncodingException; |
| | | import java.net.URLDecoder; |
| | | import javax.servlet.http.HttpServletRequest; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import org.jeecg.common.api.vo.Result; |
| | | import org.jeecg.common.constant.CommonConstant; |
| | | import org.jeecg.common.system.query.QueryGenerator; |
| | | import org.jeecg.common.util.oConvertUtils; |
| | | import org.jeecg.modules.qms.entity.InspectionItem; |
| | | import org.jeecg.modules.qms.entity.SamplingRules; |
| | | import org.jeecg.modules.qms.service.ISamplingRulesService; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | |
| | | import org.jeecgframework.poi.excel.ExcelImportUtil; |
| | | import org.jeecgframework.poi.excel.def.NormalExcelConstants; |
| | | import org.jeecgframework.poi.excel.entity.ExportParams; |
| | | import org.jeecgframework.poi.excel.entity.ImportParams; |
| | | import org.jeecgframework.poi.excel.view.JeecgEntityExcelView; |
| | | import org.jeecg.common.system.base.controller.JeecgController; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | import org.springframework.web.multipart.MultipartHttpServletRequest; |
| | | import org.springframework.web.servlet.ModelAndView; |
| | | import com.alibaba.fastjson.JSON; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.jeecg.common.aspect.annotation.AutoLog; |
| | | |
| | | /** |
| | | * @Description: æ½æ ·è§å |
| | | * @Author: jeecg-boot |
| | | * @Date: 2025-07-02 |
| | | * @Version: V1.0 |
| | | */ |
| | | @Api(tags="æ½æ ·è§å") |
| | | @RestController |
| | | @RequestMapping("/qms/samplingRules") |
| | | @Slf4j |
| | | public class SamplingRulesController extends JeecgController<SamplingRules, ISamplingRulesService> { |
| | | @Autowired |
| | | private ISamplingRulesService samplingRulesService; |
| | | |
| | | /** |
| | | * å页å表æ¥è¯¢ |
| | | * |
| | | * @param samplingRules |
| | | * @param pageNo |
| | | * @param pageSize |
| | | * @param req |
| | | * @return |
| | | */ |
| | | //@AutoLog(value = "æ½æ ·è§å-å页å表æ¥è¯¢") |
| | | @ApiOperation(value="æ½æ ·è§å-å页å表æ¥è¯¢", notes="æ½æ ·è§å-å页å表æ¥è¯¢") |
| | | @GetMapping(value = "/list") |
| | | public Result<IPage<SamplingRules>> queryPageList(SamplingRules samplingRules, |
| | | @RequestParam(name="pageNo", defaultValue="1") Integer pageNo, |
| | | @RequestParam(name="pageSize", defaultValue="10") Integer pageSize, |
| | | HttpServletRequest req) { |
| | | QueryWrapper<SamplingRules> queryWrapper = QueryGenerator.initQueryWrapper(samplingRules, req.getParameterMap()); |
| | | Page<SamplingRules> page = new Page<SamplingRules>(pageNo, pageSize); |
| | | IPage<SamplingRules> pageList = samplingRulesService.page(page, queryWrapper); |
| | | return Result.OK(pageList); |
| | | } |
| | | |
| | | /** |
| | | * æ·»å |
| | | * |
| | | * @param samplingRules |
| | | * @return |
| | | */ |
| | | @AutoLog(value = "æ½æ ·è§å-æ·»å ") |
| | | @ApiOperation(value="æ½æ ·è§å-æ·»å ", notes="æ½æ ·è§å-æ·»å ") |
| | | //@RequiresPermissions("org.jeecg.modules:qms_sampling_rules:add") |
| | | @PostMapping(value = "/add") |
| | | public Result<String> add(@RequestBody SamplingRules samplingRules) { |
| | | samplingRules.setRuleStatus(CommonConstant.STATUS_1); |
| | | samplingRulesService.save(samplingRules); |
| | | return Result.OK("æ·»å æåï¼"); |
| | | } |
| | | |
| | | /** |
| | | * ç¼è¾ |
| | | * |
| | | * @param samplingRules |
| | | * @return |
| | | */ |
| | | @AutoLog(value = "æ½æ ·è§å-ç¼è¾") |
| | | @ApiOperation(value="æ½æ ·è§å-ç¼è¾", notes="æ½æ ·è§å-ç¼è¾") |
| | | //@RequiresPermissions("org.jeecg.modules:qms_sampling_rules:edit") |
| | | @RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST}) |
| | | public Result<String> edit(@RequestBody SamplingRules samplingRules) { |
| | | samplingRulesService.updateById(samplingRules); |
| | | return Result.OK("ç¼è¾æå!"); |
| | | } |
| | | |
| | | /** |
| | | * éè¿idå é¤ |
| | | * |
| | | * @param id |
| | | * @return |
| | | */ |
| | | @AutoLog(value = "æ½æ ·è§å-éè¿idå é¤") |
| | | @ApiOperation(value="æ½æ ·è§å-éè¿idå é¤", notes="æ½æ ·è§å-éè¿idå é¤") |
| | | //@RequiresPermissions("org.jeecg.modules:qms_sampling_rules:delete") |
| | | @DeleteMapping(value = "/delete") |
| | | public Result<String> delete(@RequestParam(name="id",required=true) String id) { |
| | | samplingRulesService.removeById(id); |
| | | return Result.OK("å 餿å!"); |
| | | } |
| | | |
| | | /** |
| | | * æ¹éå é¤ |
| | | * |
| | | * @param ids |
| | | * @return |
| | | */ |
| | | @AutoLog(value = "æ½æ ·è§å-æ¹éå é¤") |
| | | @ApiOperation(value="æ½æ ·è§å-æ¹éå é¤", notes="æ½æ ·è§å-æ¹éå é¤") |
| | | //@RequiresPermissions("org.jeecg.modules:qms_sampling_rules:deleteBatch") |
| | | @DeleteMapping(value = "/deleteBatch") |
| | | public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) { |
| | | this.samplingRulesService.removeByIds(Arrays.asList(ids.split(","))); |
| | | return Result.OK("æ¹éå 餿å!"); |
| | | } |
| | | |
| | | /** |
| | | * éè¿idæ¥è¯¢ |
| | | * |
| | | * @param id |
| | | * @return |
| | | */ |
| | | //@AutoLog(value = "æ½æ ·è§å-éè¿idæ¥è¯¢") |
| | | @ApiOperation(value="æ½æ ·è§å-éè¿idæ¥è¯¢", notes="æ½æ ·è§å-éè¿idæ¥è¯¢") |
| | | @GetMapping(value = "/queryById") |
| | | public Result<SamplingRules> queryById(@RequestParam(name="id",required=true) String id) { |
| | | SamplingRules samplingRules = samplingRulesService.getById(id); |
| | | if(samplingRules==null) { |
| | | return Result.error("æªæ¾å°å¯¹åºæ°æ®"); |
| | | } |
| | | return Result.OK(samplingRules); |
| | | } |
| | | |
| | | /** |
| | | * 导åºexcel |
| | | * |
| | | * @param request |
| | | * @param samplingRules |
| | | */ |
| | | //@RequiresPermissions("org.jeecg.modules:qms_sampling_rules:exportXls") |
| | | @RequestMapping(value = "/exportXls") |
| | | public ModelAndView exportXls(HttpServletRequest request, SamplingRules samplingRules) { |
| | | return super.exportXls(request, samplingRules, SamplingRules.class, "æ½æ ·è§å"); |
| | | } |
| | | |
| | | /** |
| | | * éè¿excel导å
¥æ°æ® |
| | | * |
| | | * @param request |
| | | * @param response |
| | | * @return |
| | | */ |
| | | //@RequiresPermissions("qms_sampling_rules:importExcel") |
| | | @RequestMapping(value = "/importExcel", method = RequestMethod.POST) |
| | | public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) { |
| | | return super.importExcel(request, response, SamplingRules.class); |
| | | } |
| | | |
| | | @AutoLog(value = "æ½æ ·è§å-å¯ç¨&ç¦ç¨") |
| | | @ApiOperation(value = "æ½æ ·è§å-å¯ç¨&ç¦ç¨", notes = "æ½æ ·è§å-å¯ç¨&ç¦ç¨") |
| | | @PutMapping(value = "/active") |
| | | public Result<?> active(@RequestParam(name = "id", required = true) String id) { |
| | | SamplingRules samplingRules = samplingRulesService.getById(id); |
| | | if (CommonConstant.STATUS_1.equals(samplingRules.getRuleStatus())) { |
| | | samplingRules.setRuleStatus(CommonConstant.STATUS_0); |
| | | } else { |
| | | samplingRules.setRuleStatus(CommonConstant.STATUS_1); |
| | | } |
| | | samplingRulesService.updateById(samplingRules); |
| | | return Result.ok("æä½æåï¼"); |
| | | } |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package org.jeecg.modules.qms.entity; |
| | | |
| | | import java.io.Serializable; |
| | | import java.io.UnsupportedEncodingException; |
| | | import java.util.Date; |
| | | import java.math.BigDecimal; |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import com.baomidou.mybatisplus.annotation.TableLogic; |
| | | import lombok.Data; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import org.jeecg.common.constant.CommonConstant; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | import org.jeecgframework.poi.excel.annotation.Excel; |
| | | import org.jeecg.common.aspect.annotation.Dict; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.EqualsAndHashCode; |
| | | import lombok.experimental.Accessors; |
| | | |
| | | /** |
| | | * @Description: 缺é·ç»´æ¤ |
| | | * @Author: jeecg-boot |
| | | * @Date: 2025-07-02 |
| | | * @Version: V1.0 |
| | | */ |
| | | @Data |
| | | @TableName("qms_defect") |
| | | @Accessors(chain = true) |
| | | @EqualsAndHashCode(callSuper = false) |
| | | @ApiModel(value="qms_defect对象", description="缺é·ç»´æ¤") |
| | | public class Defect implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /**主é®*/ |
| | | @TableId(type = IdType.ASSIGN_ID) |
| | | @ApiModelProperty(value = "主é®") |
| | | private String id; |
| | | /**å建人*/ |
| | | @ApiModelProperty(value = "å建人") |
| | | private String createBy; |
| | | /**å建æ¶é´*/ |
| | | @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd") |
| | | @DateTimeFormat(pattern="yyyy-MM-dd") |
| | | @ApiModelProperty(value = "å建æ¶é´") |
| | | private Date createTime; |
| | | /**æ´æ°äºº*/ |
| | | @ApiModelProperty(value = "æ´æ°äºº") |
| | | private String updateBy; |
| | | /**æ´æ°æ¶é´*/ |
| | | @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd") |
| | | @DateTimeFormat(pattern="yyyy-MM-dd") |
| | | @ApiModelProperty(value = "æ´æ°æ¶é´") |
| | | private Date updateTime; |
| | | /**å 餿 è®°*/ |
| | | @Excel(name = "å 餿 è®°", width = 15) |
| | | @ApiModelProperty(value = "å 餿 è®°") |
| | | @TableLogic |
| | | private Integer delFlag = CommonConstant.DEL_FLAG_0; |
| | | /**缺é·ç¼ç */ |
| | | @Excel(name = "缺é·ç¼ç ", width = 15) |
| | | @ApiModelProperty(value = "缺é·ç¼ç ") |
| | | private String defectCode; |
| | | /**缺é·åç§°*/ |
| | | @Excel(name = "缺é·åç§°", width = 15) |
| | | @ApiModelProperty(value = "缺é·åç§°") |
| | | private String defectName; |
| | | /**缺é·åç±»*/ |
| | | @Excel(name = "缺é·åç±»", width = 15) |
| | | @ApiModelProperty(value = "缺é·åç±»") |
| | | @Dict(dicCode = "defect_category") |
| | | private String defectCategory; |
| | | /**缺é·ç¶æ*/ |
| | | @Excel(name = "缺é·ç¶æ", width = 15) |
| | | @ApiModelProperty(value = "缺é·ç¶æ") |
| | | private String defectStatus; |
| | | /**ç¼ºé·æè¿°*/ |
| | | @Excel(name = "ç¼ºé·æè¿°", width = 15) |
| | | @ApiModelProperty(value = "ç¼ºé·æè¿°") |
| | | private String descreption; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package org.jeecg.modules.qms.entity; |
| | | |
| | | import java.io.Serializable; |
| | | import java.io.UnsupportedEncodingException; |
| | | import java.util.Date; |
| | | import java.math.BigDecimal; |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import com.baomidou.mybatisplus.annotation.TableLogic; |
| | | import lombok.Data; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import org.jeecg.common.constant.CommonConstant; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | import org.jeecgframework.poi.excel.annotation.Excel; |
| | | import org.jeecg.common.aspect.annotation.Dict; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.EqualsAndHashCode; |
| | | import lombok.experimental.Accessors; |
| | | |
| | | /** |
| | | * @Description: æ£éªæ¹æ¡ |
| | | * @Author: jeecg-boot |
| | | * @Date: 2025-07-02 |
| | | * @Version: V1.0 |
| | | */ |
| | | @Data |
| | | @TableName("qms_inspection_plan") |
| | | @Accessors(chain = true) |
| | | @EqualsAndHashCode(callSuper = false) |
| | | @ApiModel(value="qms_inspection_plan对象", description="æ£éªæ¹æ¡") |
| | | public class InspectionPlan implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /**主é®*/ |
| | | @TableId(type = IdType.ASSIGN_ID) |
| | | @ApiModelProperty(value = "主é®") |
| | | private String id; |
| | | /**å建人*/ |
| | | @ApiModelProperty(value = "å建人") |
| | | private String createBy; |
| | | /**å建æ¶é´*/ |
| | | @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd") |
| | | @DateTimeFormat(pattern="yyyy-MM-dd") |
| | | @ApiModelProperty(value = "å建æ¶é´") |
| | | private Date createTime; |
| | | /**æ´æ°äºº*/ |
| | | @ApiModelProperty(value = "æ´æ°äºº") |
| | | private String updateBy; |
| | | /**æ´æ°æ¶é´*/ |
| | | @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd") |
| | | @DateTimeFormat(pattern="yyyy-MM-dd") |
| | | @ApiModelProperty(value = "æ´æ°æ¶é´") |
| | | private Date updateTime; |
| | | /**å 餿 è®°*/ |
| | | @Excel(name = "å 餿 è®°", width = 15) |
| | | @ApiModelProperty(value = "å 餿 è®°") |
| | | @TableLogic |
| | | private Integer delFlag = CommonConstant.DEL_FLAG_0; |
| | | /**æ¹æ¡ç¼ç */ |
| | | @Excel(name = "æ¹æ¡ç¼ç ", width = 15) |
| | | @ApiModelProperty(value = "æ¹æ¡ç¼ç ") |
| | | private String planCode; |
| | | /**æ¹æ¡åç§°*/ |
| | | @Excel(name = "æ¹æ¡åç§°", width = 15) |
| | | @ApiModelProperty(value = "æ¹æ¡åç§°") |
| | | private String planName; |
| | | /**ç©æç¼ç */ |
| | | @Excel(name = "ç©æç¼ç ", width = 15) |
| | | @ApiModelProperty(value = "ç©æç¼ç ") |
| | | private String materialNumber; |
| | | /**ç©æåç§°*/ |
| | | @Excel(name = "ç©æåç§°", width = 15) |
| | | @ApiModelProperty(value = "ç©æåç§°") |
| | | private String materialName; |
| | | /**æ¹æ¡ç¶æ*/ |
| | | @Excel(name = "æ¹æ¡ç¶æ", width = 15) |
| | | @ApiModelProperty(value = "æ¹æ¡ç¶æ") |
| | | private String planStatus; |
| | | /**æ¹æ¡åç±»;馿£ãå·¡æ£ãå®å·¥æ£*/ |
| | | @Excel(name = "æ¹æ¡åç±»;馿£ãå·¡æ£ãå®å·¥æ£", width = 15) |
| | | @ApiModelProperty(value = "æ¹æ¡åç±»;馿£ãå·¡æ£ãå®å·¥æ£") |
| | | @Dict(dicCode = "plan_category") |
| | | private String planCategory; |
| | | /**æ½æ ·è§åID*/ |
| | | @Excel(name = "æ½æ ·è§åID", width = 15) |
| | | @ApiModelProperty(value = "æ½æ ·è§åID") |
| | | private String ruleId; |
| | | /**æ¹æ¡æè¿°*/ |
| | | @Excel(name = "æ¹æ¡æè¿°", width = 15) |
| | | @ApiModelProperty(value = "æ¹æ¡æè¿°") |
| | | private String descreption; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package org.jeecg.modules.qms.entity; |
| | | |
| | | import java.io.Serializable; |
| | | import java.io.UnsupportedEncodingException; |
| | | import java.util.Date; |
| | | import java.math.BigDecimal; |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import com.baomidou.mybatisplus.annotation.TableLogic; |
| | | import lombok.Data; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | import org.jeecgframework.poi.excel.annotation.Excel; |
| | | import org.jeecg.common.aspect.annotation.Dict; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.EqualsAndHashCode; |
| | | import lombok.experimental.Accessors; |
| | | |
| | | /** |
| | | * @Description: æ£éªæ¹æ¡æ£éªé¡¹ |
| | | * @Author: jeecg-boot |
| | | * @Date: 2025-07-02 |
| | | * @Version: V1.0 |
| | | */ |
| | | @Data |
| | | @TableName("qms_inspection_plan_item") |
| | | @Accessors(chain = true) |
| | | @EqualsAndHashCode(callSuper = false) |
| | | @ApiModel(value="qms_inspection_plan_item对象", description="æ£éªæ¹æ¡æ£éªé¡¹") |
| | | public class InspectionPlanItem implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /**主é®*/ |
| | | @TableId(type = IdType.ASSIGN_ID) |
| | | @ApiModelProperty(value = "主é®") |
| | | private String id; |
| | | /**å建人*/ |
| | | @ApiModelProperty(value = "å建人") |
| | | private String createBy; |
| | | /**å建æ¶é´*/ |
| | | @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd") |
| | | @DateTimeFormat(pattern="yyyy-MM-dd") |
| | | @ApiModelProperty(value = "å建æ¶é´") |
| | | private Date createTime; |
| | | /**æ¹æ¡ID*/ |
| | | @Excel(name = "æ¹æ¡ID", width = 15) |
| | | @ApiModelProperty(value = "æ¹æ¡ID") |
| | | private String planId; |
| | | /**æ£éªé¡¹ID*/ |
| | | @Excel(name = "æ£éªé¡¹ID", width = 15) |
| | | @ApiModelProperty(value = "æ£éªé¡¹ID") |
| | | private String itemId; |
| | | /**æåº*/ |
| | | @Excel(name = "æåº", width = 15) |
| | | @ApiModelProperty(value = "æåº") |
| | | private Integer sorter; |
| | | /**æ åå¼*/ |
| | | @Excel(name = "æ åå¼", width = 15) |
| | | @ApiModelProperty(value = "æ åå¼") |
| | | private BigDecimal standardValue; |
| | | /**ä¸å
¬å·®(æå¤§å¼)*/ |
| | | @Excel(name = "ä¸å
¬å·®(æå¤§å¼)", width = 15) |
| | | @ApiModelProperty(value = "ä¸å
¬å·®(æå¤§å¼)") |
| | | private BigDecimal maxValue; |
| | | /**ä¸å
¬å·®(æå°å¼)*/ |
| | | @Excel(name = "ä¸å
¬å·®(æå°å¼)", width = 15) |
| | | @ApiModelProperty(value = "ä¸å
¬å·®(æå°å¼)") |
| | | private BigDecimal minValue; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package org.jeecg.modules.qms.entity; |
| | | |
| | | import java.io.Serializable; |
| | | import java.io.UnsupportedEncodingException; |
| | | import java.util.Date; |
| | | import java.math.BigDecimal; |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import com.baomidou.mybatisplus.annotation.TableLogic; |
| | | import lombok.Data; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import org.jeecg.common.constant.CommonConstant; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | import org.jeecgframework.poi.excel.annotation.Excel; |
| | | import org.jeecg.common.aspect.annotation.Dict; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.EqualsAndHashCode; |
| | | import lombok.experimental.Accessors; |
| | | |
| | | /** |
| | | * @Description: æ½æ ·è§å |
| | | * @Author: jeecg-boot |
| | | * @Date: 2025-07-02 |
| | | * @Version: V1.0 |
| | | */ |
| | | @Data |
| | | @TableName("qms_sampling_rules") |
| | | @Accessors(chain = true) |
| | | @EqualsAndHashCode(callSuper = false) |
| | | @ApiModel(value="qms_sampling_rules对象", description="æ½æ ·è§å") |
| | | public class SamplingRules implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /**主é®*/ |
| | | @TableId(type = IdType.ASSIGN_ID) |
| | | @ApiModelProperty(value = "主é®") |
| | | private String id; |
| | | /**å建人*/ |
| | | @ApiModelProperty(value = "å建人") |
| | | private String createBy; |
| | | /**å建æ¶é´*/ |
| | | @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd") |
| | | @DateTimeFormat(pattern="yyyy-MM-dd") |
| | | @ApiModelProperty(value = "å建æ¶é´") |
| | | private Date createTime; |
| | | /**æ´æ°äºº*/ |
| | | @ApiModelProperty(value = "æ´æ°äºº") |
| | | private String updateBy; |
| | | /**æ´æ°æ¶é´*/ |
| | | @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd") |
| | | @DateTimeFormat(pattern="yyyy-MM-dd") |
| | | @ApiModelProperty(value = "æ´æ°æ¶é´") |
| | | private Date updateTime; |
| | | /**å 餿 è®°*/ |
| | | @Excel(name = "å 餿 è®°", width = 15) |
| | | @ApiModelProperty(value = "å 餿 è®°") |
| | | @TableLogic |
| | | private Integer delFlag = CommonConstant.DEL_FLAG_0; |
| | | /**è§åç¼ç */ |
| | | @Excel(name = "è§åç¼ç ", width = 15) |
| | | @ApiModelProperty(value = "è§åç¼ç ") |
| | | private String ruleCode; |
| | | /**è§ååç§°*/ |
| | | @Excel(name = "è§ååç§°", width = 15) |
| | | @ApiModelProperty(value = "è§ååç§°") |
| | | private String ruleName; |
| | | /**æ½æ ·åç±»*/ |
| | | @Excel(name = "æ½æ ·åç±»", width = 15) |
| | | @ApiModelProperty(value = "æ½æ ·åç±»") |
| | | @Dict(dicCode = "rule_category") |
| | | private String ruleCategory; |
| | | /**è§åç¶æ*/ |
| | | @Excel(name = "è§åç¶æ", width = 15) |
| | | @ApiModelProperty(value = "è§åç¶æ") |
| | | private String ruleStatus; |
| | | /**æå¤§ä¸åæ ¼æ°*/ |
| | | @Excel(name = "æå¤§ä¸åæ ¼æ°", width = 15) |
| | | @ApiModelProperty(value = "æå¤§ä¸åæ ¼æ°") |
| | | private BigDecimal maxUnqualifiedQuantity; |
| | | /**æ½æ ·æ°é*/ |
| | | @Excel(name = "æ½æ ·æ°é", width = 15) |
| | | @ApiModelProperty(value = "æ½æ ·æ°é") |
| | | private BigDecimal samplingQuantity; |
| | | /**æ¹éä¸éå¼*/ |
| | | @Excel(name = "æ¹éä¸éå¼", width = 15) |
| | | @ApiModelProperty(value = "æ¹éä¸éå¼") |
| | | private BigDecimal batchLowerLimit; |
| | | /**æ¹éä¸éå¼*/ |
| | | @Excel(name = "æ¹éä¸éå¼", width = 15) |
| | | @ApiModelProperty(value = "æ¹éä¸éå¼") |
| | | private BigDecimal batchUpperLimit; |
| | | /**夿³¨*/ |
| | | @Excel(name = "夿³¨", width = 15) |
| | | @ApiModelProperty(value = "夿³¨") |
| | | private String remark; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package org.jeecg.modules.qms.mapper; |
| | | |
| | | import java.util.List; |
| | | |
| | | import org.apache.ibatis.annotations.Param; |
| | | import org.jeecg.modules.qms.entity.Defect; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | |
| | | /** |
| | | * @Description: 缺é·ç»´æ¤ |
| | | * @Author: jeecg-boot |
| | | * @Date: 2025-07-02 |
| | | * @Version: V1.0 |
| | | */ |
| | | public interface DefectMapper extends BaseMapper<Defect> { |
| | | |
| | | } |
| | |
| | | package org.jeecg.modules.qms.mapper; |
| | | |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.Wrapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.core.toolkit.Constants; |
| | | import org.apache.ibatis.annotations.Param; |
| | | import org.jeecg.modules.qms.entity.InspectionItem; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | |
| | | */ |
| | | public interface InspectionItemMapper extends BaseMapper<InspectionItem> { |
| | | |
| | | public IPage<Map<String, Object>> queryList(IPage<Map> pageData, @Param(Constants.WRAPPER) Wrapper<Map> wrapper); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package org.jeecg.modules.qms.mapper; |
| | | |
| | | import java.util.List; |
| | | |
| | | import org.apache.ibatis.annotations.Param; |
| | | import org.jeecg.modules.qms.entity.InspectionPlanItem; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | |
| | | /** |
| | | * @Description: æ£éªæ¹æ¡æ£éªé¡¹ |
| | | * @Author: jeecg-boot |
| | | * @Date: 2025-07-02 |
| | | * @Version: V1.0 |
| | | */ |
| | | public interface InspectionPlanItemMapper extends BaseMapper<InspectionPlanItem> { |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package org.jeecg.modules.qms.mapper; |
| | | |
| | | import java.util.List; |
| | | |
| | | import org.apache.ibatis.annotations.Param; |
| | | import org.jeecg.modules.qms.entity.InspectionPlan; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | |
| | | /** |
| | | * @Description: æ£éªæ¹æ¡ |
| | | * @Author: jeecg-boot |
| | | * @Date: 2025-07-02 |
| | | * @Version: V1.0 |
| | | */ |
| | | public interface InspectionPlanMapper extends BaseMapper<InspectionPlan> { |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package org.jeecg.modules.qms.mapper; |
| | | |
| | | import java.util.List; |
| | | |
| | | import org.apache.ibatis.annotations.Param; |
| | | import org.jeecg.modules.qms.entity.SamplingRules; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | |
| | | /** |
| | | * @Description: æ½æ ·è§å |
| | | * @Author: jeecg-boot |
| | | * @Date: 2025-07-02 |
| | | * @Version: V1.0 |
| | | */ |
| | | public interface SamplingRulesMapper extends BaseMapper<SamplingRules> { |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="org.jeecg.modules.qms.mapper.DefectMapper"> |
| | | |
| | | </mapper> |
| | |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="org.jeecg.modules.qms.mapper.InspectionItemMapper"> |
| | | |
| | | |
| | | <select id="queryList" resultType="map" parameterType="String"> |
| | | SELECT |
| | | t1.id, |
| | | t1.item_code itemCode, |
| | | t1.item_name itemName, |
| | | t1.item_category itemCategory, |
| | | t1.qualitative_or_quantitative qualitativeOrQuantitative, |
| | | t1.inspection_tools inspectionTools, |
| | | t1.item_status itemStatus, |
| | | t1.create_time createTime, |
| | | t2.item_text itemCategoryName, |
| | | t3.item_text qualitativeOrQuantitativeName, |
| | | t1.remark |
| | | FROM |
| | | qms_inspection_item t1 |
| | | LEFT JOIN ( SELECT * FROM v_sys_dict WHERE dict_code = 'item_category' ) t2 ON t2.item_value = t1.item_category |
| | | left join ( SELECT * FROM v_sys_dict WHERE dict_code = 'qualitative_or_quantitative' ) t3 on t3.item_value = t1.qualitative_or_quantitative |
| | | ${ew.customSqlSegment} |
| | | </select> |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="org.jeecg.modules.qms.mapper.InspectionPlanItemMapper"> |
| | | |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="org.jeecg.modules.qms.mapper.InspectionPlanMapper"> |
| | | |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="org.jeecg.modules.qms.mapper.SamplingRulesMapper"> |
| | | |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package org.jeecg.modules.qms.service; |
| | | |
| | | import org.jeecg.modules.qms.entity.Defect; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | |
| | | /** |
| | | * @Description: 缺é·ç»´æ¤ |
| | | * @Author: jeecg-boot |
| | | * @Date: 2025-07-02 |
| | | * @Version: V1.0 |
| | | */ |
| | | public interface IDefectService extends IService<Defect> { |
| | | |
| | | } |
| | |
| | | package org.jeecg.modules.qms.service; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import org.jeecg.modules.qms.entity.InspectionItem; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * @Description: æ£éªé¡¹ç® |
| | |
| | | */ |
| | | public interface IInspectionItemService extends IService<InspectionItem> { |
| | | |
| | | IPage<Map<String, Object>> queryList(Integer pageNo, Integer pageSize, Map<String, String> query); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package org.jeecg.modules.qms.service; |
| | | |
| | | import org.jeecg.modules.qms.entity.InspectionPlanItem; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | |
| | | /** |
| | | * @Description: æ£éªæ¹æ¡æ£éªé¡¹ |
| | | * @Author: jeecg-boot |
| | | * @Date: 2025-07-02 |
| | | * @Version: V1.0 |
| | | */ |
| | | public interface IInspectionPlanItemService extends IService<InspectionPlanItem> { |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package org.jeecg.modules.qms.service; |
| | | |
| | | import org.jeecg.modules.qms.entity.InspectionPlan; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | |
| | | /** |
| | | * @Description: æ£éªæ¹æ¡ |
| | | * @Author: jeecg-boot |
| | | * @Date: 2025-07-02 |
| | | * @Version: V1.0 |
| | | */ |
| | | public interface IInspectionPlanService extends IService<InspectionPlan> { |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package org.jeecg.modules.qms.service; |
| | | |
| | | import org.jeecg.modules.qms.entity.SamplingRules; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | |
| | | /** |
| | | * @Description: æ½æ ·è§å |
| | | * @Author: jeecg-boot |
| | | * @Date: 2025-07-02 |
| | | * @Version: V1.0 |
| | | */ |
| | | public interface ISamplingRulesService extends IService<SamplingRules> { |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package org.jeecg.modules.qms.service.impl; |
| | | |
| | | import org.jeecg.modules.qms.entity.Defect; |
| | | import org.jeecg.modules.qms.mapper.DefectMapper; |
| | | import org.jeecg.modules.qms.service.IDefectService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | |
| | | /** |
| | | * @Description: 缺é·ç»´æ¤ |
| | | * @Author: jeecg-boot |
| | | * @Date: 2025-07-02 |
| | | * @Version: V1.0 |
| | | */ |
| | | @Service |
| | | public class DefectServiceImpl extends ServiceImpl<DefectMapper, Defect> implements IDefectService { |
| | | |
| | | } |
| | |
| | | package org.jeecg.modules.qms.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.core.metadata.OrderItem; |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import org.apache.commons.lang.StringUtils; |
| | | import org.jeecg.common.exception.ExceptionCast; |
| | | import org.jeecg.modules.qms.entity.InspectionItem; |
| | | import org.jeecg.modules.qms.mapper.InspectionItemMapper; |
| | | import org.jeecg.modules.qms.service.IInspectionItemService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * @Description: æ£éªé¡¹ç® |
| | |
| | | @Service |
| | | public class InspectionItemServiceImpl extends ServiceImpl<InspectionItemMapper, InspectionItem> implements IInspectionItemService { |
| | | |
| | | @Override |
| | | public IPage<Map<String, Object>> queryList(Integer pageNo, Integer pageSize, Map<String, String> query) { |
| | | if (pageNo == null || pageNo < 1 || pageSize == null || pageSize < 1) { |
| | | ExceptionCast.cast("åæ°é误"); |
| | | } |
| | | IPage<Map> pageData = new Page<Map>(pageNo, pageSize); |
| | | QueryWrapper<Map> queryWrapper = Wrappers.query(); |
| | | if (null != query) { |
| | | String itemCode = query.get("itemCode"); |
| | | if (StringUtils.isNotBlank(itemCode)) { |
| | | queryWrapper.like("t1.item_code", itemCode); |
| | | } |
| | | String itemName = query.get("itemName"); |
| | | if (StringUtils.isNotBlank(itemName)) { |
| | | queryWrapper.like("t2.item_name", itemName); |
| | | } |
| | | |
| | | // æåºåæ³ |
| | | List<OrderItem> orderItems = new ArrayList<>(); |
| | | orderItems.add(OrderItem.desc("t1.create_time")); |
| | | ((Page<Map>) pageData).setOrders(orderItems); |
| | | } |
| | | return super.getBaseMapper().queryList(pageData,queryWrapper); |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package org.jeecg.modules.qms.service.impl; |
| | | |
| | | import org.jeecg.modules.qms.entity.InspectionPlanItem; |
| | | import org.jeecg.modules.qms.mapper.InspectionPlanItemMapper; |
| | | import org.jeecg.modules.qms.service.IInspectionPlanItemService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | |
| | | /** |
| | | * @Description: æ£éªæ¹æ¡æ£éªé¡¹ |
| | | * @Author: jeecg-boot |
| | | * @Date: 2025-07-02 |
| | | * @Version: V1.0 |
| | | */ |
| | | @Service |
| | | public class InspectionPlanItemServiceImpl extends ServiceImpl<InspectionPlanItemMapper, InspectionPlanItem> implements IInspectionPlanItemService { |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package org.jeecg.modules.qms.service.impl; |
| | | |
| | | import org.jeecg.modules.qms.entity.InspectionPlan; |
| | | import org.jeecg.modules.qms.mapper.InspectionPlanMapper; |
| | | import org.jeecg.modules.qms.service.IInspectionPlanService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | |
| | | /** |
| | | * @Description: æ£éªæ¹æ¡ |
| | | * @Author: jeecg-boot |
| | | * @Date: 2025-07-02 |
| | | * @Version: V1.0 |
| | | */ |
| | | @Service |
| | | public class InspectionPlanServiceImpl extends ServiceImpl<InspectionPlanMapper, InspectionPlan> implements IInspectionPlanService { |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package org.jeecg.modules.qms.service.impl; |
| | | |
| | | import org.jeecg.modules.qms.entity.SamplingRules; |
| | | import org.jeecg.modules.qms.mapper.SamplingRulesMapper; |
| | | import org.jeecg.modules.qms.service.ISamplingRulesService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | |
| | | /** |
| | | * @Description: æ½æ ·è§å |
| | | * @Author: jeecg-boot |
| | | * @Date: 2025-07-02 |
| | | * @Version: V1.0 |
| | | */ |
| | | @Service |
| | | public class SamplingRulesServiceImpl extends ServiceImpl<SamplingRulesMapper, SamplingRules> implements ISamplingRulesService { |
| | | |
| | | } |