调整策略拼接适应主动策略部分,主动策略部分为添加功能端验证尝试中
This commit is contained in:
@@ -166,7 +166,8 @@ DeletePolicyAndObject
|
||||
END
|
||||
#删除对象
|
||||
log todeleteobj_DeletePolicyAndObject
|
||||
DeleteObject ${objectids}
|
||||
Run Keyword If "${objectids}"=="${EMPTY}" log no obj to del
|
||||
... ELSE DeleteObject ${objectids}
|
||||
|
||||
DeleteAfterCase
|
||||
[Arguments] ${policyids} ${objectids}
|
||||
|
||||
@@ -72,13 +72,17 @@ PolicyParamsOpertion
|
||||
Set To Dictionary ${policyList} userRegion=${Default_UserRegion}
|
||||
${userRegion} Run Keyword If "${return}"=="FAIL" or '${userRegion}'=="${EMPTY}" Set Variable ""
|
||||
... ELSE Set Variable ${userRegion}
|
||||
|
||||
#针对主动防御特殊处理,主动防御不应用对象
|
||||
${active_defence_emptyList} Create List
|
||||
${return} ${policyType} Run Keyword And Ignore Error Set Variable ${policyList}[policyType]
|
||||
Run Keyword If "${policyType}"=="active_defence" Set To Dictionary ${policyList} referenceObject=${active_defence_emptyList}
|
||||
Run Keyword If "${policyType}"=="active_defence" Set To Dictionary ${policyList} appObjectIdArray=${active_defence_emptyList}
|
||||
# 转为json结构并返回
|
||||
${dict} Create Dictionary opAction=add returnData=${returnData} policyList=${policyList}
|
||||
${json} json.Dumps ${dict} ensure_ascii=False
|
||||
${json} Replace String ${json} "method:rst" ${userRegion}
|
||||
#${json} Evaluate ${userRegion}.replace('"method"','${userRegion}')
|
||||
#${json} Replace String ${json} "' {
|
||||
#${json} Replace String ${json} \" "
|
||||
|
||||
Log Policy_Request_Body-${json}
|
||||
[Return] ${json}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user