fix: 解决编辑进程守护名称/进程数量报错的问题 (#3260)

This commit is contained in:
zhengkunwang 2023-12-11 13:10:06 +08:00 committed by GitHub
parent 2aea2d3dfe
commit 73d41675a0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 8 deletions

View file

@ -80,12 +80,10 @@
<template #main>
<el-alert type="info" :closable="false" v-if="mode === 'installed'">
<template #default>
<span>
<span>{{ $t('app.installHelper') }}</span>
<el-link class="text-xs scroll-ml-1" icon="Position" @click="quickJump()" type="primary">
{{ $t('firewall.quickJump') }}
</el-link>
</span>
{{ $t('app.installHelper') }}
<el-link class="ml-5" icon="Position" @click="quickJump()" type="primary">
{{ $t('firewall.quickJump') }}
</el-link>
</template>
</el-alert>
<el-alert type="info" :title="$t('app.upgradeHelper')" :closable="false" v-if="mode === 'upgrade'" />

View file

@ -10,7 +10,7 @@
<el-col :span="22" :offset="1">
<el-form ref="processForm" label-position="top" :model="process" label-width="100px" :rules="rules">
<el-form-item :label="$t('commons.table.name')" prop="name">
<el-input v-model.trim="process.name" :disabled="process.operate == 'edit'"></el-input>
<el-input v-model.trim="process.name" :disabled="process.operate == 'update'"></el-input>
</el-form-item>
<el-form-item :label="$t('tool.supervisor.user')" prop="user">
<el-input v-model.trim="process.user"></el-input>
@ -58,7 +58,7 @@ const rules = ref({
dir: [Rules.requiredInput],
command: [Rules.requiredInput],
user: [Rules.requiredInput],
numprocsNum: [Rules.requiredInput, checkNumberRange(1, 9999)],
numprocsNum: [Rules.requiredInput, Rules.integerNumber, checkNumberRange(1, 9999)],
});
const initData = () => ({
operate: 'create',