Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
M
mes-ui
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
mes
mes-ui
Commits
9e2fefe9
Commit
9e2fefe9
authored
Dec 04, 2024
by
沈翠玲
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
生产报工增加补打
parent
7d5977ab
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
37 additions
and
26 deletions
+37
-26
feedback.js
src/api/mes/pro/feedback.js
+9
-0
index.vue
src/views/mes/pro/feedback/index.vue
+28
-26
No files found.
src/api/mes/pro/feedback.js
View file @
9e2fefe9
...
...
@@ -35,6 +35,15 @@ export function addFeedback(data) {
})
}
//
export
function
taskWorkunitInfo
(
data
)
{
return
request
({
url
:
'/mes/pro/workorder/taskWorkunitInfo'
,
method
:
'post'
,
data
:
data
})
}
// 修改生产报工记录
export
function
updateFeedback
(
data
)
{
return
request
({
...
...
src/views/mes/pro/feedback/index.vue
View file @
9e2fefe9
...
...
@@ -91,6 +91,8 @@
<
template
slot
-
scope
=
"scope"
>
<
el
-
button
size
=
"mini"
type
=
"text"
icon
=
"el-icon-query"
@
click
=
"handleView(scope.row)"
v
-
hasPermi
=
"['mes:pro:feedback:query']"
>
查看
<
/el-button
>
<
el
-
button
size
=
"mini"
type
=
"text"
@
click
=
"handleQrcode(scope.row)"
v
-
if
=
"!scope.isPackage"
v
-
hasPermi
=
"['mes:pro:feedback:print']"
>
补打
<
/el-button
>
<!--
<
el
-
button
size
=
"mini"
type
=
"text"
icon
=
"el-icon-edit"
@
click
=
"handleUpdate(scope.row)"
v
-
hasPermi
=
"['mes:pro:feedback:edit']"
>
修改
<
/el-button
>
<
el
-
button
size
=
"mini"
type
=
"text"
icon
=
"el-icon-delete"
@
click
=
"handleDelete(scope.row)"
...
...
@@ -251,7 +253,7 @@
<
/template
>
<
script
>
import
{
listFeedback
,
getFeedback
,
delFeedback
,
addFeedback
,
updateFeedback
,
execute
,
listNextProcess
}
from
"@/api/mes/pro/feedback"
;
import
{
listFeedback
,
getFeedback
,
delFeedback
,
addFeedback
,
updateFeedback
,
execute
,
listNextProcess
,
taskWorkunitInfo
}
from
"@/api/mes/pro/feedback"
;
import
WorkorderSelect
from
"@/components/workorderSelect/single.vue"
import
WorkstationSelect
from
"@/components/workstationSelect/simpletableSingle.vue"
import
UserSingleSelect
from
"@/components/userSelect/single.vue"
...
...
@@ -550,34 +552,34 @@ export default {
}
,
/** 二维码打印 */
handleQrcode
(
)
{
async
handleQrcode
(
row
)
{
let
workunitName
=
''
;
let
detail
=
[]
if
(
this
.
selectRow
.
some
(
v
=>
v
.
qrcode
!=
null
)){
this
.
$message
.
warning
(
'该数据是包装工序的报工,不能打印二维码'
)
return
const
res
=
await
taskWorkunitInfo
({
taskWorkunitId
:
row
.
taskWorkunitId
}
)
let
operNo
=
0
if
(
res
.
code
===
200
)
{
operNo
=
res
.
data
.
operNo
}
this
.
selectRow
.
forEach
((
s
,
i
)
=>
{
listNextProcess
({
taskId
:
s
.
taskId
}
).
then
(
workunit
=>
{
workunitName
=
workunit
.
data
.
workunitName
;
detail
.
push
({
"barcode"
:
s
.
workorderCode
,
"showText"
:
'编排单号'
+
s
.
arrangeCode
+
'
\
n工单号'
+
s
.
workorderCode
+
'
\
n数量'
+
s
.
quantityQualify
+
'
\
n下道工序机台:'
+
workunitName
,
"gp"
:
i
+
1
}
)
detail
.
push
({
"barcode"
:
s
.
workorderCode
,
"showText"
:
'编排单号'
+
s
.
arrangeCode
+
'
\
n工单号'
+
s
.
workorderCode
+
'
\
n数量'
+
s
.
quantityQualify
+
'
\
n下道工序机台:'
+
workunitName
,
"gp"
:
i
+
1
}
)
postPrintPdf
(
"qrcode-50*50-2"
,
{
detail
}
);
}
);
listNextProcess
({
taskId
:
row
.
taskId
}
).
then
(
workunit
=>
{
workunitName
=
workunit
.
data
.
workunitName
;
detail
.
push
({
"barcode"
:
row
.
workorderCode
,
showText
:
'编排单号:'
+
row
.
arrangeCode
+
'
\
n报工次数:'
+
operNo
+
'
\
n数量:'
+
row
.
quantityQualify
+
'
\
n工单号:'
+
row
.
workorderCode
+
'
\
n下道工序机台:'
+
workunitName
,
"gp"
:
1
}
)
detail
.
push
({
"barcode"
:
row
.
workorderCode
,
showText
:
'编排单号:'
+
row
.
arrangeCode
+
'
\
n报工次数:'
+
operNo
+
'
\
n数量:'
+
row
.
quantityQualify
+
'
\
n工单号:'
+
row
.
workorderCode
+
'
\
n下道工序机台:'
+
workunitName
,
"gp"
:
1
}
)
postPrintPdf
(
"qrcode-50*50-2"
,
{
detail
}
);
}
);
}
,
...
...
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