fix: MML管理文件类型判断

This commit is contained in:
TsMask
2024-03-04 17:58:00 +08:00
parent bd13b70a88
commit 49fa7bdec8
5 changed files with 99 additions and 27 deletions

View File

@@ -314,6 +314,15 @@ function ruleVerification(
}
}
break;
case 'file':
if (filter) {
const arr: string[] = filter.split(',');
const itemArr = arr.filter(item => value.endsWith(item));
if (itemArr.length === 0) {
return [false, t('views.mmlManage.requireFile', { display })];
}
}
break;
default:
console.warn(t('views.mmlManage.requireUn', { display }), type);
@@ -642,7 +651,10 @@ onMounted(() => {
:validate-on-rule-change="false"
:validateTrigger="[]"
>
<a-form-item :label="t('views.mmlManage.cmdQuickEntry')">
<a-form-item
:label="t('views.mmlManage.cmdQuickEntry')"
:help="t('views.mmlManage.cmdQuickEntryHelp')"
>
<!-- 非UPF通用4100 -->
<a-auto-complete
v-if="state.neType[0] !== 'UPF'"