1.已添加数字校验

master
x_z 3 years ago
parent c54747be55
commit bf2915e60d

@ -189,8 +189,6 @@
this.loading = false;
this.list = response.data.list || [];
this.total = response.data.total || 0;
console.log("------------");
console.log(response);
})
.catch(() => {
this.loading = false;
@ -228,15 +226,17 @@
}
},
formSubmit() {
if (!Number.isInteger(parseInt(this.formData.paramValue))) {
this.$message.warning("参数值必须为数字");
return;
}
this.$refs["dataForm"].validate((valid) => {
if (valid) {
this.formLoading = true;
let data = Object.assign({}, this.formData);
console.log("------2------");
data.paramValue = data.paramValue.trim();
systemParamConfigSave(data, this.formName)
.then((response) => {
console.log(response);
this.formLoading = false;
if (response.code != 20000) {
this.$message.error(response.message);

Loading…
Cancel
Save