Browse Source

天合备件台账需求新增

master
songguoqiang 6 months ago
parent
commit
96d4d7cee3
  1. 8
      win-module-eam/win-module-eam-biz/src/main/java/com/win/module/eam/controller/itemaccounts/vo/ItemAccountsPageReqVO.java
  2. 8
      win-module-eam/win-module-eam-biz/src/main/java/com/win/module/eam/dal/mysql/itemaccounts/ItemAccountsMapper.java

8
win-module-eam/win-module-eam-biz/src/main/java/com/win/module/eam/controller/itemaccounts/vo/ItemAccountsPageReqVO.java

@ -33,4 +33,12 @@ public class ItemAccountsPageReqVO extends PageParam {
@Schema(description = "项目号") @Schema(description = "项目号")
private String project; private String project;
@Schema(description = "备件名称")
private String itemName;
@Schema(description = "规格型号")
private String specifications;
} }

8
win-module-eam/win-module-eam-biz/src/main/java/com/win/module/eam/dal/mysql/itemaccounts/ItemAccountsMapper.java

@ -252,9 +252,15 @@ public interface ItemAccountsMapper extends BaseMapperX<ItemAccountsDO> {
.eqIfPresent(ItemAccountsDO::getType, reqVO.getType()) .eqIfPresent(ItemAccountsDO::getType, reqVO.getType())
.eqIfPresent(ItemAccountsDO::getAvailable, reqVO.getAvailable()) .eqIfPresent(ItemAccountsDO::getAvailable, reqVO.getAvailable())
.orderByDesc(ItemAccountsDO::getId); .orderByDesc(ItemAccountsDO::getId);
if(reqVO.getProject()!=null&& !reqVO.getProject().isEmpty()){ if(reqVO.getProject()!=null&& !reqVO.getProject().isEmpty()){//项目号模糊查询
itemAccountsDOLambdaQueryWrapper.inSql(ItemAccountsDO::getItemNumber, "select number from basic_item where available = 'TRUE' and deleted = 0 and project like CONCAT('%','" + reqVO.getProject() + "','%') "); itemAccountsDOLambdaQueryWrapper.inSql(ItemAccountsDO::getItemNumber, "select number from basic_item where available = 'TRUE' and deleted = 0 and project like CONCAT('%','" + reqVO.getProject() + "','%') ");
} }
if(reqVO.getItemName()!=null&& !reqVO.getItemName().isEmpty()){//备件名称
itemAccountsDOLambdaQueryWrapper.inSql(ItemAccountsDO::getItemNumber, "select number from basic_item where available = 'TRUE' and deleted = 0 and name like CONCAT('%','" + reqVO.getItemName() + "','%') ");
}
if(reqVO.getSpecifications()!=null&& !reqVO.getSpecifications().isEmpty()){//备件名称
itemAccountsDOLambdaQueryWrapper.inSql(ItemAccountsDO::getItemNumber, "select number from basic_item where available = 'TRUE' and deleted = 0 and specifications like CONCAT('%','" + reqVO.getSpecifications() + "','%') ");
}
return selectPage(reqVO, itemAccountsDOLambdaQueryWrapper); return selectPage(reqVO, itemAccountsDOLambdaQueryWrapper);
} }

Loading…
Cancel
Save