|
@@ -698,16 +698,26 @@
|
|
|
if (this.baseInfoForm.waterMin == '') {
|
|
|
this.$message.error('干粮水分不能为空!')
|
|
|
}
|
|
|
- return false
|
|
|
if (_baseWaterValidate(1, 100, 1, 0.5, "waterBase", parseFloat(this.baseInfoForm.waterMin))) {
|
|
|
- that.$message.error('干粮水分输入错误!')
|
|
|
+ that.$message.error('干粮水分输入错误,最多保留1位小数,干粮水分须可被0.5整除!')
|
|
|
}
|
|
|
return false
|
|
|
}
|
|
|
+
|
|
|
+ if (this.baseInfoForm.waterBase>this.baseInfoForm.waterMax) {
|
|
|
+ this.$message.error('基准水分须小于水分上限!')
|
|
|
+ return false
|
|
|
+ }
|
|
|
+
|
|
|
+ if (this.baseInfoForm.waterMin>this.baseInfoForm.waterBase) {
|
|
|
+ this.$message.error('干粮水分须小于基准水分!')
|
|
|
+ return false
|
|
|
+ }
|
|
|
+
|
|
|
if (this.baseInfoForm.waterMax == '' || _baseWaterValidate(1, 100, 1, 0.5, "waterBase", parseFloat(this
|
|
|
.baseInfoForm.waterMax))) {
|
|
|
if (_baseWaterValidate(1, 100, 1, 0.5, "waterBase", parseFloat(this.baseInfoForm.waterMax))) {
|
|
|
- that.$message.error('水分上限输入错误!');
|
|
|
+ that.$message.error('水分上限输入错误,最多保留1位小数,干粮水分须可被0.5整除!');
|
|
|
} else {
|
|
|
this.$message.error('水分上限不能为空!');
|
|
|
}
|
|
@@ -733,7 +743,7 @@
|
|
|
if (_item.basicUnitPrice == '') {
|
|
|
this.$message.error('基准单价不能为空!');
|
|
|
} else {
|
|
|
- that.$message.error('基准单价输入错误!');
|
|
|
+ that.$message.error('基准单价输入错误,0-50数字最多保留两位小数!');
|
|
|
}
|
|
|
return false
|
|
|
}
|
|
@@ -780,11 +790,13 @@
|
|
|
},
|
|
|
// 提交
|
|
|
submit() {
|
|
|
+ let isValidate = false
|
|
|
+ isValidate = this.validate()
|
|
|
+ if (isValidate) {
|
|
|
this.makeTableList()
|
|
|
this.baseInfoForm.details = []
|
|
|
this.makePriceDataList()
|
|
|
this.baseInfoForm.goodsName = this.selectVal
|
|
|
- let isValidate = false
|
|
|
switch (this.$route.query.type) {
|
|
|
case "查看":
|
|
|
this.isCountShow = false;
|
|
@@ -826,6 +838,8 @@
|
|
|
}
|
|
|
break;
|
|
|
}
|
|
|
+ }
|
|
|
+
|
|
|
},
|
|
|
//审核
|
|
|
audit(item, status, status2) {
|
|
@@ -1441,6 +1455,6 @@
|
|
|
background: white!important;
|
|
|
}
|
|
|
#aaa::selection{
|
|
|
- background: red;
|
|
|
+ // background: red;
|
|
|
}
|
|
|
</style>
|