职工福利-福利选择:修复总积分为0时计数插件点击加号失效(不能修改值);

This commit is contained in:
dd3s_206
2026-06-02 20:12:11 +08:00
parent 620a327c15
commit cd34b75c7e
2 changed files with 6 additions and 2 deletions
@@ -109,7 +109,7 @@
header-align="center" header-align="center"
v-if="is_integral_mode" label="所需积分" width="150"> v-if="is_integral_mode" label="所需积分" width="150">
<template slot-scope="{row}"> <template slot-scope="{row}">
<el-input-number v-model="row.integral" style="width: 100%"></el-input-number> <el-input-number v-model="row.integral" style="width: 100%" :min="0"></el-input-number>
</template> </template>
</el-table-column> </el-table-column>
@@ -310,7 +310,7 @@ layout("/layouts/platform.html"){
</el-col> </el-col>
<el-col span="8" v-if="formData.isIntegralMode"> <el-col span="8" v-if="formData.isIntegralMode">
<el-form-item label="总积分" prop="allIntegral"> <el-form-item label="总积分" prop="allIntegral">
<el-input-number v-model="formData.allIntegral" style="width: 100%" min="0"></el-input-number> <el-input-number v-model="formData.allIntegral" style="width: 100%" :min="0"></el-input-number>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
@@ -643,6 +643,10 @@ layout("/layouts/platform.html"){
return return
} }
} }
if (this.formData.isIntegralMode && (!this.formData.allIntegral || this.formData.allIntegral <= 0)) {
this.$message.warning("积分模式下总积分不能为0,请填写总积分!")
return
}
this.submitLoading = true this.submitLoading = true
const loading = this.$loading({ const loading = this.$loading({