S/DNAT复用地址池配置属性修改.
This commit is contained in:
@@ -11,7 +11,9 @@ public interface GroupAreaDao extends CrudDao<GroupAreaInfo>{
|
||||
|
||||
List<GroupAreaInfo> findGroupAreaInfoList(GroupAreaInfo entity);
|
||||
|
||||
GroupAreaInfo getInfoById(int groupId);
|
||||
GroupAreaInfo getInfoById(int id);
|
||||
|
||||
Integer getAreaCodeByGroupId(Integer groupId);
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -72,7 +72,7 @@
|
||||
FROM
|
||||
group_area_info r
|
||||
WHERE
|
||||
r.id = #{Id}
|
||||
r.id = #{Id} AND is_valid = 1
|
||||
</select>
|
||||
|
||||
<insert id="insert" parameterType="com.nis.domain.configuration.GroupAreaInfo" >
|
||||
@@ -124,4 +124,13 @@
|
||||
</where>
|
||||
</update>
|
||||
|
||||
<!-- 获取该分组的区域信息 -->
|
||||
<select id="getAreaCodeByGroupId" resultType="java.lang.Integer">
|
||||
SELECT
|
||||
area_code
|
||||
FROM
|
||||
group_area_info
|
||||
WHERE
|
||||
group_id = #{groupId} AND is_valid = 1
|
||||
</select>
|
||||
</mapper>
|
||||
@@ -15,4 +15,8 @@ public interface IpMultiplexPoolCfgDao extends CrudDao<IpMultiplexPoolCfg> {
|
||||
,@Param("isAudit")Integer isAudit
|
||||
,@Param("isValid")Integer isValid);
|
||||
|
||||
IpMultiplexPoolCfg getCfgInfo(IpMultiplexPoolCfg cfg);
|
||||
|
||||
String getIspByGroupId(Integer groupId);
|
||||
|
||||
}
|
||||
@@ -304,5 +304,37 @@
|
||||
</if>
|
||||
</where>
|
||||
</update>
|
||||
|
||||
|
||||
<select id="getCfgInfo" parameterType="com.nis.domain.configuration.IpMultiplexPoolCfg" resultMap="IpMultiplexPoolCfgMap">
|
||||
SELECT
|
||||
<include refid="IpMultiplexPoolCfgColumns"/>
|
||||
FROM ip_multiplex_pool_cfg r
|
||||
<trim prefix="WHERE" prefixOverrides="AND |OR ">
|
||||
<if test="cfgId != null">
|
||||
AND r.CFG_ID=#{cfgId,jdbcType=BIGINT}
|
||||
</if>
|
||||
<if test="isValid !=null">
|
||||
AND r.is_valid =#{isValid,jdbcType=INTEGER}
|
||||
</if>
|
||||
<if test="isValid == null">
|
||||
AND r.IS_VALID != -1
|
||||
</if>
|
||||
<if test="functionId != null">
|
||||
AND r.function_id=#{functionId,jdbcType=INTEGER}
|
||||
</if>
|
||||
<if test="destIpAddress != null and destIpAddress!=''" >
|
||||
AND r.ip = #{destIpAddress,jdbcType=VARCHAR}
|
||||
</if>
|
||||
</trim>
|
||||
</select>
|
||||
|
||||
<select id="getIspByGroupId" resultType="java.lang.String">
|
||||
SELECT
|
||||
area_effective_ids
|
||||
FROM
|
||||
ip_multiplex_pool_cfg
|
||||
WHERE
|
||||
policy_group = #{groupId} AND is_valid != -1
|
||||
|
||||
</select>
|
||||
</mapper>
|
||||
Reference in New Issue
Block a user