PXY管控添加重定向功能
This commit is contained in:
@@ -31,10 +31,15 @@ public class BaseCfg<T> extends BaseEntity<T> implements Cloneable{
|
||||
protected String showName;//表在界面上展示的名称
|
||||
protected String seltype;//选中类型,页面搜索用
|
||||
protected String tableName;
|
||||
@ExcelField(title="userregion1")
|
||||
protected String userRegion1;
|
||||
@ExcelField(title="userregion2")
|
||||
protected String userRegion2;
|
||||
@ExcelField(title="userregion3")
|
||||
protected String userRegion3;
|
||||
@ExcelField(title="userregion4")
|
||||
protected String userRegion4;
|
||||
@ExcelField(title="userregion5")
|
||||
protected String userRegion5;
|
||||
/**
|
||||
* 编译id
|
||||
|
||||
@@ -47,7 +47,82 @@ public class IpCfgTemplate {
|
||||
private Integer ratelimit;//21
|
||||
private Integer dnsStrategyId;//22
|
||||
private Integer irType;//23
|
||||
private String userRegion1;//77
|
||||
private String userRegion2;//78
|
||||
private String userRegion3;//79
|
||||
private String userRegion4;//80
|
||||
private String userRegion5;//81
|
||||
|
||||
/**
|
||||
* userRegion1
|
||||
* @return userRegion1
|
||||
*/
|
||||
@ExcelField(title="userregion1",align=2,sort=77)
|
||||
public String getUserRegion1() {
|
||||
return userRegion1;
|
||||
}
|
||||
/**
|
||||
* @param userRegion1 the userRegion1 to set
|
||||
*/
|
||||
public void setUserRegion1(String userRegion1) {
|
||||
this.userRegion1 = userRegion1;
|
||||
}
|
||||
/**
|
||||
* userRegion2
|
||||
* @return userRegion2
|
||||
*/
|
||||
@ExcelField(title="userregion2",align=2,sort=78)
|
||||
public String getUserRegion2() {
|
||||
return userRegion2;
|
||||
}
|
||||
/**
|
||||
* @param userRegion2 the userRegion2 to set
|
||||
*/
|
||||
public void setUserRegion2(String userRegion2) {
|
||||
this.userRegion2 = userRegion2;
|
||||
}
|
||||
/**
|
||||
* userRegion3
|
||||
* @return userRegion3
|
||||
*/
|
||||
@ExcelField(title="userregion3",align=2,sort=79)
|
||||
public String getUserRegion3() {
|
||||
return userRegion3;
|
||||
}
|
||||
/**
|
||||
* @param userRegion3 the userRegion3 to set
|
||||
*/
|
||||
public void setUserRegion3(String userRegion3) {
|
||||
this.userRegion3 = userRegion3;
|
||||
}
|
||||
/**
|
||||
* userRegion4
|
||||
* @return userRegion4
|
||||
*/
|
||||
@ExcelField(title="userregion4",align=2,sort=80)
|
||||
public String getUserRegion4() {
|
||||
return userRegion4;
|
||||
}
|
||||
/**
|
||||
* @param userRegion4 the userRegion4 to set
|
||||
*/
|
||||
public void setUserRegion4(String userRegion4) {
|
||||
this.userRegion4 = userRegion4;
|
||||
}
|
||||
/**
|
||||
* userRegion5
|
||||
* @return userRegion5
|
||||
*/
|
||||
@ExcelField(title="userregion5",align=2,sort=81)
|
||||
public String getUserRegion5() {
|
||||
return userRegion5;
|
||||
}
|
||||
/**
|
||||
* @param userRegion5 the userRegion5 to set
|
||||
*/
|
||||
public void setUserRegion5(String userRegion5) {
|
||||
this.userRegion5 = userRegion5;
|
||||
}
|
||||
/**
|
||||
* ratelimit
|
||||
* @return ratelimit
|
||||
|
||||
@@ -37,6 +37,11 @@
|
||||
<result column="ratelimit" property="ratelimit" jdbcType="INTEGER" />
|
||||
<result column="dns_strategy_id" property="dnsStrategyId" jdbcType="INTEGER" />
|
||||
<result column="ir_type" property="irType" jdbcType="INTEGER" />
|
||||
<result column="user_region1" property="userRegion1" jdbcType="VARCHAR" />
|
||||
<result column="user_region2" property="userRegion2" jdbcType="VARCHAR" />
|
||||
<result column="user_region3" property="userRegion3" jdbcType="VARCHAR" />
|
||||
<result column="user_region4" property="userRegion4" jdbcType="VARCHAR" />
|
||||
<result column="user_region5" property="userRegion5" jdbcType="VARCHAR" />
|
||||
</resultMap>
|
||||
<resultMap id="BaseIpMapWithUser" type="com.nis.domain.configuration.BaseIpCfg" extends="BaseIpMap" >
|
||||
<result column="creator_name" property="creatorName" jdbcType="VARCHAR" />
|
||||
@@ -50,14 +55,14 @@
|
||||
DIRECTION,PROTOCOL,PROTOCOL_ID,ACTION,IS_VALID,IS_AUDIT,
|
||||
CREATOR_ID,CREATE_TIME,EDITOR_ID,EDIT_TIME,AUDITOR_ID,AUDIT_TIME,
|
||||
SERVICE_ID,REQUEST_ID,COMPILE_ID,IS_AREA_EFFECTIVE,CLASSIFY,
|
||||
ATTRIBUTE,LABLE,AREA_EFFECTIVE_IDS,FUNCTION_ID,RATELIMIT,DNS_STRATEGY_ID,IR_TYPE
|
||||
ATTRIBUTE,LABLE,AREA_EFFECTIVE_IDS,FUNCTION_ID,RATELIMIT,DNS_STRATEGY_ID,IR_TYPE,USER_REGION1,USER_REGION2,USER_REGION3,USER_REGION4,USER_REGION5
|
||||
</sql>
|
||||
<sql id="BaseIpCfg_Column_List_with_id_name" >
|
||||
CFG_ID, CFG_DESC,CFG_REGION_CODE,CFG_TYPE, IP_TYPE, IP_PATTERN, SRC_IP_ADDRESS,DEST_IP_ADDRESS, PORT_PATTERN,SRC_PORT,DEST_PORT,
|
||||
DIRECTION,PROTOCOL,PROTOCOL_ID,ACTION,IS_VALID,IS_AUDIT,
|
||||
CREATOR_ID,CREATE_TIME,EDITOR_ID,EDIT_TIME,AUDITOR_ID,AUDIT_TIME,
|
||||
SERVICE_ID,REQUEST_ID,COMPILE_ID,IS_AREA_EFFECTIVE,CLASSIFY,
|
||||
ATTRIBUTE,LABLE,AREA_EFFECTIVE_IDS,FUNCTION_ID,RATELIMIT,DNS_STRATEGY_ID,IR_TYPE
|
||||
ATTRIBUTE,LABLE,AREA_EFFECTIVE_IDS,FUNCTION_ID,RATELIMIT,DNS_STRATEGY_ID,IR_TYPE,USER_REGION1,USER_REGION2,USER_REGION3,USER_REGION4,USER_REGION5
|
||||
</sql>
|
||||
<sql id="BaseIpCfg_Column_List_with_id_alias" >
|
||||
<choose>
|
||||
@@ -68,7 +73,12 @@
|
||||
${page.alias}.CREATOR_ID as creatorId,${page.alias}.CREATE_TIME AS createTime,${page.alias}.EDITOR_ID as editorId,${page.alias}.EDIT_TIME AS editTime,${page.alias}.AUDITOR_ID as auditorId,${page.alias}.AUDIT_TIME AS auditTime,
|
||||
${page.alias}.SERVICE_ID as serviceId,${page.alias}.REQUEST_ID AS requestId,${page.alias}.COMPILE_ID AS compileId,${page.alias}.IS_AREA_EFFECTIVE as isAreaEffective,${page.alias}.classify,
|
||||
${page.alias}.ATTRIBUTE AS attribute,${page.alias}.LABLE AS lable,${page.alias}.AREA_EFFECTIVE_IDS AS areaEffectiveIds,${page.alias}.FUNCTION_ID AS functionId,${page.alias}.RATELIMIT AS ratelimit,
|
||||
${page.alias}.DNS_STRATEGY_ID AS dnsStrategyId,${page.alias}.IR_TYPE AS irType
|
||||
${page.alias}.DNS_STRATEGY_ID AS dnsStrategyId,${page.alias}.IR_TYPE AS irType,
|
||||
${page.alias}.USER_REGION1 AS userRegion1,
|
||||
${page.alias}.USER_REGION2 AS userRegion2,
|
||||
${page.alias}.USER_REGION3 AS userRegion3,
|
||||
${page.alias}.USER_REGION4 AS userRegion4,
|
||||
${page.alias}.USER_REGION5 AS userRegion5
|
||||
</when>
|
||||
<otherwise>
|
||||
r.CFG_ID as cfgId, r.CFG_DESC as cfgDesc,r.CFG_REGION_CODE as cfgRegionCode,r.CFG_TYPE as cfgType, r.IP_TYPE as ipType,
|
||||
@@ -77,7 +87,12 @@
|
||||
r.CREATOR_ID as creatorId,r.CREATE_TIME AS createTime,r.EDITOR_ID as editorId,r.EDIT_TIME AS editTime,r.AUDITOR_ID as auditorId,r.AUDIT_TIME AS auditTime,
|
||||
r.SERVICE_ID as serviceId,r.REQUEST_ID AS requestId,r.COMPILE_ID AS compileId,r.IS_AREA_EFFECTIVE as isAreaEffective,r.classify,
|
||||
r.ATTRIBUTE AS attribute,r.LABLE AS lable,r.AREA_EFFECTIVE_IDS AS areaEffectiveIds,r.FUNCTION_ID as functionId,r.RATELIMIT AS ratelimit,
|
||||
r.DNS_STRATEGY_ID AS dnsStrategyId,r.IR_TYPE AS irType
|
||||
r.DNS_STRATEGY_ID AS dnsStrategyId,r.IR_TYPE AS irType,
|
||||
r.USER_REGION1 AS userRegion1,
|
||||
r.USER_REGION2 AS userRegion2,
|
||||
r.USER_REGION3 AS userRegion3,
|
||||
r.USER_REGION4 AS userRegion4,
|
||||
r.USER_REGION5 AS userRegion5
|
||||
</otherwise>
|
||||
</choose>
|
||||
</sql>
|
||||
@@ -92,7 +107,7 @@
|
||||
REQUEST_ID,COMPILE_ID,IS_AREA_EFFECTIVE,
|
||||
CLASSIFY,ATTRIBUTE,LABLE,
|
||||
AREA_EFFECTIVE_IDS,FUNCTION_ID,RATELIMIT,
|
||||
DNS_STRATEGY_ID,IR_TYPE
|
||||
DNS_STRATEGY_ID,IR_TYPE,USER_REGION1,USER_REGION2,USER_REGION3,USER_REGION4,USER_REGION5
|
||||
</sql>
|
||||
<sql id="BaseIpCfg_Value_List" >
|
||||
#{cfgDesc,jdbcType=VARCHAR},#{cfgRegionCode,jdbcType=INTEGER},#{cfgType,jdbcType=VARCHAR},
|
||||
@@ -105,7 +120,12 @@
|
||||
#{requestId,jdbcType=INTEGER},#{compileId,jdbcType=INTEGER},#{isAreaEffective,jdbcType=INTEGER},
|
||||
#{classify,jdbcType=VARCHAR},#{attribute,jdbcType=VARCHAR},#{lable,jdbcType=VARCHAR},
|
||||
#{areaEffectiveIds,jdbcType=VARCHAR}, #{functionId,jdbcType=INTEGER}, #{ratelimit,jdbcType=INTEGER},
|
||||
#{dnsStrategyId,jdbcType=INTEGER},#{irType,jdbcType=INTEGER}
|
||||
#{dnsStrategyId,jdbcType=INTEGER},#{irType,jdbcType=INTEGER},
|
||||
#{userRegion1,jdbcType=VARCHAR},
|
||||
#{userRegion2,jdbcType=VARCHAR},
|
||||
#{userRegion3,jdbcType=VARCHAR},
|
||||
#{userRegion4,jdbcType=VARCHAR},
|
||||
#{userRegion5,jdbcType=VARCHAR}
|
||||
</sql>
|
||||
<select id="getById" resultMap="BaseIpMap" parameterType="java.lang.Long" >
|
||||
SELECT
|
||||
@@ -282,6 +302,21 @@
|
||||
<if test="irType != null">
|
||||
AND ${page.alias}.IR_TYPE=#{irType,jdbcType=INTEGER}
|
||||
</if>
|
||||
<if test="userRegion1 != null">
|
||||
AND ${page.alias}.USER_REGION1=#{userRegion1,jdbcType=VARCHAR}
|
||||
</if>
|
||||
<if test="userRegion2 != null">
|
||||
AND ${page.alias}.USER_REGION2=#{userRegion2,jdbcType=VARCHAR}
|
||||
</if>
|
||||
<if test="userRegion3 != null">
|
||||
AND ${page.alias}.USER_REGION3=#{userRegion3,jdbcType=VARCHAR}
|
||||
</if>
|
||||
<if test="userRegion4 != null">
|
||||
AND ${page.alias}.USER_REGION4=#{userRegion4,jdbcType=VARCHAR}
|
||||
</if>
|
||||
<if test="userRegion5 != null">
|
||||
AND ${page.alias}.USER_REGION5=#{userRegion5,jdbcType=VARCHAR}
|
||||
</if>
|
||||
</when>
|
||||
<otherwise>
|
||||
<if test="cfgId != null">
|
||||
@@ -392,6 +427,21 @@
|
||||
<if test="irType != null">
|
||||
AND r.IR_TYPE=#{irType,jdbcType=INTEGER}
|
||||
</if>
|
||||
<if test="userRegion1 != null">
|
||||
AND r.USER_REGION1=#{userRegion1,jdbcType=VARCHAR}
|
||||
</if>
|
||||
<if test="userRegion2 != null">
|
||||
AND r.USER_REGION2=#{userRegion2,jdbcType=VARCHAR}
|
||||
</if>
|
||||
<if test="userRegion3 != null">
|
||||
AND r.USER_REGION3=#{userRegion3,jdbcType=VARCHAR}
|
||||
</if>
|
||||
<if test="userRegion4 != null">
|
||||
AND r.USER_REGION4=#{userRegion4,jdbcType=VARCHAR}
|
||||
</if>
|
||||
<if test="userRegion5 != null">
|
||||
AND r.USER_REGION5=#{userRegion5,jdbcType=VARCHAR}
|
||||
</if>
|
||||
</otherwise>
|
||||
</choose>
|
||||
<!-- 数据范围过滤 -->
|
||||
@@ -547,6 +597,21 @@
|
||||
<if test="irType != null">
|
||||
IR_TYPE=#{irType,jdbcType=INTEGER},
|
||||
</if>
|
||||
<if test="userRegion1 != null">
|
||||
USER_REGION1=#{userRegion1,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="userRegion2 != null">
|
||||
USER_REGION2=#{userRegion2,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="userRegion3 != null">
|
||||
USER_REGION3=#{userRegion3,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="userRegion4 != null">
|
||||
USER_REGION4=#{userRegion4,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="userRegion5 != null">
|
||||
USER_REGION5=#{userRegion5,jdbcType=VARCHAR},
|
||||
</if>
|
||||
</trim>
|
||||
</set>
|
||||
where cfg_id = #{cfgId,jdbcType=BIGINT}
|
||||
@@ -595,7 +660,7 @@
|
||||
r.CREATOR_ID as creatorId,r.CREATE_TIME AS createTime,r.EDITOR_ID as editorId,r.EDIT_TIME AS editTime,r.AUDITOR_ID as auditorId,r.AUDIT_TIME AS auditTime,
|
||||
r.SERVICE_ID as serviceId,r.REQUEST_ID AS requestId,r.COMPILE_ID AS compileId,r.IS_AREA_EFFECTIVE as isAreaEffective,r.classify,
|
||||
r.ATTRIBUTE AS attribute,r.LABLE AS lable,r.AREA_EFFECTIVE_IDS AS areaEffectiveIds,r.FUNCTION_ID as functionId,r.RATELIMIT AS ratelimit,
|
||||
r.DNS_STRATEGY_ID AS dnsStrategyId,r.IR_TYPE AS irType
|
||||
r.DNS_STRATEGY_ID AS dnsStrategyId,r.IR_TYPE AS irType,r.USER_REGION1 AS userRegion1,r.USER_REGION2 AS userRegion2,r.USER_REGION3 AS userRegion3,r.USER_REGION4 AS userRegion4,r.USER_REGION5 AS userRegion5
|
||||
, s.name as creator_name,e.name as editor_name,u.name as auditor_name
|
||||
,ri.request_title as requestName,po.group_name as group_name
|
||||
from ${tableName} r
|
||||
|
||||
Reference in New Issue
Block a user