Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
M
mes-pad
Project
Project
Details
Activity
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
ximai
mes-pad
Commits
e623a628
Commit
e623a628
authored
Mar 29, 2024
by
张海景
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update:修改检测项目显示
parent
f620d844
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
78 additions
and
48 deletions
+78
-48
index.vue
pages/mes/qc/index.vue
+78
-48
No files found.
pages/mes/qc/index.vue
View file @
e623a628
...
@@ -13,7 +13,7 @@
...
@@ -13,7 +13,7 @@
</view>
</view>
<view
class=
"grid-text"
>
首检确认
</view>
<view
class=
"grid-text"
>
首检确认
</view>
</view>
-->
</view>
-->
<view
class=
"button-frame"
:class=
"
{ active: qcType.value === curQcType }" v-for="qcType in dict.type.mes_ipqc_type
2
" @click="handleClickBtn(qcType.value)">
<view
class=
"button-frame"
:class=
"
{ active: qcType.value === curQcType }" v-for="qcType in dict.type.mes_ipqc_type" @click="handleClickBtn(qcType.value)">
<!--
<view
class=
"shortcut-icon icon-color01"
>
<!--
<view
class=
"shortcut-icon icon-color01"
>
<image
class=
"icon-button"
src=
"/static/icons/png/pro.png"
/>
<image
class=
"icon-button"
src=
"/static/icons/png/pro.png"
/>
</view>
-->
</view>
-->
...
@@ -54,7 +54,7 @@
...
@@ -54,7 +54,7 @@
<uni-td
align=
"center"
>
{{
line
.
ipqcCode
}}
</uni-td>
<uni-td
align=
"center"
>
{{
line
.
ipqcCode
}}
</uni-td>
<!--
<uni-td
align=
"center"
>
{{
line
.
ipqcName
}}
<ss
/
uni-td
>
-->
<!--
<uni-td
align=
"center"
>
{{
line
.
ipqcName
}}
<ss
/
uni-td
>
-->
<!--
<uni-td
align=
"center"
>
<!--
<uni-td
align=
"center"
>
<dict-tag
:options=
"dict.type.mes_ipqc_type
2
"
:value=
"line.ipqcType"
/>
<dict-tag
:options=
"dict.type.mes_ipqc_type"
:value=
"line.ipqcType"
/>
</uni-td>
-->
</uni-td>
-->
<uni-td>
{{
line
.
workorderCode
}}
</uni-td>
<uni-td>
{{
line
.
workorderCode
}}
</uni-td>
<uni-td
align=
"center"
>
{{
line
.
itemCode
}}
</uni-td>
<uni-td
align=
"center"
>
{{
line
.
itemCode
}}
</uni-td>
...
@@ -93,7 +93,7 @@
...
@@ -93,7 +93,7 @@
</view>
</view>
</view>
</view>
<u-modal
width=
"90%"
v-model=
"qcModalFlag"
:showConfirmButton=
"true"
:showCancelButton=
"true"
title=
"请填写检验单"
content=
"操作内容"
>
<u-modal
width=
"90%"
@
confirm=
"submitIpqc"
v-model=
"qcModalFlag"
:showConfirmButton=
"true"
:showCancelButton=
"true"
title=
"请填写检验单"
content=
"操作内容"
>
<u-form
ref=
"qcForm"
label-width=
"90px"
>
<u-form
ref=
"qcForm"
label-width=
"90px"
>
<u-row>
<u-row>
<u-col
span=
"5"
>
<u-col
span=
"5"
>
...
@@ -109,7 +109,7 @@
...
@@ -109,7 +109,7 @@
<u-col
span=
"4"
>
<u-col
span=
"4"
>
<u-form-item
label=
"检测结果"
prop=
"checkResult"
>
<u-form-item
label=
"检测结果"
prop=
"checkResult"
>
<u-radio-group
v-model=
"qcForm.checkResult"
>
<u-radio-group
v-model=
"qcForm.checkResult"
>
<u-radio
:name=
"item.value"
v-for=
"item in dict.type.mes_qc_result"
v-
key=
"item.value"
>
<u-radio
:name=
"item.value"
v-for=
"item in dict.type.mes_qc_result"
:
key=
"item.value"
>
{{
item
.
label
}}
{{
item
.
label
}}
</u-radio>
</u-radio>
</u-radio-group>
</u-radio-group>
...
@@ -141,48 +141,22 @@
...
@@ -141,48 +141,22 @@
</u-form-item>
</u-form-item>
</u-col>
</u-col>
</u-row>
</u-row>
<u-row>
<u-col
span=
"3"
></u-col>
<u-col
span=
"3"
>
<u-button
type=
"primary"
@
click=
"submitIpqc"
>
保存
</u-button>
</u-col>
<u-col
span=
"1"
></u-col>
<u-col
span=
"3"
>
<u-button
type=
"success"
@
click=
"submitIpqc('CONFIRMED')"
>
完成
</u-button>
</u-col>
</u-row>
</u-form>
</u-form>
<scroll-view
scroll-y=
"true"
scroll-x=
"true"
class=
"line-list"
>
<scroll-view
scroll-y=
"true"
scroll-x=
"true"
class=
"line-list"
>
<view
class=
"line-content"
>
<view
class=
"line-content
-item
"
>
<uni-table
ref=
"qcLineTable"
class=
"line-table"
border
stripe
:loading=
"loading"
emptyText=
"未查询到数据"
>
<uni-table
ref=
"qcLineTable"
class=
"line-table"
border
stripe
:loading=
"loading"
emptyText=
"未查询到数据"
>
<uni-tr>
<uni-tr>
<uni-th
width=
"160px"
align=
"center"
>
检测项名称
</uni-th>
<uni-th
width=
"100px"
align=
"center"
>
质检项目
</uni-th>
<uni-th
width=
"150px"
align=
"center"
>
检测工具
</uni-th>
<uni-th
width=
"100px"
align=
"center"
>
检验要求
</uni-th>
<uni-th
width=
"150px"
align=
"center"
>
检测要求
</uni-th>
<uni-th
width=
"150px"
align=
"center"
>
检验结果
</uni-th>
<uni-th
width=
"100px"
align=
"center"
>
标准值
</uni-th>
<uni-th
width=
"100px"
align=
"center"
>
单位
</uni-th>
<uni-th
width=
"100px"
align=
"center"
>
误差上限
</uni-th>
<uni-th
width=
"100px"
align=
"center"
>
误差下限
</uni-th>
<uni-th
width=
"100px"
align=
"center"
>
致命缺陷数量
</uni-th>
<uni-th
width=
"100px"
align=
"center"
>
严重缺陷数量
</uni-th>
<uni-th
width=
"100px"
align=
"center"
>
轻微缺陷数量
</uni-th>
<uni-th
width=
"150px"
align=
"center"
>
操作
</uni-th>
</uni-tr>
</uni-tr>
<uni-tr
v-for=
"(line, index) in qcLines"
:key=
"index"
>
<uni-tr
v-for=
"(line, index) in qcLines"
:key=
"index
+'index'
"
>
<uni-td
align=
"center"
>
{{
line
.
indexName
}}
</uni-td>
<uni-td
align=
"center"
>
{{
line
.
indexName
}}
</uni-td>
<uni-td
align=
"center"
>
{{
line
.
qcTool
}}
</uni-td>
<uni-td
align=
"center"
>
{{
line
.
checkMethod
}}
</uni-td>
<uni-td>
{{
line
.
checkMethod
}}
</uni-td>
<uni-td
width=
"150px"
align=
"center"
>
<uni-td
align=
"center"
>
{{
line
.
standerVal
}}
</uni-td>
<!--
{{
line
.
qualityCheckResults
v
-
if
=
"line.inputType == 2"
}}
-->
<uni-td
align=
"center"
>
{{
line
.
unitOfMeasure
}}
</uni-td>
<uni-data-checkbox
v-if=
"line.inputType == 2"
multiple
v-model=
"line.qualityCheckResults"
:localdata=
"line.selectValues"
></uni-data-checkbox>
<uni-td
align=
"center"
>
{{
line
.
thresholdMax
}}
</uni-td>
<uni-easyinput
v-else
v-model=
"line.qualityCheckResults"
></uni-easyinput>
<uni-td
align=
"center"
>
{{
line
.
thresholdMin
}}
</uni-td>
<uni-td
align=
"center"
>
{{
line
.
crQuantity
}}
</uni-td>
<uni-td
align=
"center"
>
{{
line
.
majQuantity
}}
</uni-td>
<uni-td
align=
"center"
>
{{
line
.
minQuantity
}}
</uni-td>
<uni-td>
<view
class=
"uni-group"
>
<button
class=
"uni-button"
size=
"mini"
type=
"primary"
@
click=
"qcLineItemClick(line)"
>
缺陷登记
</button>
</view>
</uni-td>
</uni-td>
</uni-tr>
</uni-tr>
</uni-table>
</uni-table>
...
@@ -257,7 +231,7 @@
...
@@ -257,7 +231,7 @@
<uni-td
align=
"center"
>
{{
line
.
ipqcCode
}}
</uni-td>
<uni-td
align=
"center"
>
{{
line
.
ipqcCode
}}
</uni-td>
<uni-td
align=
"center"
>
{{
line
.
ipqcName
}}
</uni-td>
<uni-td
align=
"center"
>
{{
line
.
ipqcName
}}
</uni-td>
<uni-td
align=
"center"
>
<uni-td
align=
"center"
>
<dict-tag
:options=
"dict.type.mes_ipqc_type
2
"
:value=
"line.ipqcType"
/>
<dict-tag
:options=
"dict.type.mes_ipqc_type"
:value=
"line.ipqcType"
/>
</uni-td>
</uni-td>
<uni-td>
{{
line
.
workorderCode
}}
</uni-td>
<uni-td>
{{
line
.
workorderCode
}}
</uni-td>
<uni-td
align=
"center"
>
{{
line
.
itemCode
}}
</uni-td>
<uni-td
align=
"center"
>
{{
line
.
itemCode
}}
</uni-td>
...
@@ -332,14 +306,16 @@
...
@@ -332,14 +306,16 @@
<
script
>
<
script
>
import
SearchInput
from
'@/components/ScanInput/index.vue'
;
import
SearchInput
from
'@/components/ScanInput/index.vue'
;
import
UButton
from
'../../../uview-ui/components/u-button/u-button.vue'
;
import
UButton
from
'../../../uview-ui/components/u-button/u-button.vue'
;
import
UniEasyinput
from
'../../../uni_modules/uni-easyinput/components/uni-easyinput/uni-easyinput.vue'
;
export
default
{
export
default
{
name
:
'QcContent'
,
name
:
'QcContent'
,
components
:
{
components
:
{
SearchInput
,
SearchInput
,
UButton
UButton
,
UniEasyinput
},
},
dicts
:
[
'mes_ipqc_type
2
'
,
'mes_qc_result'
,
'mes_order_status'
,
'mes_defect_level'
],
dicts
:
[
'mes_ipqc_type'
,
'mes_qc_result'
,
'mes_order_status'
,
'mes_defect_level'
],
data
()
{
data
()
{
return
{
return
{
screenHeight
:
768
,
screenHeight
:
768
,
...
@@ -382,7 +358,7 @@ export default {
...
@@ -382,7 +358,7 @@ export default {
}
}
],
],
taskInfo
:
{},
taskInfo
:
{},
curQcType
:
''
,
curQcType
:
'
FIRST
'
,
defectrecordList
:
[],
defectrecordList
:
[],
qcLineItem
:
{},
qcLineItem
:
{},
deffectModalFlag
:
false
,
deffectModalFlag
:
false
,
...
@@ -398,7 +374,9 @@ export default {
...
@@ -398,7 +374,9 @@ export default {
this
.
screenHeight
=
res
.
windowHeight
;
this
.
screenHeight
=
res
.
windowHeight
;
}
}
});
});
this
.
getIpqcList
();
this
.
getIpqcList
(
"FIRST"
);
},
mounted
()
{
},
},
methods
:
{
methods
:
{
async
firstCONFIRMED
(
item
)
{
async
firstCONFIRMED
(
item
)
{
...
@@ -436,13 +414,31 @@ export default {
...
@@ -436,13 +414,31 @@ export default {
this
.
$u
.
toast
(
'请输入任务单号!'
);
this
.
$u
.
toast
(
'请输入任务单号!'
);
return
;
return
;
}
}
const
qcIpqclineList
=
this
.
qcLines
.
map
(
item
=>
{
let
selectValues
=
item
.
selectValues
let
qualityCheckResults
=
item
.
qualityCheckResults
if
(
item
.
inputType
==
2
)
{
selectValues
=
item
.
selectValues
.
map
(
item
=>
{
return
{
name
:
item
.
value
}
})
selectValues
=
JSON
.
stringify
(
selectValues
)
qualityCheckResults
=
JSON
.
stringify
(
item
.
qualityCheckResults
)
}
return
{
...
item
,
selectValues
,
qualityCheckResults
}
})
const
ipqcCode
=
await
this
.
$u
.
api
.
getIpqcCode
();
const
ipqcCode
=
await
this
.
$u
.
api
.
getIpqcCode
();
const
param
=
{
const
param
=
{
ipqcId
:
this
.
qcForm
.
ipqcId
,
ipqcId
:
this
.
qcForm
.
ipqcId
,
ipqcCode
:
ipqcCode
,
ipqcCode
:
ipqcCode
,
ipqcName
:
this
.
qcForm
.
ipqcName
,
ipqcName
:
this
.
qcForm
.
ipqcName
,
ipqcType
:
this
.
curQcType
,
ipqcType
:
this
.
curQcType
,
templateId
:
null
,
templateId
:
this
.
qcForm
.
templateId
,
workorderId
:
this
.
taskInfo
.
workorderId
,
workorderId
:
this
.
taskInfo
.
workorderId
,
workorderCode
:
this
.
taskInfo
.
workorderCode
,
workorderCode
:
this
.
taskInfo
.
workorderCode
,
workorderName
:
this
.
taskInfo
.
workorderName
,
workorderName
:
this
.
taskInfo
.
workorderName
,
...
@@ -470,9 +466,11 @@ export default {
...
@@ -470,9 +466,11 @@ export default {
majQuantity
:
null
,
majQuantity
:
null
,
minQuantity
:
null
,
minQuantity
:
null
,
checkResult
:
this
.
qcForm
.
checkResult
,
checkResult
:
this
.
qcForm
.
checkResult
,
workorderId
:
this
.
qcForm
.
workorderId
,
inspectDate
:
new
Date
(),
inspectDate
:
new
Date
(),
inspector
:
this
.
vuex_user
.
userName
,
inspector
:
this
.
vuex_user
.
userName
,
status
:
'PREPARE'
status
:
'PREPARE'
,
qcIpqclineList
};
};
const
res
=
await
this
.
$u
.
api
.
addIpqc
(
param
);
const
res
=
await
this
.
$u
.
api
.
addIpqc
(
param
);
if
(
res
.
code
===
200
)
{
if
(
res
.
code
===
200
)
{
...
@@ -493,7 +491,32 @@ export default {
...
@@ -493,7 +491,32 @@ export default {
})
})
.
then
((
res
)
=>
{
.
then
((
res
)
=>
{
if
(
res
.
code
===
200
)
{
if
(
res
.
code
===
200
)
{
this
.
qcLines
=
res
.
rows
;
console
.
log
(
res
.
rows
,
'rows88999655'
)
this
.
qcLines
=
res
.
rows
.
map
(
item
=>
{
let
selectValues
=
item
.
selectValues
let
qualityCheckResults
=
item
.
qualityCheckResults
if
(
item
.
inputType
==
2
)
{
// selectValues = selectValues? JSON.parse(item.selectValues) : []
if
(
selectValues
)
{
const
data
=
JSON
.
parse
(
item
.
selectValues
)
selectValues
=
data
.
map
(
item
=>
{
return
{
text
:
item
.
name
,
value
:
item
.
name
}
})
}
else
{
selectValues
=
[]
}
qualityCheckResults
=
qualityCheckResults
?
JSON
.
parse
(
item
.
qualityCheckResults
)
:
[]
}
return
{
...
item
,
selectValues
,
qualityCheckResults
}
})
console
.
log
(
this
.
qcLines
,
'this.qcLines'
)
}
}
});
});
},
},
...
@@ -665,6 +688,13 @@ export default {
...
@@ -665,6 +688,13 @@ export default {
flex-wrap
:
nowrap
;
flex-wrap
:
nowrap
;
}
}
.line-content-item
{
width
:
100%
;
height
:
300px
;
display
:
flex
;
flex-wrap
:
nowrap
;
}
.line-table
{
.line-table
{
display
:
inline-block
;
display
:
inline-block
;
}
}
...
...
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