Commit 150e5857 authored by Hagsn3's avatar Hagsn3

删除标签一计算方法中多余的log输出

parent c2aba1a3
......@@ -79,6 +79,7 @@
</div>
</el-form>
</div>
<hr class="oneHr">
<el-tabs v-model="activeName" @tab-click="handleClick">
<el-tab-pane label="标签一" name="first">
<div class="OneTable">
......@@ -2397,7 +2398,7 @@ export default {
{ pattern: /^(0|[1-9]\d*)(\.\d{0,4})?$/, message: '请输入有效的数字', trigger: 'change' },
{ validator: this.validateMethod3, trigger: 'blur' }
],
standoneCy: [ { required: true, message: '请输入差异', trigger: 'blur' },
standoneCy: [{ required: true, message: '请输入差异', trigger: 'blur' },
{ pattern: /^(0|[1-9]\d*)(\.\d{0,4})?$/, message: '请输入有效的数字', trigger: 'change' }],
standtwoCy: [{ required: true, message: '请输入差异', trigger: 'blur' },
{ pattern: /^(0|[1-9]\d*)(\.\d{0,4})?$/, message: '请输入有效的数字', trigger: 'change' }],
......@@ -2920,7 +2921,6 @@ export default {
}
this.calculateStandardTagOne(index, this.inspectJbAl2o3List.standardOne, this.inspectJbAl2o3List.standonePlus, this.inspectJbAl2o3List.standoneCy)
// console.log('11111', this.SumList)
},
/**
* @description: 判断是否计算 差异与平均
......@@ -3052,20 +3052,7 @@ export default {
const limitOne = parseFloat(standardOne)
const limitTwo = parseFloat(standardTwo)
const difference1 = parseFloat(difference)
const recordData = this.inspectJbAl2o3List.recode1[index].recordData
const differenceValue1 = this.inspectJbAl2o3List.recode1[index].differenceValue1
console.log('recordData', recordData)
console.log('differenceValue1', differenceValue1)
// if (recordData !== '') {
// const num = parseFloat(recordData)
// if (num >= (limitOne - difference1) && num <= (limitTwo + difference1)) {
// this.inspectJbAl2o3List.recode1[index].differenceValue2 = '合格'
// } else {
// this.inspectJbAl2o3List.recode1[index].differenceValue2 = '不合格'
// }
// } else {
// this.inspectJbAl2o3List.recode1[index].differenceValue2 = ''
// }
if (differenceValue1 !== '') {
const num = parseFloat(differenceValue1)
console.log('num', num)
......@@ -3084,21 +3071,7 @@ export default {
const limitOne = parseFloat(standardOne)
const limitTwo = parseFloat(standardTwo)
const difference1 = parseFloat(difference)
const recordData = this.inspectJbAl2o3List.recode2[index].recordData
const differenceValue1 = this.inspectJbAl2o3List.recode2[index].differenceValue1
console.log('recordData', recordData)
console.log('differenceValue1', differenceValue1)
// const recordData = this.inspectJbAl2o3List.recode2[index].recordData
// if (recordData !== '') {
// const num = parseFloat(recordData)
// if (num >= (limitOne - difference1) && num <= (limitTwo + difference1)) {
// this.inspectJbAl2o3List.recode2[index].differenceValue2 = '合格'
// } else {
// this.inspectJbAl2o3List.recode2[index].differenceValue2 = '不合格'
// }
// } else {
// this.inspectJbAl2o3List.recode2[index].differenceValue2 = ''
// }
if (differenceValue1 !== '') {
const num = parseFloat(differenceValue1)
console.log('num', num)
......@@ -3119,7 +3092,6 @@ export default {
const limitOne = parseFloat(this.inspectJbAl2o3List.limitOne)
const limitTwo = parseFloat(this.inspectJbAl2o3List.limitTwo)
const recordData3 = this.inspectJbAl2o3List.recode3[index].recordData
// this.inspectJbAl2o3List.limitThree = Math.abs(limitOne - limitTwo)
if (recordData3 !== '') {
const num = parseFloat(recordData3)
if (num >= limitOne && num <= limitTwo) {
......@@ -3129,9 +3101,6 @@ export default {
}
}
}
// if (this.inspectJbAl2o3List.limitOne === '' || this.inspectJbAl2o3List.limitTwo === '') {
// this.inspectJbAl2o3List.limitThree = ''
// }
if (this.inspectJbAl2o3List.recode3[index].recordData === '' || this.inspectJbAl2o3List.limitOne === '' || this.inspectJbAl2o3List.limitTwo === '') {
this.inspectJbAl2o3List.recode3[index].differenceValue = ''
}
......@@ -3150,11 +3119,11 @@ export default {
this.handleData3Input(i)
}
if (this.inspectJbAl2o3List.limitOne && this.inspectJbAl2o3List.limitOne !== '' && this.inspectJbAl2o3List.limitOne !== undefined && this.inspectJbAl2o3List.limitTwo && this.inspectJbAl2o3List.limitTwo !== '' && this.inspectJbAl2o3List.limitTwo !== undefined) {
const limitOne = Math.floor(Number(this.inspectJbAl2o3List.limitOne) * 10000); // 将浮点数转换为整数并保留整数部分
const limitTwo = Math.floor(Number(this.inspectJbAl2o3List.limitTwo) * 10000);
this.inspectJbAl2o3List.limitThree = Math.abs(limitOne - limitTwo) / 10000; // 将结果转换回浮点数
const limitOne = Math.floor(Number(this.inspectJbAl2o3List.limitOne) * 10000) // 将浮点数转换为整数并保留整数部分
const limitTwo = Math.floor(Number(this.inspectJbAl2o3List.limitTwo) * 10000)
this.inspectJbAl2o3List.limitThree = Math.abs(limitOne - limitTwo) / 10000 // 将结果转换回浮点数
} else {
this.inspectJbAl2o3List.limitThree = '';
this.inspectJbAl2o3List.limitThree = ''
}
},
// 计算标签一的校验标准1 和 检验标准2 之间的差值
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment