feiyu02
2026-01-19 53ce8de426561e7a43847afda23b5e24e6f76c4e
src/main/kotlin/cn/flightfeather/supervision/lightshare/service/Impl/UserinfoServiceImpl.kt
@@ -303,7 +303,7 @@
        val districtName = condition.districtName ?: user?.extension1
        val p = PageHelper.startPage<Userinfo>(page, perPage)
        val result = userinfoMapper.selectByExample(Example(Userinfo::class.java).apply {
        val userInfoList = userinfoMapper.selectByExample(Example(Userinfo::class.java).apply {
            if (condition.searchText?.isNotBlank() == true) {
                and(createCriteria()
                    .orLike("acountname", "%${condition.searchText}%")
@@ -321,8 +321,13 @@
                .andEqualTo("isenable", true).apply {
                    condition.userTypeId?.let { andEqualTo("usertypeid", it) }
                })
            //todo 2020.8.19 街镇的条件查询需要扩充BaseInfo数据表字段后再实现
        })
        //2025.11.28 通过BaseInfo表中的biTownCode字段来筛选出符合条件的用户
        val baseInfoList = baseInfoMapper.selectByExample(Example(BaseInfo::class.java).apply {
            createCriteria().andIn("biGuid", userInfoList.map { it?.guid })
        }).filter { it.biTownCode == condition.townCode }
        val result = userInfoList.filter { u-> baseInfoList.any { b-> b.biGuid == u?.guid } }
        response.setIntHeader("totalPage", p.pages)
        response.setIntHeader("currentPage", p.pageNum)