fix(测试跟踪): 多选导入用例时责任人id忽略大小写
--bug=1015896 --user=张勇 【测试跟踪】用户id是小写,导入用例时责任人id填写大写,导入失败 https://www.tapd.cn/55049933/s/1229922
This commit is contained in:
parent
4354f86c5e
commit
291d16943c
|
@ -32,7 +32,8 @@ public class CustomFieldMemberValidator extends AbstractCustomFieldValidator {
|
||||||
if (StringUtils.isBlank(value)) {
|
if (StringUtils.isBlank(value)) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (userIdMap.containsKey(value) || userNameMap.containsKey(value)) {
|
long count = userIdMap.entrySet().stream().filter(e -> StringUtils.equalsAnyIgnoreCase(value,e.getKey(),e.getValue())).count();
|
||||||
|
if(count > 0){
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
throw new CustomFieldValidateException(String.format(Translator.get("custom_field_member_tip"), customField.getName()));
|
throw new CustomFieldValidateException(String.format(Translator.get("custom_field_member_tip"), customField.getName()));
|
||||||
|
|
|
@ -18,10 +18,12 @@ public class CustomFieldMultipleMemberValidator extends CustomFieldMemberValidat
|
||||||
}
|
}
|
||||||
|
|
||||||
for (String item : parse2Array(customField.getName(), value)) {
|
for (String item : parse2Array(customField.getName(), value)) {
|
||||||
if (!userIdMap.containsKey(item) && !userNameMap.containsKey(item)) {
|
long count = userIdMap.entrySet().stream().filter(e -> StringUtils.equalsAnyIgnoreCase(item,e.getKey(),e.getValue())).count();
|
||||||
CustomFieldValidateException.throwException(String.format(Translator.get("custom_field_member_tip"), customField.getName()));
|
if(count > 0){
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
CustomFieldValidateException.throwException(String.format(Translator.get("custom_field_member_tip"), customField.getName()));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
Loading…
Reference in New Issue