Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
mes-ui
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
周远喜
mes-ui
Commits
e9f50b41
Commit
e9f50b41
authored
Apr 20, 2020
by
康振飞
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
班组派工删除拆分
parent
0621929b
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
10 deletions
+20
-10
api.js
pages/aps/dispatch/api.js
+5
-1
index.vue
pages/aps/dispatch/index.vue
+15
-9
No files found.
pages/aps/dispatch/api.js
View file @
e9f50b41
...
...
@@ -25,7 +25,11 @@ export default {
saveTeamentry
(
params
){
return
Api
.
post
(
`
${
PlanUrl
}
/teamsdispatchs/saveteamentry`
,
params
);
},
//删除:
// 删除拆分项
deleteItem
(
params
){
return
Api
.
get
(
`
${
PlanUrl
}
/teamsdispatchs/deldispatch`
,
params
);
},
//删除:
delete
(
params
)
{
return
Api
.
delete
(
`
${
PlanUrl
}
/mesorder/delete`
,
{
params
:
params
...
...
pages/aps/dispatch/index.vue
View file @
e9f50b41
...
...
@@ -537,7 +537,6 @@ export default {
u
.
remark
=
this
.
entity
.
remark
u
.
equipId
=
this
.
shebeiId
})
// console.log(item)
this
.
$refs
[
'formValidate'
].
validate
((
valid
)
=>
{
if
(
valid
){
Api
.
saveTeamentry
(
item
).
then
((
res
)
=>
{
...
...
@@ -587,19 +586,17 @@ export default {
this
.
chaiNum
=
1
this
.
maxnum
=
item
.
quantity
-
1
this
.
rowIndex
=
index
// this.chaiId = item.id
},
okChai
()
{
var
detail
=
this
.
$u
.
clone
(
this
.
listTask
[
this
.
rowIndex
])
this
.
listTask
[
this
.
rowIndex
].
quantity
-=
this
.
chaiNum
detail
.
pid
=
detail
.
id
detail
.
id
=
0
// detail.pid = this.chaiId
// detail.pid = this.$u.guid()
detail
.
quantity
=
this
.
chaiNum
this
.
listTask
.
splice
(
this
.
rowIndex
+
1
,
0
,
detail
)
console
.
log
(
"拆分后数据"
,
this
.
listTask
)
this
.
saveFameData
()
this
.
getUserInfoFn
()
},
// 拆分保存
saveFameData
()
{
...
...
@@ -617,11 +614,20 @@ export default {
},
// 删除行
removeDetail
(
item
,
index
)
{
let
oldList
=
this
.
listTask
;
let
clickRow
=
oldList
.
filter
(
listRow
=>
listRow
.
process_name
===
item
.
process_name
)[
0
];
clickRow
.
quantity
+=
this
.
chaiNum
this
.
listTask
.
splice
(
index
,
1
)
this
.
$Message
.
success
(
'拆分项已删除。'
)
let
delid
=
{
id
:
item
.
id
}
Api
.
deleteItem
(
delid
).
then
((
res
)
=>
{
if
(
res
.
success
)
{
this
.
$Message
.
success
(
'拆分项已删除。'
)
this
.
getUserInfoFn
()
}
else
{
this
.
$Message
.
error
(
'拆分项删除失败!'
)
}
})
// let oldList = this.listTask;
// let clickRow = oldList.filter(listRow=>listRow.process_name===item.process_name)[0];
// clickRow.quantity += this.chaiNum
// this.listTask.splice(index, 1)
// this.$Message.success('拆分项已删除。')
},
cancle
()
{
//取消
this
.
facilityModal
=
false
...
...
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