工具管理-修改DNC刀具查询接口,满足多参数查询需求
| | |
| | | import org.jeecg.common.api.vo.Result; |
| | | import org.jeecg.common.constant.CommonConstant; |
| | | import org.jeecg.modules.tms.entity.ToolsClassify; |
| | | import org.jeecg.modules.tms.entity.dto.ToolQueryParamDto; |
| | | import org.jeecg.modules.tms.entity.vo.ParaHolesToolsVo; |
| | | import org.jeecg.modules.tms.entity.vo.ParaMillToolVo; |
| | | import org.jeecg.modules.tms.entity.vo.ParaTurningToolsVo; |
| | |
| | | |
| | | /** |
| | | * éè¿å·¥å
·ç®ç§°/ç´å¾åæ°æ¥è¯¢å
·ä½å·¥å
·åæ°ä¿¡æ¯(ç»DNCæä¾æ¥å£)ï¼åæ°ç¤ºä¾ï¼3Eï¼3为工å
·ç´å¾åæ°ãE为å å·¥ä¸å¿åå
·ç®ç§°ï¼ |
| | | * @param param |
| | | * @param queryParam |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "éè¿å·¥å
·ç®ç§°/ç´å¾åæ°æ¥è¯¢å
·ä½å·¥å
·åæ°ä¿¡æ¯(ç»DNCæä¾æ¥å£)", notes = "éè¿å·¥å
·ç®ç§°/ç´å¾åæ°æ¥è¯¢å
·ä½å·¥å
·åæ°ä¿¡æ¯(ç»DNCæä¾æ¥å£)") |
| | | @GetMapping("/queryToolByParam") |
| | | public Result<?> queryToolByParam(@RequestParam("param") String param){ |
| | | public Result<?> queryToolByParam(@RequestParam("param") ToolQueryParamDto queryParam){ |
| | | String param = queryParam.getParam(); |
| | | // æ£å表达å¼ï¼ååé¨å为æ°åï¼æ¯æå°æ°ï¼ï¼ååé¨å为大åæå°å忝 |
| | | String regex = "^([\\d.]+)([A-Za-z]+)$"; |
| | | Pattern pattern = Pattern.compile(regex); |
| | |
| | | List<Object> toolList = CollectionUtil.newArrayList(); |
| | | for (ToolsClassify classify : classifyList) { |
| | | String paraTypeFlag = classify.getParaTypeFlag(); |
| | | queryParam.setClassifyId(classify.getId()); |
| | | queryParam.setDiameter(diameter); |
| | | ToolParaType toolParaType = ToolParaType.fromValue(paraTypeFlag); |
| | | if (toolParaType != null) { |
| | | switch (toolParaType) { |
| | | case HOLE: |
| | | List<ParaHolesToolsVo> paraHoleToolsList = paraHoleToolsService.selectByClassifyAndDiameter(classify.getId(), diameter); |
| | | List<ParaHolesToolsVo> paraHoleToolsList = paraHoleToolsService.selectByClassifyAndDiameter(queryParam); |
| | | toolList.addAll(paraHoleToolsList); |
| | | break; |
| | | case MILL: |
| | | List<ParaMillToolVo> paraMillToolList = paraMillToolService.selectByClassifyAndDiameter(classify.getId(), diameter); |
| | | List<ParaMillToolVo> paraMillToolList = paraMillToolService.selectByClassifyAndDiameter(queryParam); |
| | | toolList.addAll(paraMillToolList); |
| | | break; |
| | | case TURNING: |
| | | List<ParaTurningToolsVo> paraTurningToolsList = paraTurningToolsService.selectByClassifyAndDiameter(classify.getId(), diameter); |
| | | List<ParaTurningToolsVo> paraTurningToolsList = paraTurningToolsService.selectByClassifyAndDiameter(queryParam); |
| | | toolList.addAll(paraTurningToolsList); |
| | | break; |
| | | default: |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package org.jeecg.modules.tms.entity.dto; |
| | | |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | import org.jeecgframework.poi.excel.annotation.Excel; |
| | | |
| | | /*** |
| | | * DNCå·¥å
·æ¥è¯¢åæ°å°è£
|
| | | */ |
| | | @Data |
| | | public class ToolQueryParamDto { |
| | | /**å¤ååæ°(å·¥å
·ç®ç§°/ç´å¾åæ°)ï¼ä¾å¦ï¼3E*/ |
| | | @ApiModelProperty(value = "å¤ååæ°(å·¥å
·ç®ç§°/ç´å¾åæ°)ï¼ä¾å¦ï¼3E") |
| | | private String param; |
| | | /**åå
·åç±»ID(ä¸ç¨åç«¯ä¼ ï¼åå°è®°å½åæ°ç¨)*/ |
| | | private String classifyId; |
| | | /**åå
·ç´å¾(ä¸ç¨åç«¯ä¼ ï¼åå°è®°å½åæ°ç¨)*/ |
| | | private String diameter; |
| | | /**åå
·æ»é¿*/ |
| | | @ApiModelProperty(value = "åå
·æ»é¿") |
| | | private String totalLength; |
| | | /**åå
·ææ*/ |
| | | @ApiModelProperty(value = "åå
·ææ") |
| | | private String toolMaterial; |
| | | /**åååé¿*/ |
| | | @ApiModelProperty(value = "åååé¿(åå å·¥åå
·ãé£ååå
·)") |
| | | private String edgeLength; |
| | | /**åæ°(åå å·¥åå
·)*/ |
| | | @ApiModelProperty(value = "åæ°(åå å·¥åå
·)") |
| | | private String bladeCount; |
| | | /**ææå å·¥é¿åº¦*/ |
| | | @ApiModelProperty(value = "ææå å·¥é¿åº¦(åå å·¥åå
·)") |
| | | private String effectiveLength; |
| | | /**æå°éåç´å¾(åå å·¥åå
·)*/ |
| | | @ApiModelProperty(value = "æå°éåç´å¾(åå å·¥åå
·)") |
| | | private String latestBoringDiameter; |
| | | /**æå¤§éåç´å¾(åå å·¥åå
·)*/ |
| | | @ApiModelProperty(value = "æå¤§éåç´å¾(åå å·¥åå
·)") |
| | | private String maxBoringDiameter; |
| | | /**åæç´å¾*/ |
| | | @ApiModelProperty(value = "åæç´å¾(åå å·¥åå
·)") |
| | | private String knifeDiameter; |
| | | /**åå¾*/ |
| | | @ApiModelProperty(value = "åå¾(åå å·¥åå
·)") |
| | | private String boreDiameter; |
| | | /**å头æ°*/ |
| | | @ApiModelProperty(value = "å头æ°(åå å·¥åå
·)") |
| | | private String headsNumber; |
| | | /**齿æ°*/ |
| | | @ApiModelProperty(value = "齿æ°(é£ååå
·)") |
| | | private String numberOfTeeth; |
| | | /**é¢å¾*/ |
| | | @ApiModelProperty(value = "é¢å¾(é£ååå
·)") |
| | | private String neckDiameter; |
| | | /**æå°ç´å¾*/ |
| | | @Excel(name = "æå°ç´å¾", width = 15) |
| | | @ApiModelProperty(value = "æå°ç´å¾(åå å·¥åå
·ãé£ååå
·ã车ååå
·)") |
| | | private String smallDiameter; |
| | | /**æé¿*/ |
| | | @ApiModelProperty(value = "æé¿(é£ååå
·)") |
| | | private String handleLength; |
| | | /**æå¤§åæ·±*/ |
| | | @ApiModelProperty(value = "æå¤§åæ·±(é£ååå
·)") |
| | | private String deepestDepth; |
| | | /**æé¢é¿åº¦*/ |
| | | @ApiModelProperty(value = "æé¢é¿åº¦(é£ååå
·)") |
| | | private String handleNeckLength; |
| | | /**æ¬ä¼¸é¿åº¦*/ |
| | | @ApiModelProperty(value = "æ¬ä¼¸é¿åº¦(é£ååå
·)") |
| | | private String overhangingLength; |
| | | /**èºè·*/ |
| | | @ApiModelProperty(value = "èºè·(é£ååå
·)") |
| | | private String pitch; |
| | | /**æå°å å·¥ç´å¾*/ |
| | | @ApiModelProperty(value = "æå°å å·¥ç´å¾(é£ååå
·)") |
| | | private String recentlyDiameter; |
| | | /**é
å¥åçå·*/ |
| | | @ApiModelProperty(value = "é
å¥åçå·(车ååå
·)") |
| | | private String matchingNumber; |
| | | /**ååæ¹å*/ |
| | | @ApiModelProperty(value = "ååæ¹å(车ååå
·)") |
| | | private String cuttingDirection; |
| | | /**åç尺寸*/ |
| | | @ApiModelProperty(value = "åç尺寸(车ååå
·)") |
| | | private String knifeSize; |
| | | /**éæç´å¾*/ |
| | | @ApiModelProperty(value = "éæç´å¾(车ååå
·)") |
| | | private String boringBarDiameter; |
| | | /**åæé¿åº¦*/ |
| | | @ApiModelProperty(value = "åæé¿åº¦(车ååå
·)") |
| | | private String bladeLength; |
| | | /**åææ¹å*/ |
| | | @ApiModelProperty(value = "åææ¹å(车ååå
·)") |
| | | private String barDirection; |
| | | /**åæé«åº¦*/ |
| | | @ApiModelProperty(value = "åæé«åº¦(车ååå
·)") |
| | | private String bladeHeight; |
| | | /**åæå®½åº¦*/ |
| | | @ApiModelProperty(value = "åæå®½åº¦(车ååå
·)") |
| | | private String bladeWide; |
| | | /**åçæ§½å®½*/ |
| | | @ApiModelProperty(value = "åçæ§½å®½(车ååå
·)") |
| | | private String slotWidth; |
| | | /**æå¤§åå
¥ç´å¾*/ |
| | | @ApiModelProperty(value = "æå¤§åå
¥ç´å¾(车ååå
·)") |
| | | private String maxDiameter; |
| | | /**æå¤§å槽深度*/ |
| | | @ApiModelProperty(value = "æå¤§å槽深度(车ååå
·)") |
| | | private String maxDepth; |
| | | /**åæ¿å度*/ |
| | | @ApiModelProperty(value = "åæ¿å度(车ååå
·)") |
| | | private String bladeThickness; |
| | | /**æå°å å·¥ç´å¾*/ |
| | | @ApiModelProperty(value = "æå°å å·¥ç´å¾(车ååå
·)") |
| | | private String minDiameter; |
| | | } |
| | |
| | | |
| | | import java.util.List; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.core.toolkit.Constants; |
| | | import org.apache.ibatis.annotations.Param; |
| | | import org.jeecg.modules.tms.entity.ParaHoleTools; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | |
| | | */ |
| | | public interface ParaHoleToolsMapper extends BaseMapper<ParaHoleTools> { |
| | | |
| | | List<ParaHolesToolsVo> selectByClassifyAndDiameter(@Param("classifyId") String classifyId, |
| | | @Param("diameter") String diameter); |
| | | List<ParaHolesToolsVo> selectByClassifyAndDiameter(@Param(Constants.WRAPPER) |
| | | LambdaQueryWrapper<ParaHolesToolsVo> queryWrapper); |
| | | } |
| | |
| | | |
| | | import java.util.List; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.core.toolkit.Constants; |
| | | import org.apache.ibatis.annotations.Param; |
| | | import org.jeecg.modules.tms.entity.ParaMillTool; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | |
| | | */ |
| | | public interface ParaMillToolMapper extends BaseMapper<ParaMillTool> { |
| | | |
| | | List<ParaMillToolVo> selectByClassifyAndDiameter(@Param("classifyId") String classifyId, |
| | | @Param("diameter") String diameter); |
| | | List<ParaMillToolVo> selectByClassifyAndDiameter(@Param(Constants.WRAPPER) |
| | | LambdaQueryWrapper<ParaMillTool> queryWrapper); |
| | | } |
| | |
| | | |
| | | import java.util.List; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.core.toolkit.Constants; |
| | | import org.apache.ibatis.annotations.Param; |
| | | import org.jeecg.modules.tms.entity.ParaTurningTools; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | |
| | | */ |
| | | public interface ParaTurningToolsMapper extends BaseMapper<ParaTurningTools> { |
| | | |
| | | List<ParaTurningToolsVo> selectByClassifyAndDiameter(@Param("classifyId") String classifyId, |
| | | @Param("diameter") String diameter); |
| | | List<ParaTurningToolsVo> selectByClassifyAndDiameter(@Param(Constants.WRAPPER) |
| | | LambdaQueryWrapper<ParaTurningTools> queryWrapper); |
| | | } |
| | |
| | | |
| | | <select id="selectByClassifyAndDiameter" resultType="org.jeecg.modules.tms.entity.vo.ParaHolesToolsVo"> |
| | | SELECT |
| | | t.id, |
| | | t.classify_id AS classifyId, |
| | | t2.classify_id AS classifyNum, |
| | | t2.type_name AS classifyName, |
| | | t1.id AS toolId, |
| | | t1.tool_code AS toolCode, |
| | | t.sign_code AS signCode, |
| | | t.chinese_name AS chineseName, |
| | | t.foreign_language_name AS foreignLanguageName, |
| | | t.standard_level AS standardLevel, |
| | | t.standard_code AS standardCode, |
| | | t.position_code AS positionCode, |
| | | t.tool_model AS toolModel, |
| | | t.diameter, |
| | | t.cone_angle AS coneAngle, |
| | | t.edge_length AS edgeLength, |
| | | t.total_length AS totalLength, |
| | | t.tool_material AS toolMaterial, |
| | | t.part_material AS partMaterial, |
| | | t.paintcoat_flag AS paintcoatFlag, |
| | | t.tool_pattern AS toolPattern, |
| | | t.handle_specifications AS handleSpecifications, |
| | | t.cooling_method AS coolingMethod, |
| | | t.technical_conditions AS technicalConditions, |
| | | t.conditions_info AS conditionsInfo, |
| | | t.brand, |
| | | t.types, |
| | | t.tolerance_class AS toleranceClass, |
| | | t.flute_form AS fluteForm, |
| | | t.handle_form AS handleForm, |
| | | t.blade_count AS bladeCount, |
| | | t.small_diameter AS smallDiameter, |
| | | t.chamfer_angle AS chamferAngle, |
| | | t.fitter_part AS fitterPart, |
| | | t.effective_length AS effectiveLength, |
| | | t.drill_diameter_range AS drillDiameterRange, |
| | | t.knife_diameter AS knifeDiameter, |
| | | t.bore_diameter AS boreDiameter, |
| | | t.connector_type AS connectorType, |
| | | t.slot_specification AS slotSpecification, |
| | | t.scope_of_application AS scopeOfApplication, |
| | | t.latest_boring_diameter AS latestBoringDiameter, |
| | | t.max_boring_diameter AS maxBoringDiameter, |
| | | t.processingmethod, |
| | | t.heads_number AS headsNumber, |
| | | t.adapt_holder AS adaptHolder |
| | | t.id, |
| | | t.classify_id AS classifyId, |
| | | t2.classify_id AS classifyNum, |
| | | t2.type_name AS classifyName, |
| | | t1.id AS toolId, |
| | | t1.tool_code AS toolCode, |
| | | t.sign_code AS signCode, |
| | | t.chinese_name AS chineseName, |
| | | t.foreign_language_name AS foreignLanguageName, |
| | | t.standard_level AS standardLevel, |
| | | t.standard_code AS standardCode, |
| | | t.position_code AS positionCode, |
| | | t.tool_model AS toolModel, |
| | | t.diameter, |
| | | t.cone_angle AS coneAngle, |
| | | t.edge_length AS edgeLength, |
| | | t.total_length AS totalLength, |
| | | t.tool_material AS toolMaterial, |
| | | t.part_material AS partMaterial, |
| | | t.paintcoat_flag AS paintcoatFlag, |
| | | t.tool_pattern AS toolPattern, |
| | | t.handle_specifications AS handleSpecifications, |
| | | t.cooling_method AS coolingMethod, |
| | | t.technical_conditions AS technicalConditions, |
| | | t.conditions_info AS conditionsInfo, |
| | | t.brand, |
| | | t.types, |
| | | t.tolerance_class AS toleranceClass, |
| | | t.flute_form AS fluteForm, |
| | | t.handle_form AS handleForm, |
| | | t.blade_count AS bladeCount, |
| | | t.small_diameter AS smallDiameter, |
| | | t.chamfer_angle AS chamferAngle, |
| | | t.fitter_part AS fitterPart, |
| | | t.effective_length AS effectiveLength, |
| | | t.drill_diameter_range AS drillDiameterRange, |
| | | t.knife_diameter AS knifeDiameter, |
| | | t.bore_diameter AS boreDiameter, |
| | | t.connector_type AS connectorType, |
| | | t.slot_specification AS slotSpecification, |
| | | t.scope_of_application AS scopeOfApplication, |
| | | t.latest_boring_diameter AS latestBoringDiameter, |
| | | t.max_boring_diameter AS maxBoringDiameter, |
| | | t.processingmethod, |
| | | t.heads_number AS headsNumber, |
| | | t.adapt_holder AS adaptHolder |
| | | FROM tms_para_hole_tools t |
| | | LEFT JOIN tms_base_tools t1 on t.tool_code = t1.id |
| | | LEFT JOIN tms_tools_classify t2 on t.classify_id = t2.id |
| | | <where> |
| | | <if test="classifyId != null and classifyId != ''"> |
| | | AND t.classify_id = #{classifyId} |
| | | </if> |
| | | <if test="diameter != null and diameter != ''"> |
| | | AND t.diameter = #{diameter} |
| | | </if> |
| | | </where> |
| | | ${ew.customSqlSegment} |
| | | </select> |
| | | </mapper> |
| | |
| | | FROM tms_para_mill_tool t |
| | | LEFT JOIN tms_base_tools t1 on t.tool_code = t1.id |
| | | LEFT JOIN tms_tools_classify t2 on t.classify_id = t2.id |
| | | <where> |
| | | <if test="classifyId != null and classifyId != ''"> |
| | | AND t.classify_id = #{classifyId} |
| | | </if> |
| | | <if test="diameter != null and diameter != ''"> |
| | | AND t.diameter = #{diameter} |
| | | </if> |
| | | </where> |
| | | ${ew.customSqlSegment} |
| | | </select> |
| | | </mapper> |
| | |
| | | FROM tms_para_turning_tools t |
| | | LEFT JOIN tms_base_tools t1 ON t.tool_code = t1.id |
| | | LEFT JOIN tms_tools_classify t2 on t.classify_id = t2.id |
| | | <where> |
| | | <if test="classifyId != null and classifyId != ''"> |
| | | AND t.classify_id = #{classifyId} |
| | | </if> |
| | | <if test="diameter != null and diameter != ''"> |
| | | AND t.diameter = #{diameter} |
| | | </if> |
| | | </where> |
| | | ${ew.customSqlSegment} |
| | | </select> |
| | | </mapper> |
| | |
| | | |
| | | import org.jeecg.modules.tms.entity.ParaHoleTools; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import org.jeecg.modules.tms.entity.dto.ToolQueryParamDto; |
| | | import org.jeecg.modules.tms.entity.vo.ParaHolesToolsVo; |
| | | |
| | | import java.util.List; |
| | |
| | | */ |
| | | public interface IParaHoleToolsService extends IService<ParaHoleTools> { |
| | | |
| | | List<ParaHolesToolsVo> selectByClassifyAndDiameter(String classifyId, String diameter); |
| | | List<ParaHolesToolsVo> selectByClassifyAndDiameter(ToolQueryParamDto queryParamDto); |
| | | } |
| | |
| | | |
| | | import org.jeecg.modules.tms.entity.ParaMillTool; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import org.jeecg.modules.tms.entity.dto.ToolQueryParamDto; |
| | | import org.jeecg.modules.tms.entity.vo.ParaMillToolVo; |
| | | |
| | | import java.util.List; |
| | |
| | | */ |
| | | public interface IParaMillToolService extends IService<ParaMillTool> { |
| | | |
| | | List<ParaMillToolVo> selectByClassifyAndDiameter(String classifyId, String diameter); |
| | | List<ParaMillToolVo> selectByClassifyAndDiameter(ToolQueryParamDto queryParamDto); |
| | | } |
| | |
| | | |
| | | import org.jeecg.modules.tms.entity.ParaTurningTools; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import org.jeecg.modules.tms.entity.dto.ToolQueryParamDto; |
| | | import org.jeecg.modules.tms.entity.vo.ParaTurningToolsVo; |
| | | |
| | | import java.util.List; |
| | |
| | | */ |
| | | public interface IParaTurningToolsService extends IService<ParaTurningTools> { |
| | | |
| | | List<ParaTurningToolsVo> selectByClassifyAndDiameter(String classifyId, String diameter); |
| | | List<ParaTurningToolsVo> selectByClassifyAndDiameter(ToolQueryParamDto queryParamDto); |
| | | } |
| | |
| | | package org.jeecg.modules.tms.service.impl; |
| | | |
| | | import cn.hutool.core.util.StrUtil; |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import org.jeecg.modules.tms.entity.ParaHoleTools; |
| | | import org.jeecg.modules.tms.entity.dto.ToolQueryParamDto; |
| | | import org.jeecg.modules.tms.entity.vo.ParaHolesToolsVo; |
| | | import org.jeecg.modules.tms.mapper.ParaHoleToolsMapper; |
| | | import org.jeecg.modules.tms.service.IParaHoleToolsService; |
| | |
| | | public class ParaHoleToolsServiceImpl extends ServiceImpl<ParaHoleToolsMapper, ParaHoleTools> implements IParaHoleToolsService { |
| | | |
| | | @Override |
| | | public List<ParaHolesToolsVo> selectByClassifyAndDiameter(String classifyId, String diameter) { |
| | | return this.baseMapper.selectByClassifyAndDiameter(classifyId, diameter); |
| | | public List<ParaHolesToolsVo> selectByClassifyAndDiameter(ToolQueryParamDto paramDto) { |
| | | LambdaQueryWrapper<ParaHolesToolsVo> queryWrapper = new LambdaQueryWrapper<>(); |
| | | if (paramDto != null) { |
| | | // åå å·¥åå
·ç¸å
³åæ°å段 |
| | | queryWrapper |
| | | .eq(StrUtil.isNotBlank(paramDto.getClassifyId()), ParaHolesToolsVo::getClassifyId, paramDto.getClassifyId()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getDiameter()), ParaHolesToolsVo::getDiameter, paramDto.getDiameter()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getTotalLength()), ParaHolesToolsVo::getTotalLength, paramDto.getTotalLength()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getToolMaterial()), ParaHolesToolsVo::getToolMaterial, paramDto.getToolMaterial()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getEdgeLength()), ParaHolesToolsVo::getEdgeLength, paramDto.getEdgeLength()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getBladeCount()), ParaHolesToolsVo::getBladeCount, paramDto.getBladeCount()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getEffectiveLength()), ParaHolesToolsVo::getEffectiveLength, paramDto.getEffectiveLength()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getLatestBoringDiameter()), ParaHolesToolsVo::getLatestBoringDiameter, paramDto.getLatestBoringDiameter()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getMaxBoringDiameter()), ParaHolesToolsVo::getMaxBoringDiameter, paramDto.getMaxBoringDiameter()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getKnifeDiameter()), ParaHolesToolsVo::getKnifeDiameter, paramDto.getKnifeDiameter()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getBoreDiameter()), ParaHolesToolsVo::getBoreDiameter, paramDto.getBoreDiameter()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getHeadsNumber()), ParaHolesToolsVo::getHeadsNumber, paramDto.getHeadsNumber()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getSmallDiameter()), ParaHolesToolsVo::getSmallDiameter, paramDto.getSmallDiameter()); |
| | | } |
| | | return this.baseMapper.selectByClassifyAndDiameter(queryWrapper); |
| | | } |
| | | } |
| | |
| | | package org.jeecg.modules.tms.service.impl; |
| | | |
| | | import cn.hutool.core.util.StrUtil; |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import org.jeecg.modules.tms.entity.ParaMillTool; |
| | | import org.jeecg.modules.tms.entity.dto.ToolQueryParamDto; |
| | | import org.jeecg.modules.tms.entity.vo.ParaMillToolVo; |
| | | import org.jeecg.modules.tms.mapper.ParaMillToolMapper; |
| | | import org.jeecg.modules.tms.service.IParaMillToolService; |
| | |
| | | public class ParaMillToolServiceImpl extends ServiceImpl<ParaMillToolMapper, ParaMillTool> implements IParaMillToolService { |
| | | |
| | | @Override |
| | | public List<ParaMillToolVo> selectByClassifyAndDiameter(String classifyId, String diameter) { |
| | | return this.baseMapper.selectByClassifyAndDiameter(classifyId, diameter); |
| | | public List<ParaMillToolVo> selectByClassifyAndDiameter(ToolQueryParamDto paramDto) { |
| | | LambdaQueryWrapper<ParaMillTool> queryWrapper = new LambdaQueryWrapper<>(); |
| | | if (paramDto != null) { |
| | | //é£ååå
·ç¸å
³åæ°å段 |
| | | queryWrapper |
| | | .eq(StrUtil.isNotBlank(paramDto.getClassifyId()), ParaMillTool::getClassifyId, paramDto.getClassifyId()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getDiameter()), ParaMillTool::getDiameter, paramDto.getDiameter()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getTotalLength()), ParaMillTool::getTotalLength, paramDto.getTotalLength()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getToolMaterial()), ParaMillTool::getToolMaterial, paramDto.getToolMaterial()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getEdgeLength()), ParaMillTool::getEdgeLength, paramDto.getEdgeLength()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getNumberOfTeeth()), ParaMillTool::getNumberOfTeeth, paramDto.getNumberOfTeeth()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getNeckDiameter()), ParaMillTool::getNeckDiameter, paramDto.getNeckDiameter()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getSmallDiameter()), ParaMillTool::getSmallDiameter, paramDto.getSmallDiameter()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getHandleLength()), ParaMillTool::getHandleLength, paramDto.getHandleLength()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getDeepestDepth()), ParaMillTool::getDeepestDepth, paramDto.getDeepestDepth()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getHandleNeckLength()), ParaMillTool::getHandleNeckLength, paramDto.getHandleNeckLength()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getOverhangingLength()), ParaMillTool::getOverhangingLength, paramDto.getOverhangingLength()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getPitch()), ParaMillTool::getPitch, paramDto.getPitch()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getRecentlyDiameter()), ParaMillTool::getRecentlyDiameter, paramDto.getRecentlyDiameter()); |
| | | } |
| | | return this.baseMapper.selectByClassifyAndDiameter(queryWrapper); |
| | | } |
| | | } |
| | |
| | | package org.jeecg.modules.tms.service.impl; |
| | | |
| | | import cn.hutool.core.util.StrUtil; |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import org.jeecg.modules.tms.entity.ParaTurningTools; |
| | | import org.jeecg.modules.tms.entity.dto.ToolQueryParamDto; |
| | | import org.jeecg.modules.tms.entity.vo.ParaTurningToolsVo; |
| | | import org.jeecg.modules.tms.mapper.ParaTurningToolsMapper; |
| | | import org.jeecg.modules.tms.service.IParaTurningToolsService; |
| | |
| | | public class ParaTurningToolsServiceImpl extends ServiceImpl<ParaTurningToolsMapper, ParaTurningTools> implements IParaTurningToolsService { |
| | | |
| | | @Override |
| | | public List<ParaTurningToolsVo> selectByClassifyAndDiameter(String classifyId, String diameter) { |
| | | return this.baseMapper.selectByClassifyAndDiameter(classifyId, diameter); |
| | | public List<ParaTurningToolsVo> selectByClassifyAndDiameter(ToolQueryParamDto paramDto) { |
| | | LambdaQueryWrapper<ParaTurningTools> queryWrapper = new LambdaQueryWrapper<>(); |
| | | if (paramDto != null) { |
| | | //车ååå
·ç¸å
³åæ°å段 |
| | | queryWrapper |
| | | .eq(StrUtil.isNotBlank(paramDto.getClassifyId()), ParaTurningTools::getClassifyId, paramDto.getClassifyId()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getDiameter()), ParaTurningTools::getToolDiameter, paramDto.getDiameter()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getTotalLength()), ParaTurningTools::getTotalLength, paramDto.getTotalLength()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getToolMaterial()), ParaTurningTools::getToolMaterial, paramDto.getToolMaterial()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getSmallDiameter()), ParaTurningTools::getSmallDiameter, paramDto.getSmallDiameter()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getCuttingDirection()), ParaTurningTools::getCuttingDirection, paramDto.getCuttingDirection()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getKnifeSize()), ParaTurningTools::getKnifeSize, paramDto.getKnifeSize()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getBoringBarDiameter()), ParaTurningTools::getBoringBarDiameter, paramDto.getBoringBarDiameter()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getBladeLength()), ParaTurningTools::getBladeLength, paramDto.getBladeLength()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getBarDirection()), ParaTurningTools::getBarDirection, paramDto.getBarDirection()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getBladeHeight()), ParaTurningTools::getBladeHeight, paramDto.getBladeHeight()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getBladeWide()), ParaTurningTools::getBladeWide, paramDto.getBladeWide()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getSlotWidth()), ParaTurningTools::getSlotWidth, paramDto.getSlotWidth()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getMaxDiameter()), ParaTurningTools::getMaxDiameter, paramDto.getMaxDiameter()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getMaxDepth()), ParaTurningTools::getMaxDepth, paramDto.getMaxDepth()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getBladeThickness()), ParaTurningTools::getBladeThickness, paramDto.getBladeThickness()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getMinDiameter()), ParaTurningTools::getMinDiameter, paramDto.getMinDiameter()) |
| | | .eq(StrUtil.isNotBlank(paramDto.getMatchingNumber()), ParaTurningTools::getMatchingNumber, paramDto.getMatchingNumber()); |
| | | } |
| | | return this.baseMapper.selectByClassifyAndDiameter(queryWrapper); |
| | | } |
| | | } |