Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
T
template_vue
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
胡宝山
template_vue
Commits
2c4b4f46
Commit
2c4b4f46
authored
Mar 18, 2024
by
Hagsn3
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改合格判定标准
parent
e343f6c8
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
139 additions
and
93 deletions
+139
-93
templateFirst.vue
src/views/template/templateFirst.vue
+139
-93
No files found.
src/views/template/templateFirst.vue
View file @
2c4b4f46
...
...
@@ -79,7 +79,6 @@
</div>
</el-form>
</div>
<hr
class=
"oneHr"
>
<el-tabs
v-model=
"activeName"
@
tab-click=
"handleClick"
>
<el-tab-pane
label=
"标签一"
name=
"first"
>
<div
class=
"OneTable"
>
...
...
@@ -1260,21 +1259,21 @@
</el-form-item>
<el-form-item
label=
"差异:"
>
<span
v-if=
"inspectJbAl2o3List.limitThree"
>
{{
inspectJbAl2o3List
.
limitThree
}}
</span>
<span
v-else
></span
>
<!--
<el-input-->
<!-- v-model="inspectJbAl2o3List.limitThree"-->
<!-- class="inspectionStandardsInput"-->
<!-- :maxlength="7"-->
<!-- :disabled="(firstFromDisabled)"-->
<!-- @input="CalculateDifference"-->
<!-- />-->
<span
v-else
/
>
<!--
<el-input-->
<!-- v-model="inspectJbAl2o3List.limitThree"-->
<!-- class="inspectionStandardsInput"-->
<!-- :maxlength="7"-->
<!-- :disabled="(firstFromDisabled)"-->
<!-- @input="CalculateDifference"-->
<!-- />-->
</el-form-item>
</el-form>
<!--
<div-->
<!-- class="inspectDifferent"-->
<!-- :disabled="(firstFromDisabled)"-->
<!-- @input="CalculateDifference"-->
<!-- >差异 :
</div>
-->
<!--
<div-->
<!-- class="inspectDifferent"-->
<!-- :disabled="(firstFromDisabled)"-->
<!-- @input="CalculateDifference"-->
<!-- >差异 :
</div>
-->
</div>
<div
class=
"recordFourTitle"
>
<div
class=
"input"
>
输入
</div>
...
...
@@ -2398,7 +2397,7 @@ export default {
{
pattern
:
/^
(
0|
[
1-9
]\d
*
)(\.\d{0,6})?
$/
,
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,6})?
$/
,
message
:
'请输入有效的数字'
,
trigger
:
'change'
}],
standtwoCy
:
[{
required
:
true
,
message
:
'请输入差异'
,
trigger
:
'blur'
},
{
pattern
:
/^
(
0|
[
1-9
]\d
*
)(\.\d{0,6})?
$/
,
message
:
'请输入有效的数字'
,
trigger
:
'change'
}],
...
...
@@ -2881,12 +2880,12 @@ export default {
/* 表单1的计算方法*/
handleData1Input
(
index
)
{
// 两种情况 1.单数 2.双数
if
(
index
%
2
===
0
)
{
if
(
index
%
2
===
0
)
{
/**
* 1.单数情况下计算 自身与自身加1 的差值和均值
*
* **/
if
(
this
.
inspectJbAl2o3List
.
recode1
[
index
].
recordData
&&
this
.
inspectJbAl2o3List
.
recode1
[
index
].
recordData
!==
''
&&
this
.
inspectJbAl2o3List
.
recode1
[
index
].
recordData
!==
undefined
&&
this
.
inspectJbAl2o3List
.
recode1
[
index
+
1
].
recordData
&&
this
.
inspectJbAl2o3List
.
recode1
[
index
+
1
].
recordData
!==
''
&&
this
.
inspectJbAl2o3List
.
recode1
[
index
+
1
].
recordData
!==
undefined
)
{
if
(
this
.
inspectJbAl2o3List
.
recode1
[
index
].
recordData
&&
this
.
inspectJbAl2o3List
.
recode1
[
index
].
recordData
!==
''
&&
this
.
inspectJbAl2o3List
.
recode1
[
index
].
recordData
!==
undefined
&&
this
.
inspectJbAl2o3List
.
recode1
[
index
+
1
].
recordData
&&
this
.
inspectJbAl2o3List
.
recode1
[
index
+
1
].
recordData
!==
''
&&
this
.
inspectJbAl2o3List
.
recode1
[
index
+
1
].
recordData
!==
undefined
)
{
const
num1
=
parseFloat
(
this
.
inspectJbAl2o3List
.
recode1
[
index
].
recordData
)
const
num2
=
parseFloat
(
this
.
inspectJbAl2o3List
.
recode1
[
index
+
1
].
recordData
)
this
.
inspectJbAl2o3List
.
recode1
[
index
+
1
].
differenceValue
=
this
.
digitalFormat
(
Math
.
abs
(
num1
-
num2
).
toFixed
(
this
.
LIMITNGHOURS
))
...
...
@@ -2900,7 +2899,7 @@ export default {
* 1.单数情况下计算 自身与自身减一 的差值和均值
*
* **/
if
(
this
.
inspectJbAl2o3List
.
recode1
[
index
].
recordData
&&
this
.
inspectJbAl2o3List
.
recode1
[
index
].
recordData
!==
''
&&
this
.
inspectJbAl2o3List
.
recode1
[
index
-
1
].
recordData
!==
undefined
&&
this
.
inspectJbAl2o3List
.
recode1
[
index
-
1
].
recordData
&&
this
.
inspectJbAl2o3List
.
recode1
[
index
-
1
].
recordData
!==
''
&&
this
.
inspectJbAl2o3List
.
recode1
[
index
-
1
].
recordData
!==
undefined
)
{
if
(
this
.
inspectJbAl2o3List
.
recode1
[
index
].
recordData
&&
this
.
inspectJbAl2o3List
.
recode1
[
index
].
recordData
!==
''
&&
this
.
inspectJbAl2o3List
.
recode1
[
index
-
1
].
recordData
!==
undefined
&&
this
.
inspectJbAl2o3List
.
recode1
[
index
-
1
].
recordData
&&
this
.
inspectJbAl2o3List
.
recode1
[
index
-
1
].
recordData
!==
''
&&
this
.
inspectJbAl2o3List
.
recode1
[
index
-
1
].
recordData
!==
undefined
)
{
const
num1
=
parseFloat
(
this
.
inspectJbAl2o3List
.
recode1
[
index
].
recordData
)
const
num2
=
parseFloat
(
this
.
inspectJbAl2o3List
.
recode1
[
index
-
1
].
recordData
)
this
.
inspectJbAl2o3List
.
recode1
[
index
].
differenceValue
=
this
.
digitalFormat
(
Math
.
abs
(
num1
-
num2
).
toFixed
(
this
.
LIMITNGHOURS
))
...
...
@@ -2920,7 +2919,7 @@ export default {
this
.
calculate
(
this
.
removeEmptyValues
(
this
.
SumList
),
1
)
}
this
.
calculateStandardTagOne
(
index
,
this
.
inspectJbAl2o3List
.
standardOne
,
this
.
inspectJbAl2o3List
.
standonePlus
,
this
.
inspectJbAl2o3List
.
standoneCy
)
this
.
calculateStandardTagOne
(
index
,
this
.
inspectJbAl2o3List
.
standardOne
,
this
.
inspectJbAl2o3List
.
standonePlus
,
this
.
inspectJbAl2o3List
.
standoneCy
)
// console.log('11111', this.SumList)
},
/**
...
...
@@ -2931,8 +2930,8 @@ export default {
**/
compute
(
index
)
{
var
result
=
false
console
.
log
(
'index'
,
index
%
2
)
if
(
index
%
2
===
1
)
{
console
.
log
(
'index'
,
index
%
2
)
if
(
index
%
2
===
1
)
{
result
=
true
}
return
result
...
...
@@ -3006,12 +3005,12 @@ export default {
/* 表单2的计算方法*/
handleData2Input
(
index
)
{
// 两种情况 1.单数 2.双数
if
(
index
%
2
===
0
)
{
if
(
index
%
2
===
0
)
{
/**
* 1.单数情况下计算 自身与自身加1 的差值和均值
*
* **/
if
(
this
.
inspectJbAl2o3List
.
recode2
[
index
].
recordData
&&
this
.
inspectJbAl2o3List
.
recode2
[
index
].
recordData
!==
''
&&
this
.
inspectJbAl2o3List
.
recode2
[
index
].
recordData
!==
undefined
&&
this
.
inspectJbAl2o3List
.
recode2
[
index
+
1
].
recordData
&&
this
.
inspectJbAl2o3List
.
recode2
[
index
+
1
].
recordData
!==
''
&&
this
.
inspectJbAl2o3List
.
recode2
[
index
+
1
].
recordData
!==
undefined
)
{
if
(
this
.
inspectJbAl2o3List
.
recode2
[
index
].
recordData
&&
this
.
inspectJbAl2o3List
.
recode2
[
index
].
recordData
!==
''
&&
this
.
inspectJbAl2o3List
.
recode2
[
index
].
recordData
!==
undefined
&&
this
.
inspectJbAl2o3List
.
recode2
[
index
+
1
].
recordData
&&
this
.
inspectJbAl2o3List
.
recode2
[
index
+
1
].
recordData
!==
''
&&
this
.
inspectJbAl2o3List
.
recode2
[
index
+
1
].
recordData
!==
undefined
)
{
const
num1
=
parseFloat
(
this
.
inspectJbAl2o3List
.
recode2
[
index
].
recordData
)
const
num2
=
parseFloat
(
this
.
inspectJbAl2o3List
.
recode2
[
index
+
1
].
recordData
)
this
.
inspectJbAl2o3List
.
recode2
[
index
+
1
].
differenceValue
=
this
.
digitalFormat
(
Math
.
abs
(
num1
-
num2
).
toFixed
(
this
.
LIMITNGHOURS
))
...
...
@@ -3025,7 +3024,7 @@ export default {
* 1.单数情况下计算 自身与自身减一 的差值和均值
*
* **/
if
(
this
.
inspectJbAl2o3List
.
recode2
[
index
].
recordData
&&
this
.
inspectJbAl2o3List
.
recode2
[
index
].
recordData
!==
''
&&
this
.
inspectJbAl2o3List
.
recode2
[
index
-
1
].
recordData
!==
undefined
&&
this
.
inspectJbAl2o3List
.
recode2
[
index
-
1
].
recordData
&&
this
.
inspectJbAl2o3List
.
recode2
[
index
-
1
].
recordData
!==
''
&&
this
.
inspectJbAl2o3List
.
recode2
[
index
-
1
].
recordData
!==
undefined
)
{
if
(
this
.
inspectJbAl2o3List
.
recode2
[
index
].
recordData
&&
this
.
inspectJbAl2o3List
.
recode2
[
index
].
recordData
!==
''
&&
this
.
inspectJbAl2o3List
.
recode2
[
index
-
1
].
recordData
!==
undefined
&&
this
.
inspectJbAl2o3List
.
recode2
[
index
-
1
].
recordData
&&
this
.
inspectJbAl2o3List
.
recode2
[
index
-
1
].
recordData
!==
''
&&
this
.
inspectJbAl2o3List
.
recode2
[
index
-
1
].
recordData
!==
undefined
)
{
const
num1
=
parseFloat
(
this
.
inspectJbAl2o3List
.
recode2
[
index
].
recordData
)
const
num2
=
parseFloat
(
this
.
inspectJbAl2o3List
.
recode2
[
index
-
1
].
recordData
)
this
.
inspectJbAl2o3List
.
recode2
[
index
].
differenceValue
=
this
.
digitalFormat
(
Math
.
abs
(
num1
-
num2
).
toFixed
(
this
.
LIMITNGHOURS
))
...
...
@@ -3045,40 +3044,71 @@ export default {
this
.
calculate
(
this
.
removeEmptyValues
(
this
.
SumList1
),
2
)
}
this
.
calculateStandardTagTwo
(
index
,
this
.
inspectJbAl2o3List
.
standardTwo
,
this
.
inspectJbAl2o3List
.
standtwoPlus
,
this
.
inspectJbAl2o3List
.
standtwoCy
)
this
.
calculateStandardTagTwo
(
index
,
this
.
inspectJbAl2o3List
.
standardTwo
,
this
.
inspectJbAl2o3List
.
standtwoPlus
,
this
.
inspectJbAl2o3List
.
standtwoCy
)
},
calculateStandardTagOne
(
index
,
standardOne
,
standardTwo
,
difference
)
{
calculateStandardTagOne
(
index
,
standardOne
,
standardTwo
,
difference
)
{
if
(
standardOne
&&
standardOne
!==
null
&&
standardTwo
&&
standardTwo
!==
null
&&
difference
&&
difference
!==
null
)
{
const
limitOne
=
parseFloat
(
standardOne
)
const
limitTwo
=
parseFloat
(
standardTwo
)
const
difference1
=
parseFloat
(
difference
)
const
recordData
=
this
.
inspectJbAl2o3List
.
recode1
[
index
].
recordData
if
(
recordData
!==
''
)
{
const
num
=
parseFloat
(
recordData
)
if
(
num
>=
(
limitOne
-
difference1
)
&&
num
<=
(
limitTwo
+
difference1
)
)
{
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
)
if
(
num
>=
(
limitOne
-
difference1
)
&&
num
<=
(
limitTwo
+
difference1
))
{
this
.
inspectJbAl2o3List
.
recode1
[
index
].
differenceValue2
=
'合格'
}
else
{
this
.
inspectJbAl2o3List
.
recode1
[
index
].
differenceValue2
=
'不合格'
}
}
else
{
this
.
inspectJbAl2o3List
.
recode1
[
index
].
differenceValue2
=
''
}
}
},
calculateStandardTagTwo
(
index
,
standardOne
,
standardTwo
,
difference
)
{
calculateStandardTagTwo
(
index
,
standardOne
,
standardTwo
,
difference
)
{
if
(
standardOne
&&
standardOne
!==
null
&&
standardTwo
&&
standardTwo
!==
null
&&
difference
&&
difference
!==
null
)
{
const
limitOne
=
parseFloat
(
standardOne
)
const
limitTwo
=
parseFloat
(
standardTwo
)
const
difference1
=
parseFloat
(
difference
)
const
recordData
=
this
.
inspectJbAl2o3List
.
recode2
[
index
].
recordData
if
(
recordData
!==
''
)
{
const
num
=
parseFloat
(
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
)
if
(
num
>=
(
limitOne
-
difference1
)
&&
num
<=
(
limitTwo
+
difference1
))
{
this
.
inspectJbAl2o3List
.
recode2
[
index
].
differenceValue2
=
'合格'
}
else
{
this
.
inspectJbAl2o3List
.
recode2
[
index
].
differenceValue2
=
'不合格'
}
}
else
{
this
.
inspectJbAl2o3List
.
recode2
[
index
].
differenceValue2
=
''
}
}
},
...
...
@@ -3119,7 +3149,7 @@ export default {
for
(
let
i
=
0
;
i
<
15
;
i
++
)
{
this
.
handleData3Input
(
i
)
}
if
(
this
.
inspectJbAl2o3List
.
limitOne
&&
this
.
inspectJbAl2o3List
.
limitOne
!==
''
&&
this
.
inspectJbAl2o3List
.
limitOne
!==
undefined
&&
this
.
inspectJbAl2o3List
.
limitTwo
&&
this
.
inspectJbAl2o3List
.
limitTwo
!==
''
&&
this
.
inspectJbAl2o3List
.
limitTwo
!==
undefined
)
{
if
(
this
.
inspectJbAl2o3List
.
limitOne
&&
this
.
inspectJbAl2o3List
.
limitOne
!==
''
&&
this
.
inspectJbAl2o3List
.
limitOne
!==
undefined
&&
this
.
inspectJbAl2o3List
.
limitTwo
&&
this
.
inspectJbAl2o3List
.
limitTwo
!==
''
&&
this
.
inspectJbAl2o3List
.
limitTwo
!==
undefined
)
{
const
limitOne
=
parseFloat
(
this
.
inspectJbAl2o3List
.
limitOne
)
const
limitTwo
=
parseFloat
(
this
.
inspectJbAl2o3List
.
limitTwo
)
this
.
inspectJbAl2o3List
.
limitThree
=
Math
.
abs
(
limitOne
-
limitTwo
)
...
...
@@ -3136,8 +3166,8 @@ export default {
// } else {
// this.inspectJbAl2o3List.standoneCy = ''
// }
for
(
var
i
=
0
;
i
<
10
;
i
++
)
{
this
.
calculateStandardTagOne
(
i
,
this
.
inspectJbAl2o3List
.
standardOne
,
this
.
inspectJbAl2o3List
.
standonePlus
,
this
.
inspectJbAl2o3List
.
standoneCy
)
for
(
var
i
=
0
;
i
<
10
;
i
++
)
{
this
.
calculateStandardTagOne
(
i
,
this
.
inspectJbAl2o3List
.
standardOne
,
this
.
inspectJbAl2o3List
.
standonePlus
,
this
.
inspectJbAl2o3List
.
standoneCy
)
}
},
...
...
@@ -3150,8 +3180,8 @@ export default {
// } else {
// this.inspectJbAl2o3List.standtwoPlus = ''
// }
for
(
var
i
=
0
;
i
<
10
;
i
++
)
{
this
.
calculateStandardTagTwo
(
i
,
this
.
inspectJbAl2o3List
.
standardTwo
,
this
.
inspectJbAl2o3List
.
standtwoPlus
,
this
.
inspectJbAl2o3List
.
standtwoCy
)
for
(
var
i
=
0
;
i
<
10
;
i
++
)
{
this
.
calculateStandardTagTwo
(
i
,
this
.
inspectJbAl2o3List
.
standardTwo
,
this
.
inspectJbAl2o3List
.
standtwoPlus
,
this
.
inspectJbAl2o3List
.
standtwoCy
)
}
},
...
...
@@ -4462,6 +4492,8 @@ export default {
}
.compareValue
{
/**挪一下位置*/
margin-top
:
-7%
;
width
:
25%
;
font-size
:
14px
;
font-family
:
Microsoft
YaHei
,
Microsoft
YaHei-400
;
...
...
@@ -4473,6 +4505,8 @@ export default {
align-items
:
center
;
}
.eorrCompareValue
{
/**挪一下位置*/
margin-top
:
-8%
;
width
:
25%
;
font-size
:
14px
;
font-family
:
Microsoft
YaHei
,
Microsoft
YaHei-400
;
...
...
@@ -4557,6 +4591,8 @@ export default {
}
.compareValue
{
/**挪一下位置*/
margin-top
:
-7%
;
width
:
25%
;
font-size
:
14px
;
font-family
:
Microsoft
YaHei
,
Microsoft
YaHei-400
;
...
...
@@ -4569,6 +4605,8 @@ export default {
}
.eorrCompareValue
{
/**挪一下位置*/
margin-top
:
-8%
;
width
:
25%
;
font-size
:
14px
;
font-family
:
Microsoft
YaHei
,
Microsoft
YaHei-400
;
...
...
@@ -5004,6 +5042,8 @@ export default {
}
.compareValue
{
/**挪一下位置*/
margin-top
:
-7%
;
width
:
25%
;
font-size
:
14px
;
font-family
:
Microsoft
YaHei
,
Microsoft
YaHei-400
;
...
...
@@ -5015,6 +5055,8 @@ export default {
align-items
:
center
;
}
.errorCompareValue
{
/**挪一下位置*/
margin-top
:
-8%
;
width
:
25%
;
font-size
:
14px
;
font-family
:
Microsoft
YaHei
,
Microsoft
YaHei-400
;
...
...
@@ -5101,6 +5143,8 @@ export default {
}
.compareValue
{
/**挪一下位置*/
margin-top
:
-7%
;
width
:
25%
;
font-size
:
14px
;
font-family
:
Microsoft
YaHei
,
Microsoft
YaHei-400
;
...
...
@@ -5112,6 +5156,8 @@ export default {
align-items
:
center
;
}
.errorCompareValue
{
/**挪一下位置*/
margin-top
:
-8%
;
width
:
25%
;
font-size
:
14px
;
font-family
:
Microsoft
YaHei
,
Microsoft
YaHei-400
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment