Browse Source

处理isc_materials_property_value

车车 4 tháng trước cách đây
mục cha
commit
c11a28e9ec

+ 92 - 95
yudao-module-iscs/src/main/java/cn/iocoder/yudao/module/iscs/controller/admin/materialspropertyvalue/MaterialsPropertyValueController.java

@@ -1,95 +1,92 @@
-package cn.iocoder.yudao.module.iscs.controller.admin.materialspropertyvalue;
-
-import org.springframework.web.bind.annotation.*;
-import jakarta.annotation.Resource;
-import org.springframework.validation.annotation.Validated;
-import org.springframework.security.access.prepost.PreAuthorize;
-import io.swagger.v3.oas.annotations.tags.Tag;
-import io.swagger.v3.oas.annotations.Parameter;
-import io.swagger.v3.oas.annotations.Operation;
-
-import jakarta.validation.constraints.*;
-import jakarta.validation.*;
-import jakarta.servlet.http.*;
-import java.util.*;
-import java.io.IOException;
-
-import cn.iocoder.yudao.framework.common.pojo.PageParam;
-import cn.iocoder.yudao.framework.common.pojo.PageResult;
-import cn.iocoder.yudao.framework.common.pojo.CommonResult;
-import cn.iocoder.yudao.framework.common.util.object.BeanUtils;
-import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
-
-import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils;
-
-import cn.iocoder.yudao.framework.apilog.core.annotation.ApiAccessLog;
-import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.*;
-
-import cn.iocoder.yudao.module.iscs.controller.admin.materialspropertyvalue.vo.*;
-import cn.iocoder.yudao.module.iscs.dal.dataobject.materialspropertyvalue.MaterialsPropertyValueDO;
-import cn.iocoder.yudao.module.iscs.service.materialspropertyvalue.MaterialsPropertyValueService;
-
-@Tag(name = "管理后台 - 物资属性值")
-@RestController
-@RequestMapping("/iscs/materials-property-value")
-@Validated
-public class MaterialsPropertyValueController {
-
-    @Resource
-    private MaterialsPropertyValueService materialsPropertyValueService;
-
-    @PostMapping("/insertMaterialsPropertyValue")
-    @Operation(summary = "创建物资属性值")
-    @PreAuthorize("@ss.hasPermission('iscs:materials-property-value:create')")
-    public CommonResult<Long> insertMaterialsPropertyValue(@Valid @RequestBody MaterialsPropertyValueSaveReqVO createReqVO) {
-        return success(materialsPropertyValueService.createMaterialsPropertyValue(createReqVO));
-    }
-
-    @PutMapping("/updateMaterialsPropertyValue")
-    @Operation(summary = "更新物资属性值")
-    @PreAuthorize("@ss.hasPermission('iscs:materials-property-value:update')")
-    public CommonResult<Boolean> updateMaterialsPropertyValue(@Valid @RequestBody MaterialsPropertyValueSaveReqVO updateReqVO) {
-        materialsPropertyValueService.updateMaterialsPropertyValue(updateReqVO);
-        return success(true);
-    }
-
-    @DeleteMapping("/deleteMaterialsPropertyValueList")
-    @Parameter(name = "ids", description = "编号", required = true)
-    @Operation(summary = "批量删除物资属性值")
-                @PreAuthorize("@ss.hasPermission('iscs:materials-property-value:delete')")
-    public CommonResult<Boolean> deleteMaterialsPropertyValueList(@RequestParam("ids") List<Long> ids) {
-        materialsPropertyValueService.deleteMaterialsPropertyValueListByIds(ids);
-        return success(true);
-    }
-
-    @GetMapping("/selectMaterialsPropertyValueById")
-    @Operation(summary = "获得物资属性值")
-    @Parameter(name = "id", description = "编号", required = true, example = "1024")
-    @PreAuthorize("@ss.hasPermission('iscs:materials-property-value:query')")
-    public CommonResult<MaterialsPropertyValueRespVO> selectMaterialsPropertyValueById(@RequestParam("id") Long id) {
-        MaterialsPropertyValueDO materialsPropertyValue = materialsPropertyValueService.getMaterialsPropertyValue(id);
-        return success(BeanUtils.toBean(materialsPropertyValue, MaterialsPropertyValueRespVO.class));
-    }
-
-    @GetMapping("/getMaterialsPropertyValuePage")
-    @Operation(summary = "获得物资属性值分页")
-    @PreAuthorize("@ss.hasPermission('iscs:materials-property-value:query')")
-    public CommonResult<PageResult<MaterialsPropertyValueRespVO>> getMaterialsPropertyValuePage(@Valid MaterialsPropertyValuePageReqVO pageReqVO) {
-        PageResult<MaterialsPropertyValueDO> pageResult = materialsPropertyValueService.getMaterialsPropertyValuePage(pageReqVO);
-        return success(BeanUtils.toBean(pageResult, MaterialsPropertyValueRespVO.class));
-    }
-
-    @GetMapping("/exportMaterialsPropertyValueExcel")
-    @Operation(summary = "导出物资属性值 Excel")
-    @PreAuthorize("@ss.hasPermission('iscs:materials-property-value:export')")
-    @ApiAccessLog(operateType = EXPORT)
-    public void exportMaterialsPropertyValueExcel(@Valid MaterialsPropertyValuePageReqVO pageReqVO,
-              HttpServletResponse response) throws IOException {
-        pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
-        List<MaterialsPropertyValueDO> list = materialsPropertyValueService.getMaterialsPropertyValuePage(pageReqVO).getList();
-        // 导出 Excel
-        ExcelUtils.write(response, "物资属性值.xls", "数据", MaterialsPropertyValueRespVO.class,
-                        BeanUtils.toBean(list, MaterialsPropertyValueRespVO.class));
-    }
-
-}
+package cn.iocoder.yudao.module.iscs.controller.admin.materialspropertyvalue;
+
+import cn.iocoder.yudao.framework.apilog.core.annotation.ApiAccessLog;
+import cn.iocoder.yudao.framework.common.pojo.CommonResult;
+import cn.iocoder.yudao.framework.common.pojo.PageParam;
+import cn.iocoder.yudao.framework.common.pojo.PageResult;
+import cn.iocoder.yudao.framework.common.util.object.BeanUtils;
+import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils;
+import cn.iocoder.yudao.module.iscs.controller.admin.materialspropertyvalue.vo.MaterialsPropertyValuePageReqVO;
+import cn.iocoder.yudao.module.iscs.controller.admin.materialspropertyvalue.vo.MaterialsPropertyValueRespVO;
+import cn.iocoder.yudao.module.iscs.controller.admin.materialspropertyvalue.vo.MaterialsPropertyValueSaveReqVO;
+import cn.iocoder.yudao.module.iscs.dal.dataobject.materialspropertyvalue.MaterialsPropertyValueDO;
+import cn.iocoder.yudao.module.iscs.service.materialspropertyvalue.MaterialsPropertyValueService;
+import io.swagger.v3.oas.annotations.Operation;
+import io.swagger.v3.oas.annotations.Parameter;
+import io.swagger.v3.oas.annotations.tags.Tag;
+import jakarta.annotation.Resource;
+import jakarta.servlet.http.HttpServletResponse;
+import jakarta.validation.Valid;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.validation.annotation.Validated;
+import org.springframework.web.bind.annotation.*;
+
+import java.io.IOException;
+import java.util.List;
+
+import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT;
+import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
+
+@Tag(name = "管理后台 - 物资属性值")
+@RestController
+@RequestMapping("/iscs/materials-property-value")
+@Validated
+public class MaterialsPropertyValueController {
+
+    @Resource
+    private MaterialsPropertyValueService materialsPropertyValueService;
+
+    @PostMapping("/insertMaterialsPropertyValue")
+    @Operation(summary = "创建物资属性值")
+    @PreAuthorize("@ss.hasPermission('iscs:materials-property-value:create')")
+    public CommonResult<Long> insertMaterialsPropertyValue(@Valid @RequestBody MaterialsPropertyValueSaveReqVO createReqVO) {
+        return success(materialsPropertyValueService.createMaterialsPropertyValue(createReqVO));
+    }
+
+    @PutMapping("/updateMaterialsPropertyValue")
+    @Operation(summary = "更新物资属性值")
+    @PreAuthorize("@ss.hasPermission('iscs:materials-property-value:update')")
+    public CommonResult<Boolean> updateMaterialsPropertyValue(@Valid @RequestBody MaterialsPropertyValueSaveReqVO updateReqVO) {
+        materialsPropertyValueService.updateMaterialsPropertyValue(updateReqVO);
+        return success(true);
+    }
+
+    @DeleteMapping("/deleteMaterialsPropertyValueList")
+    @Parameter(name = "ids", description = "编号", required = true)
+    @Operation(summary = "批量删除物资属性值")
+                @PreAuthorize("@ss.hasPermission('iscs:materials-property-value:delete')")
+    public CommonResult<Boolean> deleteMaterialsPropertyValueList(@RequestParam("ids") List<Long> ids) {
+        materialsPropertyValueService.deleteMaterialsPropertyValueListByIds(ids);
+        return success(true);
+    }
+
+    @GetMapping("/selectMaterialsPropertyValueById")
+    @Operation(summary = "获得物资属性值")
+    @Parameter(name = "id", description = "编号", required = true, example = "1024")
+    @PreAuthorize("@ss.hasPermission('iscs:materials-property-value:query')")
+    public CommonResult<MaterialsPropertyValueRespVO> selectMaterialsPropertyValueById(@RequestParam("id") Long id) {
+        MaterialsPropertyValueDO materialsPropertyValue = materialsPropertyValueService.getMaterialsPropertyValue(id);
+        return success(BeanUtils.toBean(materialsPropertyValue, MaterialsPropertyValueRespVO.class));
+    }
+
+    @GetMapping("/getMaterialsPropertyValuePage")
+    @Operation(summary = "获得物资属性值分页")
+    @PreAuthorize("@ss.hasPermission('iscs:materials-property-value:query')")
+    public CommonResult<PageResult<MaterialsPropertyValueRespVO>> getMaterialsPropertyValuePage(@Valid MaterialsPropertyValuePageReqVO pageReqVO) {
+        PageResult<MaterialsPropertyValueRespVO> pageResult = materialsPropertyValueService.getMaterialsPropertyValuePage(pageReqVO);
+        return success(pageResult);
+    }
+
+    @GetMapping("/exportMaterialsPropertyValueExcel")
+    @Operation(summary = "导出物资属性值 Excel")
+    @PreAuthorize("@ss.hasPermission('iscs:materials-property-value:export')")
+    @ApiAccessLog(operateType = EXPORT)
+    public void exportMaterialsPropertyValueExcel(@Valid MaterialsPropertyValuePageReqVO pageReqVO,
+              HttpServletResponse response) throws IOException {
+        pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
+        List<MaterialsPropertyValueRespVO> list = materialsPropertyValueService.getMaterialsPropertyValuePage(pageReqVO).getList();
+        // 导出 Excel
+        ExcelUtils.write(response, "物资属性值.xls", "数据", MaterialsPropertyValueRespVO.class, list);
+    }
+
+}

+ 10 - 5
yudao-module-iscs/src/main/java/cn/iocoder/yudao/module/iscs/controller/admin/materialspropertyvalue/vo/MaterialsPropertyValueRespVO.java

@@ -1,11 +1,12 @@
 package cn.iocoder.yudao.module.iscs.controller.admin.materialspropertyvalue.vo;
 
+import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
+import com.alibaba.excel.annotation.ExcelProperty;
+import com.baomidou.mybatisplus.annotation.TableField;
 import io.swagger.v3.oas.annotations.media.Schema;
-import lombok.*;
-import java.util.*;
-import org.springframework.format.annotation.DateTimeFormat;
+import lombok.Data;
+
 import java.time.LocalDateTime;
-import com.alibaba.excel.annotation.*;
 
 @Schema(description = "管理后台 - 物资属性值 Response VO")
 @Data
@@ -36,4 +37,8 @@ public class MaterialsPropertyValueRespVO {
     @ExcelProperty("创建时间")
     private LocalDateTime createTime;
 
-}
+    @Schema(description = "属性项的编号")
+    @TableField(exist = false)
+    private String propertyName;
+
+}

+ 8 - 5
yudao-module-iscs/src/main/java/cn/iocoder/yudao/module/iscs/dal/mysql/materialspropertyvalue/MaterialsPropertyValueMapper.java

@@ -1,13 +1,14 @@
 package cn.iocoder.yudao.module.iscs.dal.mysql.materialspropertyvalue;
 
-import java.util.*;
-
 import cn.iocoder.yudao.framework.common.pojo.PageResult;
-import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
 import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
+import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
+import cn.iocoder.yudao.module.iscs.controller.admin.materialspropertyvalue.vo.MaterialsPropertyValuePageReqVO;
+import cn.iocoder.yudao.module.iscs.controller.admin.materialspropertyvalue.vo.MaterialsPropertyValueRespVO;
 import cn.iocoder.yudao.module.iscs.dal.dataobject.materialspropertyvalue.MaterialsPropertyValueDO;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import org.apache.ibatis.annotations.Mapper;
-import cn.iocoder.yudao.module.iscs.controller.admin.materialspropertyvalue.vo.*;
+import org.apache.ibatis.annotations.Param;
 
 /**
  * 物资属性值 Mapper
@@ -27,4 +28,6 @@ public interface MaterialsPropertyValueMapper extends BaseMapperX<MaterialsPrope
                 .orderByDesc(MaterialsPropertyValueDO::getId));
     }
 
-}
+    Page<MaterialsPropertyValueRespVO> getMaterialsPropertyValuePage(Page<MaterialsPropertyValueDO> page, @Param(value = "vo") MaterialsPropertyValuePageReqVO vo);
+
+}

+ 65 - 63
yudao-module-iscs/src/main/java/cn/iocoder/yudao/module/iscs/service/materialspropertyvalue/MaterialsPropertyValueService.java

@@ -1,63 +1,65 @@
-package cn.iocoder.yudao.module.iscs.service.materialspropertyvalue;
-
-import java.util.*;
-import jakarta.validation.*;
-import cn.iocoder.yudao.module.iscs.controller.admin.materialspropertyvalue.vo.*;
-import cn.iocoder.yudao.module.iscs.dal.dataobject.materialspropertyvalue.MaterialsPropertyValueDO;
-import cn.iocoder.yudao.framework.common.pojo.PageResult;
-import cn.iocoder.yudao.framework.common.pojo.PageParam;
-import com.baomidou.mybatisplus.extension.service.IService;
-
-/**
- * 物资属性值 Service 接口
- *
- * @author 芋道源码
- */
-public interface MaterialsPropertyValueService extends IService<MaterialsPropertyValueDO> {
-
-    /**
-     * 创建物资属性值
-     *
-     * @param createReqVO 创建信息
-     * @return 编号
-     */
-    Long createMaterialsPropertyValue(@Valid MaterialsPropertyValueSaveReqVO createReqVO);
-
-    /**
-     * 更新物资属性值
-     *
-     * @param updateReqVO 更新信息
-     */
-    void updateMaterialsPropertyValue(@Valid MaterialsPropertyValueSaveReqVO updateReqVO);
-
-    /**
-     * 删除物资属性值
-     *
-     * @param id 编号
-     */
-    void deleteMaterialsPropertyValue(Long id);
-
-    /**
-    * 批量删除物资属性值
-    *
-    * @param ids 编号
-    */
-    void deleteMaterialsPropertyValueListByIds(List<Long> ids);
-
-    /**
-     * 获得物资属性值
-     *
-     * @param id 编号
-     * @return 物资属性值
-     */
-    MaterialsPropertyValueDO getMaterialsPropertyValue(Long id);
-
-    /**
-     * 获得物资属性值分页
-     *
-     * @param pageReqVO 分页查询
-     * @return 物资属性值分页
-     */
-    PageResult<MaterialsPropertyValueDO> getMaterialsPropertyValuePage(MaterialsPropertyValuePageReqVO pageReqVO);
-
-}
+package cn.iocoder.yudao.module.iscs.service.materialspropertyvalue;
+
+import cn.iocoder.yudao.framework.common.pojo.PageResult;
+import cn.iocoder.yudao.module.iscs.controller.admin.materialspropertyvalue.vo.MaterialsPropertyValuePageReqVO;
+import cn.iocoder.yudao.module.iscs.controller.admin.materialspropertyvalue.vo.MaterialsPropertyValueRespVO;
+import cn.iocoder.yudao.module.iscs.controller.admin.materialspropertyvalue.vo.MaterialsPropertyValueSaveReqVO;
+import cn.iocoder.yudao.module.iscs.dal.dataobject.materialspropertyvalue.MaterialsPropertyValueDO;
+import com.baomidou.mybatisplus.extension.service.IService;
+import jakarta.validation.Valid;
+
+import java.util.List;
+
+/**
+ * 物资属性值 Service 接口
+ *
+ * @author 芋道源码
+ */
+public interface MaterialsPropertyValueService extends IService<MaterialsPropertyValueDO> {
+
+    /**
+     * 创建物资属性值
+     *
+     * @param createReqVO 创建信息
+     * @return 编号
+     */
+    Long createMaterialsPropertyValue(@Valid MaterialsPropertyValueSaveReqVO createReqVO);
+
+    /**
+     * 更新物资属性值
+     *
+     * @param updateReqVO 更新信息
+     */
+    void updateMaterialsPropertyValue(@Valid MaterialsPropertyValueSaveReqVO updateReqVO);
+
+    /**
+     * 删除物资属性值
+     *
+     * @param id 编号
+     */
+    void deleteMaterialsPropertyValue(Long id);
+
+    /**
+    * 批量删除物资属性值
+    *
+    * @param ids 编号
+    */
+    void deleteMaterialsPropertyValueListByIds(List<Long> ids);
+
+    /**
+     * 获得物资属性值
+     *
+     * @param id 编号
+     * @return 物资属性值
+     */
+    MaterialsPropertyValueDO getMaterialsPropertyValue(Long id);
+
+    /**
+     * 获得物资属性值分页
+     *
+     * @param pageReqVO 分页查询
+     * @return 物资属性值分页
+     */
+    PageResult<MaterialsPropertyValueRespVO> getMaterialsPropertyValuePage(MaterialsPropertyValuePageReqVO pageReqVO);
+
+}

+ 20 - 11
yudao-module-iscs/src/main/java/cn/iocoder/yudao/module/iscs/service/materialspropertyvalue/MaterialsPropertyValueServiceImpl.java

@@ -1,12 +1,15 @@
 package cn.iocoder.yudao.module.iscs.service.materialspropertyvalue;
 
-import cn.hutool.core.collection.CollUtil;
+import cn.hutool.core.lang.Assert;
 import cn.iocoder.yudao.framework.common.pojo.PageResult;
 import cn.iocoder.yudao.framework.common.util.object.BeanUtils;
 import cn.iocoder.yudao.module.iscs.controller.admin.materialspropertyvalue.vo.MaterialsPropertyValuePageReqVO;
+import cn.iocoder.yudao.module.iscs.controller.admin.materialspropertyvalue.vo.MaterialsPropertyValueRespVO;
 import cn.iocoder.yudao.module.iscs.controller.admin.materialspropertyvalue.vo.MaterialsPropertyValueSaveReqVO;
 import cn.iocoder.yudao.module.iscs.dal.dataobject.materialspropertyvalue.MaterialsPropertyValueDO;
 import cn.iocoder.yudao.module.iscs.dal.mysql.materialspropertyvalue.MaterialsPropertyValueMapper;
+import com.baomidou.mybatisplus.core.toolkit.Wrappers;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import jakarta.annotation.Resource;
 import org.springframework.stereotype.Service;
@@ -28,6 +31,10 @@ public class MaterialsPropertyValueServiceImpl extends ServiceImpl<MaterialsProp
 
     @Override
     public Long createMaterialsPropertyValue(MaterialsPropertyValueSaveReqVO createReqVO) {
+        List<MaterialsPropertyValueDO> list = list(Wrappers.<MaterialsPropertyValueDO>lambdaQuery()
+                .eq(MaterialsPropertyValueDO::getPropertyId, createReqVO.getPropertyId())
+                .eq(MaterialsPropertyValueDO::getValueName, createReqVO.getValueName()));
+        Assert.isTrue(list.isEmpty(), "该名称已被使用!");
         // 插入
         MaterialsPropertyValueDO materialsPropertyValue = BeanUtils.toBean(createReqVO, MaterialsPropertyValueDO.class);
         materialsPropertyValueMapper.insert(materialsPropertyValue);
@@ -38,6 +45,11 @@ public class MaterialsPropertyValueServiceImpl extends ServiceImpl<MaterialsProp
 
     @Override
     public void updateMaterialsPropertyValue(MaterialsPropertyValueSaveReqVO updateReqVO) {
+        List<MaterialsPropertyValueDO> list = list(Wrappers.<MaterialsPropertyValueDO>lambdaQuery()
+                .eq(MaterialsPropertyValueDO::getPropertyId, updateReqVO.getPropertyId())
+                .eq(MaterialsPropertyValueDO::getValueName, updateReqVO.getValueName())
+                .ne(MaterialsPropertyValueDO::getId, updateReqVO.getId()));
+        Assert.isTrue(list.isEmpty(), "该名称已被使用!");
         // 校验存在
         validateMaterialsPropertyValueExists(updateReqVO.getId());
         // 更新
@@ -55,18 +67,10 @@ public class MaterialsPropertyValueServiceImpl extends ServiceImpl<MaterialsProp
 
     @Override
         public void deleteMaterialsPropertyValueListByIds(List<Long> ids) {
-        // 校验存在
-        validateMaterialsPropertyValueExists(ids);
         // 删除
         materialsPropertyValueMapper.deleteByIds(ids);
         }
 
-    private void validateMaterialsPropertyValueExists(List<Long> ids) {
-        List<MaterialsPropertyValueDO> list = materialsPropertyValueMapper.selectByIds(ids);
-        if (CollUtil.isEmpty(list) || list.size() != ids.size()) {
-            /// throw exception(MATERIALS_PROPERTY_VALUE_NOT_EXISTS);
-        }
-    }
 
     private void validateMaterialsPropertyValueExists(Long id) {
         if (materialsPropertyValueMapper.selectById(id) == null) {
@@ -80,8 +84,13 @@ public class MaterialsPropertyValueServiceImpl extends ServiceImpl<MaterialsProp
     }
 
     @Override
-    public PageResult<MaterialsPropertyValueDO> getMaterialsPropertyValuePage(MaterialsPropertyValuePageReqVO pageReqVO) {
-        return materialsPropertyValueMapper.selectPage(pageReqVO);
+    public PageResult<MaterialsPropertyValueRespVO> getMaterialsPropertyValuePage(MaterialsPropertyValuePageReqVO pageReqVO) {
+        Page<MaterialsPropertyValueDO> page = new Page<MaterialsPropertyValueDO>().setCurrent(pageReqVO.getPageNo()).setSize(pageReqVO.getPageSize());
+        Page<MaterialsPropertyValueRespVO> pageResult = materialsPropertyValueMapper.getMaterialsPropertyValuePage(page, pageReqVO);
+        PageResult<MaterialsPropertyValueRespVO> respVOPageResult = new PageResult<>();
+        respVOPageResult.setList(pageResult.getRecords());
+        respVOPageResult.setTotal(pageResult.getTotal());
+        return respVOPageResult;
     }
 
 }

+ 14 - 1
yudao-module-iscs/src/main/resources/mapper/MaterialsPropertyValueMapper.xml

@@ -9,4 +9,17 @@
         文档可见:https://www.iocoder.cn/MyBatis/x-plugins/
      -->
 
-</mapper>
+    <select id="getMaterialsPropertyValuePage"
+            resultType="cn.iocoder.yudao.module.iscs.controller.admin.materialspropertyvalue.vo.MaterialsPropertyValueRespVO">
+        select v.*, p.property_name from isc_materials_property_value v
+        left join isc_materials_property p on v.property_id = p.property_id
+        <where>
+            <if test="vo.valueName != null and vo.valueName.trim != ''">
+                and v.value_name like concat('%',#{vo.valueName},'%')
+            </if>
+            <if test="vo.propertyId != null">
+                and v.property_id = #{vo.propertyId}
+            </if>
+        </where>
+    </select>
+</mapper>