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
a9654517
Commit
a9654517
authored
May 15, 2020
by
renjintao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ordersend
parent
f978979b
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
139 additions
and
20 deletions
+139
-20
orderSend.vue
components/orderOperator/orderSend.vue
+3
-0
api.js
pages/order/monitoring/api.js
+3
-0
index.vue
pages/order/monitoring/index.vue
+133
-20
No files found.
components/orderOperator/orderSend.vue
View file @
a9654517
...
...
@@ -304,6 +304,9 @@ export default {
},
getTimeQuotationFD
(
value
)
{
this
.
orderForm
.
QuotationFinishDate
=
value
;
},
p
(
s
)
{
return
s
<
10
?
"0"
+
s
:
s
;
}
},
created
()
{
...
...
pages/order/monitoring/api.js
View file @
a9654517
...
...
@@ -35,6 +35,9 @@ export default {
pauseCauseGetpaged
(
params
){
//获取工单暂停记录
return
Api
.
get
(
`
${
PlanUrl
}
/orderexecutepausecause/getpaged`
,
params
);
},
orderrecovery
(
params
)
{
//订单回收
return
Api
.
post
(
`
${
PlanUrl
}
/mesorders/orderrecovery`
,
params
);
},
// getplantdepartments(params) {// 组织为”车间“的部门
// return Api.get(`${systemUrl}/department/getplantdepartments`, params);
...
...
pages/order/monitoring/index.vue
View file @
a9654517
...
...
@@ -30,6 +30,29 @@
<Modal
v-model=
"SpeedModal"
title=
"工单信息"
fullscreen
footer-hide
class=
"recordM"
>
<Speed
:result=
"result"
:load=
"loading"
:executeId=
"dispatchExecuteId"
:orderId=
"orderId"
/>
</Modal>
<Modal
v-model=
"recycleModal"
title=
"确定回收订单"
width=
"600"
class=
"suspend"
>
<Form
ref=
"form"
:model=
"recovery"
:rules=
"rulesRecycle"
:label-width=
"120"
>
<Row>
<Col
:span=
"24"
>
<FormItem
:label=
"l('mesCode')"
>
{{mesCode}}
</FormItem>
</Col>
<Col
:span=
"24"
>
<FormItem
:label=
"l('demandFinishDate')"
prop=
"demandFinishDate"
>
<DatePicker
type=
"date"
placeholder=
"请选择日期"
style=
"width:240px"
v-model=
"recovery.demandFinishDate"
></DatePicker>
</FormItem>
</Col>
</Row>
</Form>
<div
slot=
"footer"
>
<Button
@
click=
"cancelRecycle"
>
取消
</Button>
<Button
type=
"primary"
@
click=
"changeFinishiDate"
>
确定
</Button>
</div>
</Modal>
</div>
</template>
<
script
>
...
...
@@ -50,8 +73,8 @@ export default {
data
()
{
return
{
result
:
[],
dispatchExecuteId
:
null
,
//任务id
orderId
:
null
,
//订单id
dispatchExecuteId
:
null
,
//任务id
orderId
:
null
,
//订单id
SpeedModal
:
false
,
rowSuspend
:
{},
recordId
:
0
,
...
...
@@ -64,6 +87,7 @@ export default {
suspendModal
:
false
,
recordModal
:
false
,
deletelModal
:
false
,
recycleModal
:
false
,
curId
:
0
,
columns
:
[
{
key
:
"id"
,
title
:
this
.
l
(
"id"
),
hide
:
true
,
align
:
"left"
},
...
...
@@ -175,7 +199,7 @@ export default {
title
:
this
.
l
(
"productName"
),
align
:
"left"
,
easy
:
true
,
high
:
true
,
high
:
true
},
{
...
...
@@ -245,7 +269,7 @@ export default {
code
:
"mes_xingchi_plan.order_material.routingType"
,
easy
:
true
,
high
:
true
,
width
:
100
,
width
:
100
},
{
title
:
this
.
l
(
"jindu"
),
...
...
@@ -334,7 +358,7 @@ export default {
key
:
"remark"
,
title
:
this
.
l
(
"remark"
),
align
:
"center"
,
hide
:
true
hide
:
true
},
{
title
:
"暂停记录"
,
...
...
@@ -362,7 +386,9 @@ export default {
render
:
(
h
,
params
)
=>
{
return
h
(
"div"
,
{
class
:
"action"
},
[
h
(
params
.
row
.
status
==
5
&&
params
.
row
.
upSplitId
==
0
?
"Button"
:
""
,
//订单状态暂停,启动
params
.
row
.
status
==
5
&&
params
.
row
.
upSplitId
==
0
?
"Button"
:
""
,
//订单状态暂停,启动
{
props
:
{
type
:
"error"
,
...
...
@@ -385,13 +411,16 @@ export default {
""
),
h
(
params
.
row
.
status
==
6
&&
params
.
row
.
upSplitId
==
0
?
"Button"
:
""
,
//订单状态执行中,暂停
params
.
row
.
status
==
6
&&
params
.
row
.
upSplitId
==
0
?
"Button"
:
""
,
//订单状态执行中,暂停
{
props
:
{
type
:
"success"
,
size
:
"small"
,
icon
:
"ios-pause"
,
ghost
:
true
ghost
:
true
,
tooltip
:
"暂停"
},
style
:
{
fontSize
:
"18px"
,
...
...
@@ -406,12 +435,44 @@ export default {
}
},
""
),
h
(
params
.
row
.
status
==
5
&&
params
.
row
.
upSplitId
>
0
?
"op"
:
""
,
//订单状态执行中,暂停
{
attrs
:
{
icon
:
"md-sync"
,
type
:
"icon"
,
title
:
"回收订单"
,
oprate
:
"edit"
,
msg
:
"确认要恢复工序吗?"
},
on
:
{
click
:
()
=>
{
this
.
recycle
(
params
.
row
);
}
}
}
)
]);
}
}
],
loading
:
false
loading
:
false
,
recovery
:
{
orderId
:
null
,
demandFinishDate
:
""
//计划完成时间
},
mesCode
:
""
,
rulesRecycle
:
{
demandFinishDate
:
[
{
required
:
true
,
message
:
"请选择计划完成时间"
,
trigger
:
"change"
,
type
:
"date"
}
]
}
};
},
mounted
()
{},
...
...
@@ -438,17 +499,19 @@ export default {
this
.
result
=
[];
this
.
loading
=
true
;
this
.
SpeedModal
=
true
;
this
.
dispatchExecuteId
=
row
.
dispatchExecuteId
this
.
orderId
=
row
.
id
this
.
dispatchExecuteId
=
row
.
dispatchExecuteId
;
this
.
orderId
=
row
.
id
;
Api
.
info
({
routingHeaderId
:
row
.
routingHeaderId
,
dispatchExecuteId
:
row
.
dispatchExecuteId
}).
then
(
r
=>
{
})
.
then
(
r
=>
{
if
(
r
.
success
)
{
this
.
result
=
r
.
result
;
this
.
loading
=
false
;
}
}).
catch
(
err
=>
{
})
.
catch
(
err
=>
{
this
.
$Message
.
error
(
"连接错误"
);
});
}
...
...
@@ -499,6 +562,53 @@ export default {
}
});
},
recycle
(
row
)
{
//回收订单
this
.
recycleModal
=
true
;
this
.
mesCode
=
row
.
mesCode
;
this
.
recovery
=
{
orderId
:
row
.
id
,
demandFinishDate
:
row
.
demandFinishDate
};
},
changeFinishiDate
()
{
let
temTime
=
this
.
recovery
.
demandFinishDate
;
this
.
recovery
.
demandFinishDate
=
""
;
this
.
recovery
.
demandFinishDate
=
this
.
getFormatDateEnd
(
temTime
);
Api
.
orderrecovery
(
this
.
recovery
)
.
then
(
res
=>
{
if
(
res
.
success
)
{
this
.
$Message
.
success
(
"回收成功"
);
this
.
$refs
.
grid
.
reload
(
this
.
easySearch
);
this
.
recycleModal
=
false
;
}
})
.
catch
(
err
=>
{
this
.
$Message
.
error
(
"数据连接错误"
);
});
},
cancelRecycle
()
{
this
.
mesCode
=
""
;
this
.
recovery
=
{
orderId
:
null
,
demandFinishDate
:
""
//计划完成时间
};
this
.
recycleModal
=
false
;
},
getFinishedDate
(
value
)
{
this
.
recovery
.
demandFinishDate
=
value
;
},
getFormatDateEnd
(
dates
)
{
const
d
=
new
Date
(
dates
);
const
resDate
=
d
.
getFullYear
()
+
"-"
+
this
.
p
(
d
.
getMonth
()
+
1
)
+
"-"
+
this
.
p
(
d
.
getDate
())
+
" 23:59:59"
;
return
resDate
;
},
//截取字符串
sliceStr
(
str
,
lenS
,
lenE
)
{
return
str
.
slice
(
lenS
,
lenE
);
...
...
@@ -507,6 +617,9 @@ export default {
this
.
curId
=
0
;
this
.
suspendModal
=
false
;
},
p
(
s
)
{
return
Number
(
s
)
<
10
?
"0"
+
s
:
s
;
},
l
(
key
)
{
let
vkey
=
"mes_order_watch"
+
"."
+
key
;
return
this
.
$t
(
vkey
)
||
key
;
...
...
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