fix(用例管理): 修复导入用例等级值为空校验失败问题

--bug=1045294 --user=郭雨琦 https://www.tapd.cn/55049933/bugtrace/bugs/view/1155049933001045294
This commit is contained in:
guoyuqi 2024-08-22 09:53:14 +08:00 committed by Craftsman
parent 3dc9184cb6
commit d02b153dea
1 changed files with 3 additions and 0 deletions

View File

@ -43,6 +43,9 @@ public abstract class AbstractCustomFieldValidator {
protected void validateRequired(TemplateCustomFieldDTO customField, String value) throws CustomFieldValidateException { protected void validateRequired(TemplateCustomFieldDTO customField, String value) throws CustomFieldValidateException {
if (customField.getRequired() && StringUtils.isBlank(value)) { if (customField.getRequired() && StringUtils.isBlank(value)) {
if (StringUtils.equalsIgnoreCase(customField.getInternalFieldKey(),"functional_priority")) {
return;
}
CustomFieldValidateException.throwException(String.format(Translator.get("custom_field_required_tip"), customField.getFieldName())); CustomFieldValidateException.throwException(String.format(Translator.get("custom_field_required_tip"), customField.getFieldName()));
} }
} }