资料中心类型条件查询修改
This commit is contained in:
+7
-3
@@ -88,10 +88,14 @@ public class FileMaterialServiceImpl extends ServiceImpl<FileMaterialDao, FileMa
|
|||||||
}
|
}
|
||||||
queryPage.setTreeIdList(treeIds);
|
queryPage.setTreeIdList(treeIds);
|
||||||
}
|
}
|
||||||
//dataType制空,不然节点重名会有bug
|
|
||||||
queryPage.setDataType(null);
|
|
||||||
queryPage.setTreeId(null);
|
queryPage.setTreeId(null);
|
||||||
return fileMaterialDao.getFileMaterialPage(page,queryPage);
|
IPage<FileMaterial> fileMaterialPage = fileMaterialDao.getFileMaterialPage(page, queryPage);
|
||||||
|
if (ObjectUtils.isNotEmpty(queryPage.getDataType())) {
|
||||||
|
List<FileMaterial> fileMaterials = fileMaterialPage.getRecords().stream().filter(fileMaterial -> fileMaterial.getDataType().equals(queryPage.getDataType())).collect(Collectors.toList());
|
||||||
|
fileMaterialPage.setRecords(fileMaterials);
|
||||||
|
fileMaterialPage.setTotal(fileMaterials.size());
|
||||||
|
}
|
||||||
|
return fileMaterialPage;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
-3
@@ -38,9 +38,6 @@
|
|||||||
<if test="flieM.id != null and flieM.id != ''">
|
<if test="flieM.id != null and flieM.id != ''">
|
||||||
and fm.id=#{flieM.id}
|
and fm.id=#{flieM.id}
|
||||||
</if>
|
</if>
|
||||||
<if test="flieM.dataType != null and flieM.dataType != ''">
|
|
||||||
AND fm.data_type like concat('%',#{flieM.dataType},'%')
|
|
||||||
</if>
|
|
||||||
<if test="flieM.dataTitle != null and flieM.dataTitle != ''">
|
<if test="flieM.dataTitle != null and flieM.dataTitle != ''">
|
||||||
AND fm.data_title like concat('%',#{flieM.dataTitle},'%')
|
AND fm.data_title like concat('%',#{flieM.dataTitle},'%')
|
||||||
</if>
|
</if>
|
||||||
|
|||||||
Reference in New Issue
Block a user