feiyu02
2024-01-10 30a53b41f09d2eefd33513a409d472c2166ba1ea
src/main/kotlin/cn/flightfeather/supervision/domain/ds2/repository/UserInfoTZRep.kt
@@ -17,8 +17,16 @@
     */
    fun findEnterpriseUser(district: String?, sceneType: Constant.SceneType): List<UserinfoTZ?> {
        val type = Constant.SceneType.typeMap(sceneType.value.toByte())
        return findEnterpriseUser(district, type?.toInt())
    }
    /**
     * 查找在线的正式企业用户
     * @param sceneTypeTZ 飞羽环境系统中的场景类型
     */
    fun findEnterpriseUser(district: String?, sceneTypeTZ: Int?): List<UserinfoTZ?> {
        return userinfoTZMapper.selectByExample(Example(UserinfoTZ::class.java).apply {
            createCriteria().andEqualTo("extension2", type)
            createCriteria().andEqualTo("extension2", sceneTypeTZ)
                .andEqualTo("extension1", district)
                .andEqualTo("usertypeid", Constant.UserType.ENTERPRISE.value)
                .andEqualTo("isenable", true)