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
5255a0e0
Commit
5255a0e0
authored
May 21, 2024
by
张海景
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update:修改刀模板上下机参数
parent
881919ab
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
262 additions
and
259 deletions
+262
-259
index.vue
pages/mes/prodReport/index.vue
+262
-259
No files found.
pages/mes/prodReport/index.vue
View file @
5255a0e0
...
...
@@ -107,7 +107,7 @@
title=
"生产报工"
@
confirm=
"handleSubmitfeedback"
show-cancel-button
:show-confirm-button=
"feedbackForms[0]
&&feedbackForms[0].isPackage === '1'? false
: true"
:show-confirm-button=
"feedbackForms[0]
&& feedbackForms[0].isPackage === '1' ? false
: true"
:title-style=
"
{ 'background-color': '#1E3770', color: '#FFFFFF', 'line-height': '37px', 'padding-top': '0px' }"
v-model="proVisible"
width="1800rpx"
...
...
@@ -116,8 +116,8 @@
<!-- 是否包装工序isPackage为1是 -->
<scroll-view
style=
"max-height: 600px"
scroll-y=
"true"
class=
"scroll-Y"
>
<view
class=
"feedback-card"
v-for=
"(feedback, i) in feedbackForms"
:key=
"i
+
feedback.id"
>
<view
v-if=
"feedback.isPackage === '1'"
>
<view
class=
"feedback-card"
v-for=
"(feedback, i) in feedbackForms"
:key=
"i
+
feedback.id"
>
<view
v-if=
"feedback.isPackage === '1'"
>
<u-form
label-width=
"80px"
:model=
"feedback"
:rules=
"rules"
labelAlign=
"right"
>
<u-row>
<u-col
span=
"4"
>
...
...
@@ -149,7 +149,7 @@
</u-col>
<u-col
span=
"4"
>
<u-form-item
label=
"报工人:"
prop=
"nickName"
>
{{
feedback
.
nickName
}}
{{
feedback
.
nickName
}}
</u-form-item>
</u-col>
</u-row>
...
...
@@ -161,7 +161,7 @@
</u-col>
<u-col
span=
"3"
>
<u-form-item
label=
"包装单位:"
prop=
"packUnitOfMeasure"
>
{{
feedback
.
packUnitOfMeasure
}}
{{
feedback
.
packUnitOfMeasure
}}
</u-form-item>
</u-col>
<u-col
span=
"5"
>
...
...
@@ -201,7 +201,7 @@
<u-col
span=
"6"
>
<u-form-item
label=
"检测人员:"
prop=
"checkBy"
>
<u-input
disabled
v-model=
"feedback.checkBy"
></u-input>
<u-button
@
tap=
"
userVisible = true,useData = feedback;
"
type=
"success"
size=
"mini"
>
选择人员
</u-button>
<u-button
@
tap=
"
(userVisible = true), (useData = feedback)
"
type=
"success"
size=
"mini"
>
选择人员
</u-button>
</u-form-item>
</u-col>
</u-row>
...
...
@@ -215,7 +215,7 @@
<u-col
span=
"6"
>
<u-form-item
label-width=
"120px"
label=
"是否合并包装:"
prop=
"mergePack"
>
<view
class=
"uni-list-item__extra"
>
<u-radio-group
v-model=
"feedback.mergePack"
@
change=
"getWorkorderDirectiveList(feedback, i,true)"
>
<u-radio-group
v-model=
"feedback.mergePack"
@
change=
"getWorkorderDirectiveList(feedback, i,
true)"
>
<u-radio
:name=
"1"
>
是
</u-radio>
<u-radio
:name=
"0"
>
否
</u-radio>
</u-radio-group>
...
...
@@ -239,11 +239,18 @@
</
template
>
<
template
slot=
"peration"
slot-scope=
"scope"
>
<!--
{{
scope
.
row
}}
-->
<u-button
v-if=
"Number(scope.row.packageNum) > Number(scope.row.feedbackQuantity)"
@
tap=
"handleSubmitPackageFeedback(feedback, scope.row)"
type=
"success"
style=
"margin-left: 20rpx"
size=
"mini"
>
打印/报工
</u-button>
<u-button
v-if=
"Number(scope.row.packageNum) > Number(scope.row.feedbackQuantity)"
@
tap=
"handleSubmitPackageFeedback(feedback, scope.row)"
type=
"success"
style=
"margin-left: 20rpx"
size=
"mini"
>
打印/报工
</u-button>
<!--
<u-input
v-model=
"scope.row.reportQuantity"
type=
"number"
></u-input>
-->
</
template
>
</zb-table>
</view>
<!-- 指令列表 -->
<view
v-if=
"feedback.tableDirectiveData.length"
>
...
...
@@ -262,7 +269,6 @@
<!--
<u-input
v-model=
"scope.row.reportQuantity"
type=
"number"
></u-input>
-->
</
template
>
</zb-table>
</view>
<!-- SIZE列表 -->
<view
v-if=
"feedback.tableSizeData.length"
>
...
...
@@ -343,10 +349,8 @@
</u-row>
</u-form>
</view>
</view>
</scroll-view>
</view>
</u-modal>
<u-modal
...
...
@@ -384,15 +388,15 @@
:title-style=
"{ 'background-color': '#1E3770', color: '#FFFFFF', 'line-height': '37px', 'padding-top': '0px' }"
v-model=
"knifeTempVisible"
width=
"100%"
:content-style=
"{
height: '87vh'
}"
:content-style=
"{
height: '87vh'
}"
>
<view
style=
"display: flex
;
"
>
<view
style=
"width:
520px;
"
>
<view
style=
"display: flex"
>
<view
style=
"width:
520px
"
>
<!-- #ifdef APP-PLUS -->
<app-scan
v-if=
"knifeTempAppScanVisible"
ref=
"appScan"
@
getCode=
"handleUpdateKnifeTemp"
></app-scan>
<!-- #endif -->
</view>
<dModelList
:data=
"dModelData"
@
action=
"upDownGetList"
@
scan=
"handleAppScanKnifeTemp"
/>
<dModelList
:data=
"dModelData"
@
action=
"upDownGetList"
@
scan=
"handleAppScanKnifeTemp"
/>
</view>
</u-modal>
<!-- //生产报工报工人员 -->
...
...
@@ -480,17 +484,17 @@
</u-modal>
<u-modal
title=
"投料校验"
@
cancel=
"$refs.appScan.closed()
, feedingInspectionVisible = false
"
@
cancel=
"$refs.appScan.closed()
, (feedingInspectionVisible = false)
"
show-cancel-button
cancelText=
"关闭"
:show-confirm-button=
"false"
:title-style=
"{ 'background-color': '#1E3770', color: '#FFFFFF', 'line-height': '37px', 'padding-top': '0px' }"
v-model=
"feedingInspectionVisible"
width=
"100%"
:content-style=
"{
height: '87vh'
}"
:content-style=
"{
height: '87vh'
}"
>
<view
style=
"display: flex
;
"
>
<view
style=
"width:
520px;
"
v-if=
"feedingInspectionVisible"
>
<view
style=
"display: flex"
>
<view
style=
"width:
520px
"
v-if=
"feedingInspectionVisible"
>
<!-- #ifdef APP-PLUS -->
<app-scan
ref=
"appScan"
@
getCode=
"feedingInspectionScan"
></app-scan>
<!-- #endif -->
...
...
@@ -521,23 +525,22 @@
</uni-table>
</scroll-view>
</view>
</view>
</u-modal>
<u-modal
title=
"反冲料登记"
@
cancel=
"$refs.appScan.closed()
, recoilMaterialVisible = false
"
@
cancel=
"$refs.appScan.closed()
, (recoilMaterialVisible = false)
"
show-cancel-button
cancelText=
"关闭"
:show-confirm-button=
"false"
:title-style=
"{ 'background-color': '#1E3770', color: '#FFFFFF', 'line-height': '37px', 'padding-top': '0px' }"
v-model=
"recoilMaterialVisible"
width=
"100%"
:content-style=
"{
height: '87vh'
}"
:content-style=
"{
height: '87vh'
}"
>
<view
style=
"display: flex
;
"
>
<view
style=
"width:
520px;
"
v-if=
"recoilMaterialVisible"
>
<view
style=
"display: flex"
>
<view
style=
"width:
520px
"
v-if=
"recoilMaterialVisible"
>
<!-- #ifdef APP-PLUS -->
<app-scan
ref=
"appScan"
@
getCode=
"recoilMaterialScan"
></app-scan>
<!-- #endif -->
...
...
@@ -856,7 +859,7 @@ import UButton from '../../../uview-ui/components/u-button/u-button.vue';
import
cameraAuthMixin
from
'@/components/AppScan/appScanMixins.js'
;
import
{
handleError
}
from
'vue'
;
import
AppScan
from
'../../../components/AppScan/AppScan.vue'
;
import
{
debounce
}
from
'@/utils/ruoyi'
import
{
debounce
}
from
'@/utils/ruoyi'
;
export
default
{
name
:
'ProdReport'
,
dicts
:
[
'pro_pack_type'
,
'sap_yes_no'
],
...
...
@@ -1374,36 +1377,36 @@ export default {
methods
:
{
handleChangePackNum
(
feedback
,
i
)
{
if
(
this
.
getWorkorderDirectiveLoading
)
{
return
return
;
}
debounce
(
this
.
getWorkorderDirectiveList
(
feedback
,
i
,
true
),
30000
)
debounce
(
this
.
getWorkorderDirectiveList
(
feedback
,
i
,
true
),
30000
);
},
handleSubmitConfirmlKnifeTemp
()
{
this
.
knifeTempVisible
=
true
this
.
$refs
.
appScan
.
closed
()
this
.
knifeTempAppScanVisible
=
false
this
.
knifeTempCancelText
=
'确认'
this
.
knifeTempType
=
null
this
.
knifeTempVisible
=
true
;
this
.
$refs
.
appScan
.
closed
()
;
this
.
knifeTempAppScanVisible
=
false
;
this
.
knifeTempCancelText
=
'确认'
;
this
.
knifeTempType
=
null
;
},
handleSubmitCancelKnifeTemp
()
{
this
.
knifeTempVisible
=
true
this
.
$refs
.
appScan
.
closed
()
this
.
knifeTempAppScanVisible
=
false
this
.
knifeTempCancelText
=
'取消'
this
.
knifeTempVisible
=
true
;
this
.
$refs
.
appScan
.
closed
()
;
this
.
knifeTempAppScanVisible
=
false
;
this
.
knifeTempCancelText
=
'取消'
;
},
handleAppScanKnifeTemp
(
type
)
{
this
.
knifeTempAppScanVisible
=
true
this
.
knifeTempType
=
type
this
.
knifeTempCancelText
=
type
===
'1'
?
'关闭上机扫描'
:
'关闭下机扫描'
this
.
getPemissionScan
()
this
.
knifeTempAppScanVisible
=
true
;
this
.
knifeTempType
=
type
;
this
.
knifeTempCancelText
=
type
===
'1'
?
'关闭上机扫描'
:
'关闭下机扫描'
;
this
.
getPemissionScan
()
;
},
handleUpdateKnifeTemp
(
code
)
{
console
.
log
({
type
:
this
.
knifeTempType
,
sn
:
code
,
task
_workunt_id
:
this
.
tableSelectData
[
0
].
taskWorkunitId
},
code
,
'code---handleUpdateKnifeTemp'
)
this
.
$u
.
api
.
dModel
.
tmToolMachinesScancode
({
type
:
this
.
knifeTempType
,
sn
:
code
,
task
_workunt_i
d
:
this
.
tableSelectData
[
0
].
taskWorkunitId
}).
then
((
res
)
=>
{
console
.
log
(
res
,
'res333'
)
console
.
log
({
type
:
this
.
knifeTempType
,
sn
:
code
,
task
WorkunitId
:
this
.
tableSelectData
[
0
].
taskWorkunitId
},
code
,
'code---handleUpdateKnifeTemp'
);
this
.
$u
.
api
.
dModel
.
tmToolMachinesScancode
({
type
:
this
.
knifeTempType
,
sn
:
code
,
task
WorkunitI
d
:
this
.
tableSelectData
[
0
].
taskWorkunitId
}).
then
((
res
)
=>
{
console
.
log
(
res
,
'res333'
)
;
if
(
res
.
code
===
200
)
{
this
.
$u
.
toast
(
this
.
knifeTempType
===
'1'
?
'上机成功'
:
'下机成功'
)
this
.
upDownGetList
()
this
.
$u
.
toast
(
this
.
knifeTempType
===
'1'
?
'上机成功'
:
'下机成功'
);
this
.
upDownGetList
()
;
}
});
},
...
...
@@ -1478,13 +1481,15 @@ export default {
if
(
item
.
status
===
'BEGINNING'
)
{
status
=
true
;
}
else
{
this
.
$u
.
api
.
changeCheckMachineTool
({
this
.
$u
.
api
.
changeCheckMachineTool
({
taskWorkunitId
:
item
.
taskWorkunitId
}).
then
(
res
=>
{
if
(
res
.
code
===
200
)
{
})
.
then
((
res
)
=>
{
if
(
res
.
code
===
200
)
{
this
.
changeStatus
(
item
.
taskId
,
item
.
taskWorkunitId
,
'BEGINNING'
,
item
.
workunitId
,
false
);
}
})
});
}
});
if
(
status
)
{
...
...
@@ -1505,7 +1510,7 @@ export default {
case
'Prod'
:
if
(
this
.
tableSelectData
[
0
].
status
===
'PREPARE'
)
{
this
.
$u
.
toast
(
'工序未开工'
);
return
return
;
}
this
.
doFeedback
();
break
;
...
...
@@ -1612,7 +1617,7 @@ export default {
// workunitName: this.vuex_workunit.workunitName,
// processId: selectData.processId,
// taskId: selectData.taskId,
taskWorkunitId
:
selectData
.
taskWorkunitId
,
taskWorkunitId
:
selectData
.
taskWorkunitId
// workorderId: selectData.workorderId,
// toolRequestUseId: data[0].toolRequestUseId,
// toolMachinesRecordList: data.map((v) => {
...
...
@@ -1685,16 +1690,16 @@ export default {
row
.
tableSizeColumn
=
[];
row
.
tableSizeData
=
[];
row
.
tableOrderData
=
[];
row
.
packNum
=
''
row
.
packType
=
''
row
.
packUnitOfMeasure
=
''
row
.
lossIndividuallyWrap
=
undefined
row
.
currentTabPro
=
0
row
.
packNum
=
''
;
row
.
packType
=
''
;
row
.
packUnitOfMeasure
=
''
;
row
.
lossIndividuallyWrap
=
undefined
;
row
.
currentTabPro
=
0
;
return
;
}
else
{
if
(
row
.
isPackage
===
'1'
)
{
row
.
packNum
=
items
.
usagePackNum
row
.
encasementNum
=
items
.
usageEncasementNum
row
.
packNum
=
items
.
usagePackNum
;
row
.
encasementNum
=
items
.
usageEncasementNum
;
this
.
getWorkorderDirectiveList
(
id
,
index
);
}
}
...
...
@@ -1800,11 +1805,11 @@ export default {
text
:
temp
.
workorderCode
};
});
if
(
item
.
isPackage
===
'1'
&&
res
.
rows
.
length
>
0
)
{
item
.
workorderId
=
res
.
rows
[
0
].
workorderId
item
.
packNum
=
res
.
rows
[
0
].
usagePackNum
item
.
encasementNum
=
res
.
rows
[
0
].
usageEncasementNum
this
.
getWorkorderDirectiveList
(
res
.
rows
[
0
].
workorderId
,
index
)
if
(
item
.
isPackage
===
'1'
&&
res
.
rows
.
length
>
0
)
{
item
.
workorderId
=
res
.
rows
[
0
].
workorderId
;
item
.
packNum
=
res
.
rows
[
0
].
usagePackNum
;
item
.
encasementNum
=
res
.
rows
[
0
].
usageEncasementNum
;
this
.
getWorkorderDirectiveList
(
res
.
rows
[
0
].
workorderId
,
index
)
;
}
});
},
...
...
@@ -1960,11 +1965,11 @@ export default {
},
doFeedback
()
{
// this.reset();
console
.
log
(
this
.
dict
.
type
,
'this.dicts.type'
)
console
.
log
(
this
.
dict
.
type
,
'this.dicts.type'
)
;
this
.
feedbackForms
=
[];
let
flagPackage
=
[]
let
flagPackage
=
[]
;
this
.
tableSelectData
.
forEach
((
item
,
index
)
=>
{
flagPackage
.
push
(
item
.
isPackage
===
'1'
)
flagPackage
.
push
(
item
.
isPackage
===
'1'
)
;
let
defQualify
=
item
.
quantity
-
item
.
quantityQualify
-
item
.
quantityUnqualify
;
defQualify
=
defQualify
<
0
?
0
:
defQualify
;
defQualify
=
defQualify
>
item
.
quantityWait
?
item
.
quantityWait
:
defQualify
;
...
...
@@ -2051,101 +2056,101 @@ export default {
tableOrderData
:
[],
tableDirectiveData
:
[],
currentTabPro
:
0
,
packNum
:
0
,
packNum
:
0
,
encasementNum
:
0
,
mergePack
:
0
};
this
.
getWorkorderWithSizeAndDirective
(
feedback
,
index
);
this
.
feedbackForms
.
push
(
feedback
);
});
console
.
log
(
flagPackage
,
Array
.
from
(
new
Set
(
flagPackage
)))
console
.
log
(
flagPackage
,
Array
.
from
(
new
Set
(
flagPackage
)))
;
if
(
Array
.
from
(
new
Set
(
flagPackage
)).
length
===
2
)
{
this
.
$u
.
toast
(
'包装工序禁止多选报工'
)
return
this
.
$u
.
toast
(
'包装工序禁止多选报工'
)
;
return
;
}
// 如果选择了包装工序、非包装工序提示:“包装工序禁止多选报工”
this
.
proVisible
=
true
;
},
// 获取指令列表
getWorkorderDirectiveList
(
rows
,
index
,
flag
)
{
this
.
getWorkorderDirectiveLoading
=
true
this
.
getWorkorderDirectiveLoading
=
true
;
let
row
=
this
.
feedbackForms
[
index
];
this
.
$u
.
api
.
workOrderSoDirectiveApi
({
"encasementNum"
:
row
.
encasementNum
,
"mergePack"
:
row
.
mergePack
||
0
,
"packNum"
:
row
.
packNum
,
"quantity"
:
row
.
quantity
,
"taskId"
:
row
.
taskId
,
"workorderId"
:
row
.
workorderId
encasementNum
:
row
.
encasementNum
,
mergePack
:
row
.
mergePack
||
0
,
packNum
:
row
.
packNum
,
quantity
:
row
.
quantity
,
taskId
:
row
.
taskId
,
workorderId
:
row
.
workorderId
})
.
then
((
res
)
=>
{
console
.
log
(
res
,
'88999res'
);
this
.
getWorkorderDirectiveLoading
=
false
this
.
getWorkorderDirectiveLoading
=
false
;
if
(
res
.
code
===
200
)
{
this
.
copyFeedBackForms
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
feedbackForms
))
console
.
log
(
this
.
copyFeedBackForms
,
'this.copyFeedBackForms88999'
)
if
(
res
.
data
.
directiveList
)
{
row
.
tableDirectiveData
=
res
.
data
.
directiveList
.
map
(
item
=>
{
this
.
copyFeedBackForms
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
feedbackForms
))
;
console
.
log
(
this
.
copyFeedBackForms
,
'this.copyFeedBackForms88999'
);
if
(
res
.
data
.
directiveList
)
{
row
.
tableDirectiveData
=
res
.
data
.
directiveList
.
map
(
(
item
)
=>
{
return
{
...
item
,
reportQuantity
:
Number
(
item
.
packageNum
)
||
0
-
Number
(
item
.
feedbackQuantity
)
||
0
}
})
}
;
})
;
row
.
listTabPro
=
[
{
name
:
'指令列表'
}
]
]
;
}
else
{
row
.
tableDirectiveData
=
[]
row
.
tableDirectiveData
=
[]
;
}
if
(
res
.
data
.
orderPackageList
)
{
row
.
tableOrderData
=
res
.
data
.
orderPackageList
.
map
(
item
=>
{
if
(
res
.
data
.
orderPackageList
)
{
row
.
tableOrderData
=
res
.
data
.
orderPackageList
.
map
(
(
item
)
=>
{
return
{
...
item
,
reportQuantity
:
Number
(
item
.
packageNum
)
||
0
-
Number
(
item
.
feedbackQuantity
)
||
0
}
})
}
;
})
;
row
.
listTabPro
=
[
{
name
:
'报工列表'
}
]
]
;
}
else
{
row
.
tableOrderData
=
[]
row
.
tableOrderData
=
[]
;
}
if
(
res
.
data
.
sizeList
)
{
row
.
tableSizeData
=
res
.
data
.
sizeList
.
map
(
item
=>
{
if
(
res
.
data
.
sizeList
)
{
row
.
tableSizeData
=
res
.
data
.
sizeList
.
map
(
(
item
)
=>
{
return
{
...
item
,
reportQuantity
:
Number
(
item
.
packageNum
)
||
0
-
Number
(
item
.
feedbackQuantity
)
||
0
}
})
}
;
})
;
row
.
listTabPro
=
[
{
name
:
'SIZE列表'
}
]
row
.
tableSizeColumn
[
1
].
label
=
res
.
data
.
sizeColumnName
]
;
row
.
tableSizeColumn
[
1
].
label
=
res
.
data
.
sizeColumnName
;
}
else
{
row
.
tableSizeData
=
[]
row
.
tableSizeData
=
[]
;
}
}
else
{
if
(
flag
)
{
console
.
log
(
this
.
copyFeedBackForms
,
'this.copyFeedBackForms'
)
console
.
log
(
this
.
copyFeedBackForms
,
'this.copyFeedBackForms'
);
// this.$set(this.feedbackForms, index, this.copyFeedBackForms[index])
this
.
$set
(
this
.
feedbackForms
[
index
],
'packNum'
,
this
.
copyFeedBackForms
[
index
].
packNum
)
this
.
$set
(
this
.
feedbackForms
[
index
],
'encasementNum'
,
this
.
copyFeedBackForms
[
index
].
encasementNum
)
this
.
$set
(
this
.
feedbackForms
[
index
],
'mergePack'
,
this
.
copyFeedBackForms
[
index
].
mergePack
)
console
.
log
(
this
.
feedbackForms
[
index
],
'889row'
)
this
.
$set
(
this
.
feedbackForms
[
index
],
'packNum'
,
this
.
copyFeedBackForms
[
index
].
packNum
)
;
this
.
$set
(
this
.
feedbackForms
[
index
],
'encasementNum'
,
this
.
copyFeedBackForms
[
index
].
encasementNum
)
;
this
.
$set
(
this
.
feedbackForms
[
index
],
'mergePack'
,
this
.
copyFeedBackForms
[
index
].
mergePack
)
;
console
.
log
(
this
.
feedbackForms
[
index
],
'889row'
)
;
}
console
.
log
(
88999
)
console
.
log
(
88999
)
;
}
})
})
;
},
handleSubmitPackageFeedback
(
item
,
row
)
{
if
((
item
.
printTemplate
)
&&
!
this
.
vuex_printConnect
)
{
if
(
item
.
printTemplate
&&
!
this
.
vuex_printConnect
)
{
this
.
$u
.
toast
(
'打印机连接失败'
);
return
;
}
...
...
@@ -2171,7 +2176,7 @@ export default {
.
then
((
res
)
=>
{
if
(
res
.
code
===
200
)
{
// this.proVisible = false;
item
.
quantityUnqualify
=
0
item
.
quantityUnqualify
=
0
;
if
(
item
.
printTemplate
)
{
let
params
=
{};
res
.
data
.
forEach
((
datas
)
=>
{
...
...
@@ -2212,9 +2217,9 @@ export default {
label
:
element
};
if
(
key
===
'reportQuantity'
)
{
obj
.
width
=
130
obj
.
type
=
'slot'
obj
.
slot
=
'reportQuantity'
obj
.
width
=
130
;
obj
.
type
=
'slot'
;
obj
.
slot
=
'reportQuantity'
;
}
columns
.
push
(
obj
);
}
...
...
@@ -2306,7 +2311,7 @@ export default {
netWeight
:
item
.
netWeight
,
feedbackTime
:
item
.
feedbackTime
,
minPackageNum
:
item
.
minPackageNum
,
printContents
:
item
.
whether
==
'1'
?
item
.
printContents
:
null
,
printContents
:
item
.
whether
==
'1'
?
item
.
printContents
:
null
})
.
then
((
res
)
=>
{
if
(
res
.
code
===
200
)
{
...
...
@@ -2353,7 +2358,7 @@ export default {
},
feedingInspectionShow
()
{
this
.
feedingInspectionVisible
=
true
;
this
.
getPemissionScan
()
this
.
getPemissionScan
()
;
this
.
feedingInspectionLoadAndScan
();
},
feedingInspectionLoadAndScan
(
bool
)
{
...
...
@@ -2368,7 +2373,7 @@ export default {
});
},
feedingInspectionScan
(
barNumber
)
{
console
.
log
(
barNumber
,
'-----barNumberfeedingInspectionScan'
)
console
.
log
(
barNumber
,
'-----barNumberfeedingInspectionScan'
)
;
const
taskInfo
=
this
.
tableSelectData
[
0
];
this
.
$u
.
api
.
validateFeedingInspection
({
plnr
:
barNumber
,
taskId
:
taskInfo
.
taskId
}).
then
((
res
)
=>
{
if
(
res
.
code
===
200
)
{
...
...
@@ -2379,12 +2384,12 @@ export default {
async
getPemissionScan
()
{
/* #ifdef APP-PLUS */
if
(
!
uni
.
getStorageSync
(
'iosCameraAuth'
)
&&
this
.
isIos
)
{
uni
.
setStorageSync
(
'iosCameraAuth'
,
true
)
uni
.
setStorageSync
(
'iosCameraAuth'
,
true
);
}
else
{
let
bol
=
await
this
.
getCameraAuth
()
let
bol
=
await
this
.
getCameraAuth
();
if
(
!
bol
)
{
this
.
refusedCameraAuth
()
return
this
.
refusedCameraAuth
();
return
;
}
}
/* #endif */
...
...
@@ -2404,7 +2409,7 @@ export default {
},
recoilMaterialShow
()
{
this
.
recoilMaterialVisible
=
true
;
this
.
getPemissionScan
()
this
.
getPemissionScan
()
;
this
.
recoilMaterialLoadAndScan
();
},
recoilMaterialLoadAndScan
(
bool
)
{
...
...
@@ -2420,14 +2425,13 @@ export default {
});
},
recoilMaterialScan
(
barNumber
)
{
console
.
log
(
barNumber
,
'-----barNumberrecoilMaterialScan'
)
console
.
log
(
barNumber
,
'-----barNumberrecoilMaterialScan'
)
;
const
taskInfo
=
this
.
tableSelectData
[
0
];
this
.
$u
.
api
.
addRecoilMaterial
({
taskId
:
taskInfo
.
taskId
,
plnr
:
barNumber
}).
then
((
res
)
=>
{
if
(
res
.
code
===
200
)
{
this
.
recoilMaterialLoadAndScan
(
true
);
}
});
},
recoilMaterialDelete
(
line
)
{
const
t
=
this
;
...
...
@@ -2449,15 +2453,14 @@ export default {
});
this
.
$u
.
api
.
listMaterialRequest
({
taskId
:
taskInfo
.
taskId
}).
then
((
res
)
=>
{
if
(
res
.
code
===
200
)
{
this
.
materialRequestList
=
res
.
data
.
map
(
item
=>
{
this
.
materialRequestList
=
res
.
data
.
map
(
(
item
)
=>
{
return
{
...
item
,
workorderCode
:
this
.
curTaskInfo
.
workorderCode
}
})
};
});
this
.
materialRequestArrays
=
this
.
materialRequestList
.
concat
([]);
}
});
},
materialRequestFormShow
(
line
)
{
...
...
@@ -2541,20 +2544,20 @@ export default {
this
.
materialRequestArrays
=
this
.
materialRequestList
.
concat
([]);
}
else
{
const
items
=
this
.
curTaskInfo
.
workorderOption
.
find
((
item
)
=>
item
.
value
===
this
.
curTaskInfo
.
workorderCode
);
console
.
log
(
items
)
console
.
log
(
items
);
this
.
$u
.
api
.
getWproworkOrderProcessItem
({
workorderId
:
id
,
processId
:
this
.
curTaskInfo
.
processId
}).
then
((
res
)
=>
{
if
(
res
.
code
===
200
)
{
const
list
=
res
.
rows
.
map
(
item
=>
{
const
list
=
res
.
rows
.
map
((
item
)
=>
{
return
{
...
item
,
workorderCode
:
items
.
text
}
})
};
});
this
.
materialRequests
=
this
.
materialRequestList
.
concat
(
list
);
this
.
materialRequestArrays
=
this
.
materialRequests
.
filter
((
item
,
index
,
self
)
=>
{
return
self
.
findIndex
(
t
=>
t
.
itemCode
===
item
.
itemCode
)
===
index
;
});
console
.
log
(
materialRequestArrays
,
'materialRequestArrays'
)
return
self
.
findIndex
((
t
)
=>
t
.
itemCode
===
item
.
itemCode
)
===
index
;
});
console
.
log
(
materialRequestArrays
,
'materialRequestArrays'
);
}
});
}
...
...
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