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
2680e4ba
Commit
2680e4ba
authored
Jun 09, 2020
by
renjintao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
转续...
parent
3ad7209e
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
204 additions
and
114 deletions
+204
-114
userSelect.vue
components/page/userSelect.vue
+53
-33
api.js
pages/produce/execute/api.js
+9
-0
orderlist.vue
pages/produce/execute/components/orderlist.vue
+18
-13
index.vue
pages/produce/execute/index.vue
+58
-52
index.vue
pages/produce/execute/starOrder/index.vue
+66
-16
No files found.
components/page/userSelect.vue
View file @
2680e4ba
...
...
@@ -27,19 +27,18 @@
<div
v-width=
"50"
class=
"fa-m fs"
>
<span>
已选项
</span>
</div>
<div
class=
"fg"
>
<div
class=
"fg"
>
<dl>
<dd
v-for=
"(li,i) in checkedItems"
>
<div
class=
"flex"
>
<span
class=
"fg"
>
{{
li
.
userName
}}
</span>
<a
@
click=
"removeItem(li)"
>
<Icon
type=
"md-close"
size=
"16"
/>
</a>
</div>
</dd>
</dl>
<dd
v-for=
"(li,i) in checkedItems"
>
<div
class=
"flex"
>
<span
class=
"fg"
>
{{
li
.
userName
}}
</span>
<a
@
click=
"removeItem(li)"
>
<Icon
type=
"md-close"
size=
"16"
/>
</a>
</div>
</dd>
</dl>
</div>
</div>
</div>
...
...
@@ -53,13 +52,17 @@
clearable
filterable
>
<Option
v-for=
"item in dic"
:value=
"item.value"
:key=
"item.value"
:label=
"item.label"
>
<Option
v-for=
"item in datas?datas:dic"
:value=
"item.value"
:key=
"item.value"
:label=
"item.label"
>
<div>
<Icon
:type=
"item.gender == 1 ? 'ios-man' : 'ios-woman'"
/>
{{
item
.
label
}}
(
<span
style=
"color:#c3c3c3"
>
{{
item
.
cardNo
}}
</span>
)
{{
item
.
label
}}
<span
style=
"color:#c3c3c3"
v-if=
"item.cardNo"
>
(
{{
item
.
cardNo
}}
)
</span>
<br
/>
<span
style=
"color:#c3c3c3"
>
{{
item
.
departmentTitle
}}
</span>
<span
style=
"color:#c3c3c3"
v-if=
"item.departmentTitle"
>
{{
item
.
departmentTitle
}}
</span>
</div>
</Option>
</Select>
...
...
@@ -111,6 +114,11 @@ export default {
roleTitle
:
{
type
:
String
,
default
:
""
},
datas
:
{
//自定义用户数据
type
:
Array
,
default
:
null
}
},
methods
:
{
...
...
@@ -131,18 +139,18 @@ export default {
})
.
then
(
r
=>
{
this
.
data
=
r
.
result
;
if
(
this
.
theme
==
"list"
)
{
this
.
departmentGroup
();
if
(
this
.
theme
==
"list"
)
{
this
.
departmentGroup
();
}
});
},
departmentGroup
()
{
var
group
=
[];
var
users
=
this
.
$u
.
clone
(
this
.
data
);
if
(
this
.
name
&&
this
.
name
.
length
>
0
)
{
users
.
map
(
u
=>
{
u
.
checked
=
this
.
name
.
indexOf
(
u
.
id
)
>
-
1
;
})
var
users
=
this
.
$u
.
clone
(
this
.
data
);
if
(
this
.
name
&&
this
.
name
.
length
>
0
)
{
users
.
map
(
u
=>
{
u
.
checked
=
this
.
name
.
indexOf
(
u
.
id
)
>
-
1
;
})
;
}
group
=
this
.
$u
.
group
(
users
,
u
=>
{
return
u
.
departmentId
;
...
...
@@ -180,15 +188,15 @@ export default {
this
.
$set
(
this
.
group
,
i
,
u
);
}
});
this
.
listSetValue
();
this
.
listSetValue
();
},
//list 时,设置值。
listSetValue
(){
var
ids
=
[];
this
.
checkedItems
.
map
(
u
=>
{
ids
.
push
(
u
.
id
)
})
this
.
$emit
(
"on-change"
,
ids
);
listSetValue
()
{
var
ids
=
[];
this
.
checkedItems
.
map
(
u
=>
{
ids
.
push
(
u
.
id
)
;
})
;
this
.
$emit
(
"on-change"
,
ids
);
},
checkAll
(
item
,
i
)
{
item
.
children
.
map
(
u
=>
{
...
...
@@ -207,9 +215,16 @@ export default {
}
else
{
if
(
!
this
.
multiple
)
{
//单选时返回信息
var
item1
=
this
.
dic
.
filter
(
u
=>
u
.
value
==
this
.
value
);
if
(
item1
&&
item1
[
0
])
{
items
.
push
(
item1
[
0
]);
if
(
this
.
datas
&&
this
.
datas
.
length
>
0
)
{
var
item2
=
this
.
datas
.
filter
(
u
=>
u
.
value
==
this
.
value
);
if
(
item2
&&
item2
[
0
])
{
items
.
push
(
item2
[
0
]);
}
}
else
{
var
item1
=
this
.
dic
.
filter
(
u
=>
u
.
value
==
this
.
value
);
if
(
item1
&&
item1
[
0
])
{
items
.
push
(
item1
[
0
]);
}
}
}
else
{
//复选时返回
...
...
@@ -284,6 +299,11 @@ export default {
this
.
getselectuser
(
v
);
},
deep
:
true
},
datas
(
v
)
{
if
(
v
)
{
//alert(JSON.stringify(v))
}
}
}
};
...
...
pages/produce/execute/api.js
View file @
2680e4ba
...
...
@@ -25,5 +25,14 @@ export default {
entrentrycontinuestart
(
params
)
{
return
Api
.
post
(
`
${
PlanUrl
}
/orderexecute/entrycontinue`
,
params
);
},
//转序弹框产品+人员
productsandoperators
(
params
)
{
return
Api
.
post
(
`
${
PlanUrl
}
/orderexecutehandon/productsandoperators`
,
params
);
},
//确认发起转序
confirmproductsandoperator
(
params
)
{
return
Api
.
post
(
`
${
PlanUrl
}
/orderexecutehandon/confirmproductsandoperator`
,
params
);
},
}
\ No newline at end of file
pages/produce/execute/components/orderlist.vue
View file @
2680e4ba
...
...
@@ -37,26 +37,29 @@ export default {
return
{
gnFlag
:
0
,
listTasks
:
[],
dataLength
:
0
,
dataLength
:
0
};
},
props
:
{
order
:
{
type
:
String
,
default
:
''
,
type
:
[
String
,
Number
]
},
asc
:
{
type
:
Boolean
,
default
:
true
,
default
:
true
},
statu
:
{
type
:
Number
,
default
:
-
9
}
},
created
()
{
this
.
loadTree
(
-
9
);
this
.
loadTree
();
},
methods
:
{
loadTree
(
value
)
{
loadTree
()
{
let
parmse
=
{
status
:
value
,
status
:
this
.
statu
,
isAsc
:
this
.
asc
};
Api
.
getCardList
(
parmse
).
then
(
res
=>
{
...
...
@@ -83,14 +86,16 @@ export default {
}
},
watch
:
{
order
(
v
)
{
order
(
v
)
{
//alert(v)
},
asc
(
v
)
{
this
.
asc
=
v
this
.
loadTree
(
-
9
)
asc
(
v
)
{
this
.
asc
=
v
;
this
.
loadTree
();
},
statu
(
v
)
{
this
.
statu
=
v
this
.
loadTree
();
}
}
};
...
...
pages/produce/execute/index.vue
View file @
2680e4ba
...
...
@@ -2,33 +2,44 @@
@import "./execute.less";
</
style
>
<
template
>
<div
class=
"execute_box"
>
<!--
<div
class=
"top_title"
>
<div
class=
"execute_box"
>
<!--
<div
class=
"top_title"
>
<span
class=
"fl"
>
{{
orderTitle
}}
</span>
<div>
工单编号: 12001011
</div>
</div>
-->
<component
:is=
"detail"
:gdid=
"gdId"
:row=
"row"
/>
<a
class=
"gd_list"
@
click=
"orderlistMode = true"
>
工单列表
</a>
<a
class=
"gn_area"
@
click=
"functionalMode = true"
>
功能区
</a>
<!-- 工单列表 -->
<Drawer
placement=
"left"
class=
"gd_box"
:closable=
"false"
:inner=
"true"
:transfer=
"false"
v-model=
"orderlistMode"
>
<div
slot=
"header"
>
<div
class=
"header"
>
<a
class=
"gd_tt"
@
click=
"goToOrder"
><Icon
type=
"ios-undo-outline"
/>
工单列表
</a>
<Dictionary
code=
"taskList.status"
class=
"select_star fr"
v-model=
"odermodel"
@
on-change=
"searchOrder"
></Dictionary>
</Option>
</Select>
</div>
-->
<component
:is=
"detail"
:gdid=
"gdId"
:row=
"row"
/>
<a
class=
"gd_list"
@
click=
"orderlistMode = true"
>
工单列表
</a>
<a
class=
"gn_area"
@
click=
"functionalMode = true"
>
功能区
</a>
<!-- 工单列表 -->
<Drawer
placement=
"left"
class=
"gd_box"
:closable=
"false"
:inner=
"true"
:transfer=
"false"
v-model=
"orderlistMode"
>
<div
slot=
"header"
>
<div
class=
"header"
>
<a
class=
"gd_tt"
@
click=
"goToOrder"
>
<Icon
type=
"ios-undo-outline"
/>
工单列表
</a>
<Dictionary
code=
"taskList.status"
class=
"select_star fr"
v-model=
"odermodel"
@
on-change=
"searchOrder"
></Dictionary>
</div>
<div
class=
"select_t"
>
<Button
@
click=
"changeAsc"
>
{{
ascTitle
}}
</Button>
</div>
</div>
<!-- 列表卡片主内容 -->
<orderlist
ref=
"orderlist
"
:asc=
"asc
"
:order=
"inputId"
/>
<orderlist
ref=
"orderlist
ref"
:asc=
"asc"
:statu=
"statu
"
:order=
"inputId"
/>
</Drawer>
<!-- 功能区 -->
<Drawer
<Drawer
class=
"gn_box"
:closable=
"false"
:inner=
"true"
...
...
@@ -54,22 +65,23 @@ export default {
functionalMode
:
false
,
gdId
:
0
,
detail
:
null
,
row
:{},
row
:
{},
odermodel
:
-
9
,
orderId
:
this
.
$route
.
query
.
id
,
condition
:
[],
inputId
:
null
,
asc
:
true
,
ascTitle
:
'时间正序排序'
asc
:
true
,
ascTitle
:
"时间正序排序"
,
statu
:
-
9
};
},
created
()
{
let
row
=
{}
let
row
=
{};
row
.
id
=
this
.
$route
.
query
.
id
;
row
.
orderId
=
this
.
$route
.
query
.
orderId
;
row
.
executeId
=
this
.
$route
.
query
.
executeId
;
this
.
row
=
row
this
.
inputId
=
this
.
$route
.
query
.
id
row
.
orderId
=
this
.
$route
.
query
.
orderId
;
row
.
executeId
=
this
.
$route
.
query
.
executeId
;
this
.
row
=
row
;
this
.
inputId
=
this
.
$route
.
query
.
id
;
this
.
detail
=
()
=>
import
(
"./starOrder/index"
);
},
async
fetch
({
store
,
params
})
{
...
...
@@ -84,11 +96,11 @@ export default {
this
.
$router
.
push
(
"/produce/orderlist"
);
},
searchOrder
(
value
)
{
if
(
value
==
''
||
value
==
null
||
value
==
undefined
)
{
value
=-
9
}
this
.
$refs
.
orderlist
.
loadTree
(
value
);
if
(
value
==
null
||
typeof
value
==
"undefined"
)
{
value
=
-
9
;
}
this
.
statu
=
value
// this.$refs.orderlistref
.loadTree(value);
},
changeTitle
(
number
,
type
)
{
this
.
orderTitle
=
type
;
...
...
@@ -97,21 +109,21 @@ export default {
this
.
detail
=
()
=>
import
(
"./starOrder/index"
);
}
//进度汇报
if
(
number
==
1
)
{
this
.
$Message
.
info
(
"尊敬的用户,您没有该权限!"
)
this
.
$Message
.
info
(
"尊敬的用户,您没有该权限!"
);
// this.detail = () => import("./MaterialCollec/index");
}
//物料领用
if
(
number
==
2
)
{
// this.detail = () => import("./productSet/index");
this
.
$Message
.
info
(
"尊敬的用户,您没有该权限!"
)
this
.
$Message
.
info
(
"尊敬的用户,您没有该权限!"
)
;
}
//产品装配
if
(
number
==
3
)
{
this
.
detail
=
()
=>
import
(
"./taskTime/index"
);
}
//工时分配
if
(
number
==
4
)
{
this
.
$Message
.
info
(
"尊敬的用户,您没有该权限!"
)
this
.
$Message
.
info
(
"尊敬的用户,您没有该权限!"
);
// this.detail = () => import("./preparation/index");
}
//生产准备
if
(
number
==
5
)
{
if
(
number
==
5
)
{
this
.
detail
=
()
=>
import
(
"./ProcessCheck/index"
);
}
//工艺查看
if
(
number
==
6
)
{
...
...
@@ -124,31 +136,25 @@ export default {
this
.
detail
=
()
=>
import
(
"./datafilling/index"
);
}
//数据填报
if
(
number
==
9
)
{
this
.
$Message
.
info
(
"尊敬的用户,您没有该权限!"
)
this
.
$Message
.
info
(
"尊敬的用户,您没有该权限!"
);
// this.detail = () => import("./testdata/index");
}
//测试数据
},
changeAsc
()
{
this
.
asc
=!
this
.
asc
if
(
this
.
asc
)
{
this
.
ascTitle
=
'时间正序排序'
}
else
{
this
.
ascTitle
=
'时间倒序排序'
changeAsc
()
{
this
.
asc
=
!
this
.
asc
;
if
(
this
.
asc
)
{
this
.
ascTitle
=
"时间正序排序"
;
}
else
{
this
.
ascTitle
=
"时间倒序排序"
;
}
}
},
watch
:
{
'$route.query.id'
(
v
)
{
this
.
row
.
id
=
v
this
.
inputId
=
v
this
.
detail
=
()
=>
import
(
"./starOrder/index"
)
},
"$route.query.id"
(
v
)
{
this
.
row
.
id
=
v
;
this
.
inputId
=
v
;
this
.
detail
=
()
=>
import
(
"./starOrder/index"
);
}
}
};
</
script
>
pages/produce/execute/starOrder/index.vue
View file @
2680e4ba
...
...
@@ -53,7 +53,7 @@
<li>
图号:
{{
entity
.
drawnNumber
}}
</li>
<li>
状态:
<state
code=
"plan.order.status"
ref=
"state"
:value=
"entity.status"
type=
"text"
></state>
<state
code=
"plan.order.status"
ref=
"state"
:value=
"entity.status"
type=
"text"
></state>
</li>
<li>
订单编号:
{{
entity
.
mesCode
}}
</li>
<li>
批次号:
{{
entity
.
batchNumber
}}
</li>
...
...
@@ -78,7 +78,7 @@
<ViewerImg
:images=
"images"
/>
</div>
</div>
<Modal
v-model=
"ransferModal"
:title=
"transferTitle"
fullscreen
style=
"z-index:99999"
>
<Modal
v-model=
"ransferModal"
:title=
"transferTitle"
fullscreen
style=
"z-index:99999"
:footer-hide=
"cardlist.length>0"
>
<div
class=
"wu_bgModal"
>
<div
class=
"mass_box"
>
<div
class=
"mass_list"
>
...
...
@@ -99,16 +99,16 @@
:checked=
"item.checked"
color=
"primary"
@
on-change=
"changeCards"
>
{{
item
.
pr
efix
}}
.
{{
item
.
code
}}
</Tag>
>
{{
item
.
pr
oduct_
code
}}
</Tag>
</div>
</div>
</div>
<div
class=
"mass_box"
>
<UserSelect
ref=
"userSelected"
v-width=
"300"
/>
<UserSelect
ref=
"userSelected"
:datas=
"userlist"
v-model=
"user"
v-width=
"300"
/>
</div>
</div>
<div
slot=
"footer"
>
<Button
class=
"button"
@
click=
"ransferModal=false"
>
取消
</Button>
<div
slot=
"footer"
>
<Button
class=
"button"
@
click=
"ransferModal=false"
>
取消
</Button>
<Button
class=
"button"
type=
"primary"
@
click=
"ransOk"
>
确定
</Button>
</div>
</Modal>
...
...
@@ -151,7 +151,12 @@ export default {
:
Number
(
this
.
$route
.
query
.
dispatchStatus
)
==
5
?
true
:
false
,
cardlist
:
[]
cardlist
:
[],
detailId
:
null
,
nextDetailId
:
null
,
operatorId
:
null
,
userlist
:
[],
user
:
null
};
},
created
()
{
...
...
@@ -309,12 +314,26 @@ export default {
this
.
$parent
.
changeTitle
(
type
,
title
);
},
getProduce
()
{
this
.
cardlist
=
[]
this
.
cardlist
=
[];
let
pid
=
Number
(
this
.
$route
.
query
.
id
);
// JSON.stringify()
Api
.
getpaged
({
id
:
pid
})
let
params
=
{
id
:
Number
(
this
.
$route
.
query
.
id
),
executeId
:
Number
(
this
.
$route
.
query
.
executeId
)
};
Api
.
productsandoperators
(
params
)
.
then
(
res
=>
{
if
(
res
.
success
)
{
let
resoult
=
res
.
result
;
if
(
res
.
success
&&
res
.
result
)
{
this
.
detailId
=
res
.
result
.
detailId
;
this
.
nextDetailId
=
res
.
result
.
nextDetailId
;
let
users
=
res
.
result
.
users
;
this
.
userlist
=
[];
users
.
forEach
(
u
=>
{
(
u
.
value
=
u
.
id
),
(
u
.
label
=
u
.
userName
);
this
.
userlist
.
push
(
u
);
});
let
resoult
=
res
.
result
.
products
;
resoult
.
filter
(
u
=>
{
u
.
checked
=
false
;
this
.
cardlist
.
push
(
u
);
...
...
@@ -344,19 +363,50 @@ export default {
let
cardlist
=
this
.
cardlist
;
cardlist
.
map
((
u
,
i
)
=>
{
if
(
u
.
id
==
name
)
{
u
.
checked
=
true
;
u
.
checked
=
checked
;
}
});
},
//确定转续
ransOk
()
{
let
cardlist
=
this
.
cardlist
;
let
upList
=
[]
let
userInfo
=
this
.
$refs
.
userSelected
.
getSelectItems
();
let
cardlist
=
this
.
cardlist
;
let
upList
=
[];
cardlist
.
map
((
u
,
i
)
=>
{
if
(
u
.
checked
)
{
upList
.
push
(
u
.
id
)
upList
.
push
(
u
.
id
)
;
}
});
alert
(
JSON
.
stringify
(
upList
));
if
(
upList
.
length
==
0
)
{
this
.
$Message
.
error
(
"请选择转续的产品!"
);
return
;
}
if
(
!
userInfo
||
userInfo
.
length
==
0
)
{
this
.
$Message
.
error
(
"请选择人员!"
);
return
;
}
let
params
=
{
id
:
Number
(
this
.
$route
.
query
.
id
),
detailId
:
this
.
detailId
,
nextDetailId
:
this
.
nextDetailId
,
productIds
:
upList
,
operatorId
:
userInfo
[
0
].
id
,
operator
:
userInfo
[
0
].
userName
};
Api
.
confirmproductsandoperator
(
params
)
.
then
(
res
=>
{
if
(
res
.
success
&&
res
.
result
)
{
this
.
$Message
.
success
(
"转续成功"
);
this
.
ransferModal
=
false
}
else
{
this
.
$Message
.
error
(
"转续失败"
);
}
})
.
catch
(
e
=>
{
this
.
$Message
.
error
(
"连接错误"
);
});
}
},
watch
:
{
...
...
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