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
f12229c9
Commit
f12229c9
authored
Oct 12, 2020
by
仇晓婷
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'product' of
http://git.mes123.com/zhouyx/mes-ui
into product
parents
d6048a1a
40912b67
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
1056 additions
and
1064 deletions
+1056
-1064
index.vue
pages/bug/index.vue
+447
-465
index.vue
pages/import/index.vue
+6
-1
index.vue
pages/order/monitoring/index.vue
+599
-594
orderlist.vue
pages/produce/orderlist.vue
+4
-4
No files found.
pages/bug/index.vue
View file @
f12229c9
<
template
>
<
template
>
<div
class=
"myBug"
>
<div
class=
"myBug"
>
<Tabs
:animated=
"false"
@
on-click=
"tab"
>
<Tabs
:animated=
"false"
@
on-click=
"tab"
>
<TabPane
label=
"我的"
></TabPane>
<TabPane
label=
"我的"
></TabPane>
<TabPane
label=
"所有"
></TabPane>
<TabPane
label=
"所有"
></TabPane>
</Tabs>
</Tabs>
<DataGrid
<DataGrid
:columns=
"columns"
ref=
"grid"
:action=
"action"
:conditions=
"easySearch"
@
on-selection-change=
"selectInfo"
:height=
"gridHeight"
>
:columns=
"columns"
<template
slot=
"easySearch"
>
ref=
"grid"
<Form
inline
>
:action=
"action"
<FormItem>
:conditions=
"easySearch"
<dictionary
code=
"Test.bug.status"
v-model=
"easySearch.status.value"
style=
"width:400px;"
multiple
></dictionary>
@
on-selection-change=
"selectInfo"
</FormItem>
:height=
"gridHeight"
<FormItem>
>
<Input
search
enter-button
placeholder=
"请输入bug标题或地址"
@
on-search=
"search"
v-model=
"easySearch.keys.value"
/>
<template
slot=
"easySearch"
>
</FormItem>
<Form
inline
>
</Form>
<FormItem>
</
template
>
<dictionary
<
template
slot=
"searchForm"
>
code=
"Test.bug.status"
<Search
/>
v-model=
"easySearch.status.value"
</
template
>
style=
"width:400px;"
<
template
slot=
"batch"
>
multiple
<Form
:model=
"formMyCheck"
:label-width=
"5"
:rules=
"ruleValidate"
inline
ref=
"formValidate"
>
></dictionary>
<FormItem>
</FormItem>
<dictionary
code=
"Test.but.statusOper"
v-model=
"selectBatch"
type=
"radio"
@
on-change=
"statuChange"
ref=
"dicradio"
></dictionary>
<FormItem>
</FormItem>
<Input
<FormItem
v-if=
"selectBatch == 5"
label
prop=
"selectAlloter"
>
search
<UserSelect
ref=
"userSelected"
v-model=
"alloter"
@
on-change=
"changeUserSelect"
/>
enter-button
</FormItem>
placeholder=
"请输入bug标题或地址"
<FormItem>
@
on-search=
"search"
<Button
type=
"primary"
@
click=
"upChange"
>
确定
</Button>
v-model=
"easySearch.keys.value"
</FormItem>
/>
</Form>
</FormItem>
</
template
>
</Form>
</
template
>
<
template
slot=
"searchForm"
>
<Search
/>
</
template
>
<
template
slot=
"batch"
>
<Form
:model=
"formMyCheck"
:label-width=
"5"
:rules=
"ruleValidate"
inline
ref=
"formValidate"
>
<FormItem>
<dictionary
code=
"Test.but.statusOper"
v-model=
"selectBatch"
type=
"radio"
@
on-change=
"statuChange"
ref=
"dicradio"
></dictionary>
</FormItem>
<FormItem
v-if=
"selectBatch == 5"
label
prop=
"selectAlloter"
>
<UserSelect
ref=
"userSelected"
v-model=
"alloter"
@
on-change=
"changeUserSelect"
/>
</FormItem>
<FormItem>
<Button
type=
"primary"
@
click=
"upChange"
>
确定
</Button>
</FormItem>
</Form>
</
template
>
</DataGrid>
</DataGrid>
<Modal
v-model=
"modalEdit"
fullscreen
title=
"bug编辑"
@
on-cancel=
"canselModal(1)"
>
<Modal
v-model=
"modalEdit"
fullscreen
title=
"bug编辑"
@
on-cancel=
"canselModal(1)"
>
<edit
ref=
"edit"
/>
<edit
ref=
"edit"
/>
<div
slot=
"footer"
>
<div
slot=
"footer"
>
<Button
@
click=
"canselModal(1)"
>
取消
</Button>
<Button
@
click=
"canselModal(1)"
>
取消
</Button>
<Button
type=
"primary"
@
click=
"addSave"
>
确定
</Button>
<Button
type=
"primary"
@
click=
"addSave"
>
确定
</Button>
</div>
</div>
</Modal>
</Modal>
<Modal
v-model=
"modalDetail"
fullscreen
title=
"bug操作"
@
on-cancel=
"canselModal(2)"
>
<Modal
v-model=
"modalDetail"
fullscreen
title=
"bug操作"
@
on-cancel=
"canselModal(2)"
>
<detail
ref=
"detail"
/>
<detail
ref=
"detail"
/>
<div
slot=
"footer"
>
<div
slot=
"footer"
>
<Button
@
click=
"canselModal(2)"
>
取消
</Button>
<Button
@
click=
"canselModal(2)"
>
取消
</Button>
<Button
type=
"primary"
@
click=
"detailSave"
>
确定
</Button>
<Button
type=
"primary"
@
click=
"detailSave"
>
确定
</Button>
</div>
</div>
</Modal>
</Modal>
<Modal
v-model=
"modalInfo"
title=
"批量信息"
>
<Modal
v-model=
"modalInfo"
title=
"批量信息"
>
确定进行批量操作?
确定进行批量操作?
<div
slot=
"footer"
>
<div
slot=
"footer"
>
<Button
@
click=
"modalInfo = false"
>
取消
</Button>
<Button
@
click=
"modalInfo = false"
>
取消
</Button>
<Button
type=
"primary"
@
click=
"upSave"
>
确定
</Button>
<Button
type=
"primary"
@
click=
"upSave"
>
确定
</Button>
</div>
</div>
</Modal>
</Modal>
</div>
</div>
</template>
</template>
<
script
>
<
script
>
import
Api
from
"@/libs/bug"
;
import
Api
from
"@/libs/bug"
;
import
edit
from
"./component/add"
;
import
edit
from
"./component/add"
;
import
detail
from
"./component/detail"
;
import
detail
from
"./component/detail"
;
import
Search
from
"./component/search"
;
import
Search
from
"./component/search"
;
export
default
{
export
default
{
name
:
"bug"
,
name
:
"bug"
,
components
:
{
components
:
{
edit
,
edit
,
detail
,
detail
,
Search
Search
},
},
data
()
{
data
()
{
let
userInfo
=
this
.
$store
.
state
.
admin
.
user
.
info
;
let
userInfo
=
this
.
$store
.
state
.
admin
.
user
.
info
;
return
{
return
{
action
:
Api
.
index
,
action
:
Api
.
index
,
easySearch
:
{
easySearch
:
{
keys
:
{
op
:
"title,pagePath"
,
value
:
""
},
keys
:
{
status
:
{
op
:
"In"
,
value
:
[
1
,
5
,
0
]
},
op
:
"title,pagePath"
,
creatorUserId
:
{
value
:
""
op
:
"Equal"
,
},
value
:
userInfo
.
userId
status
:
{
}
op
:
"In"
,
},
value
:
[
1
,
5
,
0
]
selectList
:
[],
},
results
:
[],
creatorUserId
:
{
footerBar
:
false
,
op
:
"Equal"
,
modalInfo
:
false
,
value
:
userInfo
.
userId
gridHeight
:
""
,
}
totals
:
10
,
},
pageSizeOpts
:
[
20
,
50
,
100
],
selectList
:
[],
pageSize
:
20
,
results
:
[],
tabIndex
:
1
,
footerBar
:
false
,
columns
:
[
modalInfo
:
false
,
{
gridHeight
:
""
,
type
:
"selection"
,
totals
:
10
,
width
:
60
,
pageSizeOpts
:
[
20
,
50
,
100
],
align
:
"center"
pageSize
:
20
,
},
tabIndex
:
1
,
{
columns
:
[{
key
:
"id"
,
type
:
"selection"
,
width
:
80
,
width
:
60
,
title
:
this
.
l
(
"id"
)
align
:
"center"
},
{
key
:
"id"
,
width
:
80
,
title
:
this
.
l
(
"id"
)
},
{
title
:
this
.
l
(
"level"
),
key
:
"level"
,
width
:
100
},
{
title
:
this
.
l
(
"title"
),
key
:
"title"
,
width
:
240
,
tooltip
:
true
,
render
:
(
h
,
params
)
=>
h
(
"a"
,
{
style
:
{},
on
:
{
click
:
()
=>
{
this
.
detailInfo
(
params
.
row
);
}
}
},
params
.
row
.
title
)
},
{
title
:
this
.
l
(
"pagePath"
),
key
:
"pagePath"
,
tooltip
:
true
,
render
:
(
h
,
params
)
=>
h
(
"a"
,
{
style
:
{},
on
:
{
click
:
()
=>
{
window
.
open
(
params
.
row
.
pagePath
,
"_blank"
);
}
}
},
params
.
row
.
pagePath
)
},
{
title
:
this
.
l
(
"status"
),
key
:
"status"
,
width
:
100
,
code
:
'Test.bug.status'
,
},
{
title
:
this
.
l
(
"creationTime"
),
key
:
"creationTime"
,
align
:
"center"
,
width
:
180
},
{
title
:
this
.
l
(
"createor"
),
key
:
"createor"
,
width
:
120
},
{
title
:
this
.
l
(
"alloter"
),
key
:
"alloter"
,
width
:
120
},
{
title
:
this
.
l
(
"lastModificationTime"
),
key
:
"lastModificationTime"
,
align
:
"center"
,
width
:
180
},
{
title
:
this
.
l
(
"auditUser"
),
align
:
"center"
,
key
:
"auditUser"
,
width
:
120
},
{
key
:
"action"
,
title
:
"操作"
,
align
:
"center"
,
width
:
180
,
render
:
(
h
,
params
)
=>
h
(
"div"
,
[
h
(
"Button"
,
{
props
:
{
type
:
"text"
,
size
:
"small"
},
style
:
{
color
:
"green"
},
on
:
{
click
:
()
=>
{
this
.
detailInfo
(
params
.
row
);
}
}
},
"解决"
),
h
(
"Button"
,
{
props
:
{
type
:
"text"
,
size
:
"small"
},
style
:
{
color
:
"green"
},
on
:
{
click
:
()
=>
{
this
.
editInfo
(
params
.
row
);
}
}
},
"编辑"
)
])
}
],
statusList
:
[{
name
:
"确认"
,
value
:
"1"
},
{
name
:
"解决"
,
value
:
"2"
},
{
name
:
"冻结"
,
value
:
"4"
},
{
name
:
"关闭"
,
value
:
"3"
}
],
modalEdit
:
false
,
modalDetail
:
false
,
searchForm
:
{
Status
:
0
,
PageSize
:
20
,
Current
:
1
},
listBatch
:
{
ids
:
[],
statusNew
:
0
,
auditUser
:
""
,
workHours
:
0
,
remark
:
""
,
alloter
:
""
,
alloterId
:
null
},
selectBatch
:
100
,
auditUser
:
null
,
alloter
:
{},
formMyCheck
:
{
selectAlloter
:
null
},
ruleValidate
:
{
selectAlloter
:
[{
required
:
true
,
message
:
"请选择驳指派人"
,
type
:
"number"
,
trigger
:
"change"
}]
}
};
},
computed
:
{},
async
fetch
({
store
,
params
})
{
await
store
.
dispatch
(
"loadDictionary"
);
// 加载数据字典
},
methods
:
{
//选项卡切换
tab
(
data
)
{
if
(
data
==
"0"
)
{
this
.
easySearch
.
creatorUserId
.
value
=
this
.
$store
.
state
.
userInfo
.
userId
;
}
else
{
this
.
easySearch
.
creatorUserId
.
value
=
null
;
}
this
.
search
();
},
},
{
search
()
{
title
:
this
.
l
(
"level"
),
this
.
$refs
.
grid
.
easySearch
(
this
.
easySearch
);
key
:
"level"
,
width
:
100
},
},
{
//打开修改窗口
title
:
this
.
l
(
"title"
),
editInfo
(
value
)
{
key
:
"title"
,
this
.
modalEdit
=
true
;
width
:
240
,
this
.
$refs
.
edit
.
editeInfo
(
value
);
tooltip
:
true
,
render
:
(
h
,
params
)
=>
h
(
"a"
,
{
style
:
{},
on
:
{
click
:
()
=>
{
this
.
detailInfo
(
params
.
row
);
}
}
},
params
.
row
.
title
)
},
},
{
//修改事件
title
:
this
.
l
(
"pagePath"
),
addSave
()
{
key
:
"pagePath"
,
let
param
=
this
.
$refs
.
edit
.
addBugInfo
();
tooltip
:
true
,
param
.
auditUser
=
this
.
$store
.
state
.
userInfo
.
userName
;
render
:
(
h
,
params
)
=>
if
(
param
.
id
!=
null
)
{
h
(
//增加确定
"a"
,
this
.
$http
.
bug
.
createorupdate
(
param
).
then
(
res
=>
{
{
if
(
res
.
result
.
status
)
{
style
:
{},
this
.
$Message
.
success
(
"修改成功!"
);
on
:
{
this
.
search
();
click
:
()
=>
{
}
else
{
window
.
open
(
params
.
row
.
pagePath
,
"_blank"
);
this
.
$Message
.
error
(
"修改失败!"
);
}
}
}
this
.
modalEdit
=
false
;
},
});
params
.
row
.
pagePath
}
else
{
)
this
.
$Message
.
error
(
"修改失败!"
);
}
},
},
{
//打开确定/操作窗口
title
:
this
.
l
(
"status"
),
detailInfo
(
value
)
{
key
:
"status"
,
this
.
modalDetail
=
true
;
width
:
100
,
this
.
$refs
.
detail
.
detailInfo
(
value
);
render
:
(
h
,
params
)
=>
{
return
h
(
"state"
,
{
props
:
{
code
:
"Test.bug.status"
,
type
:
"text"
,
value
:
params
.
row
.
status
+
""
}
});
}
},
},
{
//确定/关闭操作
title
:
this
.
l
(
"creationTime"
),
detailSave
()
{
key
:
"creationTime"
,
let
param
=
this
.
$refs
.
detail
.
addBugInfo
();
align
:
"center"
,
param
.
auditUser
=
this
.
$store
.
state
.
userInfo
.
userName
;
width
:
180
param
.
ids
=
[
param
.
id
];
if
(
param
.
id
!=
null
)
{
//增加确定
this
.
$http
.
bug
.
doaction
(
param
).
then
(
res
=>
{
if
(
res
.
result
)
{
this
.
$Message
.
success
(
"操作成功!"
);
this
.
search
();
}
else
{
this
.
$Message
.
error
(
"操作失败!"
);
}
this
.
modalDetail
=
false
;
});
}
else
{
this
.
$Message
.
error
(
"操作失败!"
);
}
},
},
{
//取消窗口,查看状态
title
:
this
.
l
(
"createor"
),
canselModal
(
type
)
{
key
:
"createor"
,
let
param
;
width
:
120
if
(
type
==
1
)
{
param
=
this
.
$refs
.
edit
.
addBugInfo
();
}
else
{
param
=
this
.
$refs
.
detail
.
addBugInfo
();
}
param
.
auditUser
=
this
.
$store
.
state
.
userInfo
.
userName
;
param
.
ids
=
[
param
.
id
];
param
.
statusNew
=
6
;
if
(
param
.
id
!=
null
)
{
//增加改变状态为6/查看
this
.
$http
.
bug
.
doaction
(
param
).
then
(
res
=>
{
if
(
res
.
result
)
{
//this.search(this.searchForm)
}
else
{
this
.
$Message
.
error
(
"操作失败!"
);
}
});
}
else
{
this
.
$Message
.
error
(
"操作失败!"
);
}
this
.
modalDetail
=
false
;
this
.
modalEdit
=
false
;
},
},
{
selectInfo
(
value
)
{
title
:
this
.
l
(
"alloter"
),
this
.
selectList
=
[];
key
:
"alloter"
,
this
.
selectList
=
value
;
width
:
120
let
statueArry
=
[];
value
.
forEach
(
data
=>
{
var
that
=
this
;
statueArry
.
push
(
data
.
id
);
});
this
.
results
=
[];
this
.
results
=
statueArry
;
this
.
getListId
(
statueArry
);
},
},
{
//得到需要批量操作的ids
title
:
this
.
l
(
"lastModificationTime"
),
getListId
(
value
)
{
key
:
"lastModificationTime"
,
this
.
listBatch
.
ids
=
value
;
align
:
"center"
,
if
(
this
.
listBatch
.
ids
.
length
>
0
)
{
width
:
180
this
.
footerBar
=
true
;
//this.showBt = false
this
.
selectBatch
=
100
;
}
else
{
this
.
footerBar
=
false
;
//this.showBt = false
this
.
selectBatch
=
100
;
}
this
.
listBatch
.
auditUser
=
this
.
$store
.
state
.
userInfo
.
userName
;
},
},
{
//批量操作
title
:
this
.
l
(
"auditUser"
),
statuChange
(
value
)
{
align
:
"center"
,
this
.
listBatch
.
statusNew
=
value
;
key
:
"auditUser"
,
width
:
120
},
},
{
upChange
()
{
key
:
"action"
,
if
(
this
.
selectBatch
!=
100
)
{
title
:
"操作"
,
if
(
this
.
listBatch
.
ids
.
length
!=
0
)
{
align
:
"center"
,
if
(
this
.
selectBatch
==
5
)
{
width
:
180
,
this
.
$refs
[
"formValidate"
].
validate
(
valid
=>
{
render
:
(
h
,
params
)
=>
if
(
valid
)
{
h
(
"div"
,
[
let
alloterInfo
=
this
.
$refs
[
"userSelected"
].
getSelectItems
();
h
(
this
.
listBatch
.
alloter
=
alloterInfo
[
0
].
userName
;
"Button"
,
this
.
listBatch
.
alloterId
=
alloterInfo
[
0
].
id
;
{
this
.
modalInfo
=
true
;
props
:
{
}
type
:
"text"
,
});
size
:
"small"
}
else
{
},
this
.
modalInfo
=
true
;
style
:
{
color
:
"green"
},
on
:
{
click
:
()
=>
{
this
.
detailInfo
(
params
.
row
);
}
}
}
}
else
{
},
this
.
$Message
.
error
(
"请选择操作列表!"
);
"解决"
this
.
selectBatch
=
100
;
),
}
h
(
}
else
{
"Button"
,
this
.
$Message
.
error
(
"请选择操作!"
);
{
}
props
:
{
},
type
:
"text"
,
changeUserSelect
(
val
)
{
size
:
"small"
if
(
val
!=
undefined
&&
val
.
length
!=
""
&&
val
.
length
!=
0
)
{
},
this
.
formMyCheck
.
selectAlloter
=
1
;
style
:
{
}
else
{
color
:
"green"
this
.
formMyCheck
.
selectAlloter
=
null
;
},
this
.
listBatch
.
alloter
=
""
;
on
:
{
this
.
listBatch
.
alloterId
=
null
;
click
:
()
=>
{
}
this
.
editInfo
(
params
.
row
);
},
}
upSave
()
{
}
//增加确定
},
this
.
$http
.
bug
.
doaction
(
this
.
listBatch
).
then
(
res
=>
{
"编辑"
if
(
res
.
result
)
{
)
this
.
$Message
.
success
(
"操作成功!"
);
])
this
.
search
();
}
this
.
footerBar
=
false
;
],
this
.
showBt
=
false
;
this
.
modalInfo
=
false
;
statusList
:
[
this
.
selectBatch
=
100
;
{
name
:
"确认"
,
value
:
"1"
},
}
else
{
{
name
:
"解决"
,
value
:
"2"
},
this
.
$Message
.
error
(
"操作失败!"
);
{
name
:
"冻结"
,
value
:
"4"
},
}
{
name
:
"关闭"
,
value
:
"3"
}
],
modalEdit
:
false
,
modalDetail
:
false
,
searchForm
:
{
Status
:
0
,
PageSize
:
20
,
Current
:
1
},
listBatch
:
{
ids
:
[],
statusNew
:
0
,
auditUser
:
""
,
workHours
:
0
,
remark
:
""
,
alloter
:
""
,
alloterId
:
null
},
selectBatch
:
100
,
auditUser
:
null
,
alloter
:
{},
formMyCheck
:
{
selectAlloter
:
null
},
ruleValidate
:
{
selectAlloter
:
[
{
required
:
true
,
message
:
"请选择驳指派人"
,
type
:
"number"
,
trigger
:
"change"
}
]
}
};
},
computed
:
{},
async
fetch
({
store
,
params
})
{
await
store
.
dispatch
(
"loadDictionary"
);
// 加载数据字典
},
methods
:
{
//选项卡切换
tab
(
data
)
{
if
(
data
==
"0"
)
{
this
.
easySearch
.
creatorUserId
.
value
=
this
.
$store
.
state
.
userInfo
.
userId
;
}
else
{
this
.
easySearch
.
creatorUserId
.
value
=
null
;
}
this
.
search
();
},
search
()
{
this
.
$refs
.
grid
.
easySearch
(
this
.
easySearch
);
},
//打开修改窗口
editInfo
(
value
)
{
this
.
modalEdit
=
true
;
this
.
$refs
.
edit
.
editeInfo
(
value
);
},
//修改事件
addSave
()
{
let
param
=
this
.
$refs
.
edit
.
addBugInfo
();
param
.
auditUser
=
this
.
$store
.
state
.
userInfo
.
userName
;
if
(
param
.
id
!=
null
)
{
//增加确定
this
.
$http
.
bug
.
createorupdate
(
param
).
then
(
res
=>
{
if
(
res
.
result
.
status
)
{
this
.
$Message
.
success
(
"修改成功!"
);
this
.
search
();
}
else
{
this
.
$Message
.
error
(
"修改失败!"
);
}
this
.
modalEdit
=
false
;
});
}
else
{
this
.
$Message
.
error
(
"修改失败!"
);
}
},
//打开确定/操作窗口
detailInfo
(
value
)
{
this
.
modalDetail
=
true
;
this
.
$refs
.
detail
.
detailInfo
(
value
);
},
//确定/关闭操作
detailSave
()
{
let
param
=
this
.
$refs
.
detail
.
addBugInfo
();
param
.
auditUser
=
this
.
$store
.
state
.
userInfo
.
userName
;
param
.
ids
=
[
param
.
id
];
if
(
param
.
id
!=
null
)
{
//增加确定
this
.
$http
.
bug
.
doaction
(
param
).
then
(
res
=>
{
if
(
res
.
result
)
{
this
.
$Message
.
success
(
"操作成功!"
);
this
.
search
();
}
else
{
this
.
$Message
.
error
(
"操作失败!"
);
}
this
.
modalDetail
=
false
;
});
}
else
{
this
.
$Message
.
error
(
"操作失败!"
);
}
},
//取消窗口,查看状态
canselModal
(
type
)
{
let
param
;
if
(
type
==
1
)
{
param
=
this
.
$refs
.
edit
.
addBugInfo
();
}
else
{
param
=
this
.
$refs
.
detail
.
addBugInfo
();
}
param
.
auditUser
=
this
.
$store
.
state
.
userInfo
.
userName
;
param
.
ids
=
[
param
.
id
];
param
.
statusNew
=
6
;
if
(
param
.
id
!=
null
)
{
//增加改变状态为6/查看
this
.
$http
.
bug
.
doaction
(
param
).
then
(
res
=>
{
if
(
res
.
result
)
{
//this.search(this.searchForm)
}
else
{
this
.
$Message
.
error
(
"操作失败!"
);
}
});
}
else
{
this
.
$Message
.
error
(
"操作失败!"
);
}
this
.
modalDetail
=
false
;
this
.
modalEdit
=
false
;
},
selectInfo
(
value
)
{
this
.
selectList
=
[];
this
.
selectList
=
value
;
let
statueArry
=
[];
value
.
forEach
(
data
=>
{
var
that
=
this
;
statueArry
.
push
(
data
.
id
);
});
this
.
results
=
[];
this
.
results
=
statueArry
;
this
.
getListId
(
statueArry
);
},
//得到需要批量操作的ids
getListId
(
value
)
{
this
.
listBatch
.
ids
=
value
;
if
(
this
.
listBatch
.
ids
.
length
>
0
)
{
this
.
footerBar
=
true
;
//this.showBt = false
this
.
selectBatch
=
100
;
}
else
{
this
.
footerBar
=
false
;
//this.showBt = false
this
.
selectBatch
=
100
;
}
this
.
listBatch
.
auditUser
=
this
.
$store
.
state
.
userInfo
.
userName
;
},
//批量操作
statuChange
(
value
)
{
this
.
listBatch
.
statusNew
=
value
;
},
upChange
()
{
if
(
this
.
selectBatch
!=
100
)
{
if
(
this
.
listBatch
.
ids
.
length
!=
0
)
{
if
(
this
.
selectBatch
==
5
)
{
this
.
$refs
[
"formValidate"
].
validate
(
valid
=>
{
if
(
valid
)
{
let
alloterInfo
=
this
.
$refs
[
"userSelected"
].
getSelectItems
();
this
.
listBatch
.
alloter
=
alloterInfo
[
0
].
userName
;
this
.
listBatch
.
alloterId
=
alloterInfo
[
0
].
id
;
this
.
modalInfo
=
true
;
}
});
});
}
else
{
},
this
.
modalInfo
=
true
;
arry2Name
(
arryList
,
values
)
{
}
//预警类别转换
}
else
{
var
codes
=
arryList
;
this
.
$Message
.
error
(
"请选择操作列表!"
);
var
name
=
""
;
this
.
selectBatch
=
100
;
for
(
let
i
in
codes
)
{
}
if
(
values
==
codes
[
i
].
value
)
{
}
else
{
name
=
codes
[
i
].
name
;
this
.
$Message
.
error
(
"请选择操作!"
);
}
}
}
},
return
name
;
changeUserSelect
(
val
)
{
},
if
(
val
!=
undefined
&&
val
.
length
!=
""
&&
val
.
length
!=
0
)
{
canselFooter
()
{
this
.
formMyCheck
.
selectAlloter
=
1
;
this
.
footerBar
=
false
;
}
else
{
this
.
selectBatch
=
100
;
this
.
formMyCheck
.
selectAlloter
=
null
;
},
this
.
listBatch
.
alloter
=
""
;
l
(
key
)
{
this
.
listBatch
.
alloterId
=
null
;
let
vkey
=
"bug"
+
"."
+
key
;
}
return
this
.
$t
(
vkey
)
||
key
;
},
upSave
()
{
//增加确定
this
.
$http
.
bug
.
doaction
(
this
.
listBatch
).
then
(
res
=>
{
if
(
res
.
result
)
{
this
.
$Message
.
success
(
"操作成功!"
);
this
.
search
();
this
.
footerBar
=
false
;
this
.
showBt
=
false
;
this
.
modalInfo
=
false
;
this
.
selectBatch
=
100
;
}
else
{
this
.
$Message
.
error
(
"操作失败!"
);
}
});
},
arry2Name
(
arryList
,
values
)
{
//预警类别转换
var
codes
=
arryList
;
var
name
=
""
;
for
(
let
i
in
codes
)
{
if
(
values
==
codes
[
i
].
value
)
{
name
=
codes
[
i
].
name
;
}
}
}
return
name
;
},
canselFooter
()
{
this
.
footerBar
=
false
;
this
.
selectBatch
=
100
;
},
},
l
(
key
)
{
created
()
{
let
vkey
=
"bug"
+
"."
+
key
;
return
this
.
$t
(
vkey
)
||
key
;
}
},
created
()
{
window
.
screenHeight
=
window
.
innerHeight
;
this
.
gridHeight
=
window
.
screenHeight
-
250
;
},
mounted
()
{
// this.search(this.searchForm)
window
.
onresize
=
()
=>
{
return
(()
=>
{
window
.
screenHeight
=
window
.
innerHeight
;
window
.
screenHeight
=
window
.
innerHeight
;
this
.
gridHeight
=
window
.
screenHeight
-
250
;
this
.
gridHeight
=
window
.
screenHeight
-
250
;
})();
},
};
mounted
()
{
}
// this.search(this.searchForm)
window
.
onresize
=
()
=>
{
return
(()
=>
{
window
.
screenHeight
=
window
.
innerHeight
;
this
.
gridHeight
=
window
.
screenHeight
-
250
;
})();
};
}
};
};
</
script
>
</
script
>
pages/import/index.vue
View file @
f12229c9
...
@@ -18,7 +18,7 @@
...
@@ -18,7 +18,7 @@
<Button
type=
"primary"
@
click=
"add"
>
新增
</Button>
<Button
type=
"primary"
@
click=
"add"
>
新增
</Button>
</
template
>
</
template
>
</DataGrid>
</DataGrid>
<Modal
v-model=
"modal"
:title=
"title"
width=
"1200"
:fullscreen=
"full"
footer-hide
>
<Modal
v-model=
"modal"
:title=
"title"
width=
"1200"
:fullscreen=
"full"
:footer-hide=
"initBtn"
>
<component
:is=
"detail"
:eid=
"curId"
@
on-close=
"cancel"
@
on-ok=
"ok"
/>
<component
:is=
"detail"
:eid=
"curId"
@
on-close=
"cancel"
@
on-ok=
"ok"
/>
</Modal>
</Modal>
</div>
</div>
...
@@ -48,6 +48,7 @@ export default {
...
@@ -48,6 +48,7 @@ export default {
},
},
modal
:
false
,
modal
:
false
,
full
:
false
,
full
:
false
,
initBtn
:
true
,
title
:
"新增"
,
title
:
"新增"
,
detail
:
null
,
detail
:
null
,
curId
:
0
,
curId
:
0
,
...
@@ -213,6 +214,7 @@ export default {
...
@@ -213,6 +214,7 @@ export default {
add
()
{
add
()
{
this
.
curId
=
0
;
this
.
curId
=
0
;
this
.
full
=
false
;
this
.
full
=
false
;
this
.
initBtn
=
true
;
this
.
title
=
"新增"
;
this
.
title
=
"新增"
;
this
.
detail
=
()
=>
import
(
"./add"
);
this
.
detail
=
()
=>
import
(
"./add"
);
this
.
modal
=
true
;
this
.
modal
=
true
;
...
@@ -227,6 +229,7 @@ export default {
...
@@ -227,6 +229,7 @@ export default {
this
.
curId
=
id
;
this
.
curId
=
id
;
this
.
title
=
"详情"
;
this
.
title
=
"详情"
;
this
.
full
=
false
;
this
.
full
=
false
;
this
.
initBtn
=
false
;
this
.
detail
=
()
=>
import
(
"./detail"
);
this
.
detail
=
()
=>
import
(
"./detail"
);
this
.
modal
=
true
;
this
.
modal
=
true
;
},
},
...
@@ -234,6 +237,7 @@ export default {
...
@@ -234,6 +237,7 @@ export default {
this
.
curId
=
id
;
this
.
curId
=
id
;
this
.
title
=
"编辑"
;
this
.
title
=
"编辑"
;
this
.
full
=
false
;
this
.
full
=
false
;
this
.
initBtn
=
true
;
this
.
detail
=
()
=>
import
(
"./edit"
);
this
.
detail
=
()
=>
import
(
"./edit"
);
this
.
modal
=
true
;
this
.
modal
=
true
;
},
},
...
@@ -241,6 +245,7 @@ export default {
...
@@ -241,6 +245,7 @@ export default {
this
.
curId
=
row
.
id
;
this
.
curId
=
row
.
id
;
this
.
title
=
"处理文件:"
+
row
.
name
;
this
.
title
=
"处理文件:"
+
row
.
name
;
this
.
full
=
true
;
this
.
full
=
true
;
this
.
initBtn
=
true
;
this
.
detail
=
()
=>
import
(
"./process"
);
this
.
detail
=
()
=>
import
(
"./process"
);
this
.
modal
=
true
;
this
.
modal
=
true
;
},
},
...
...
pages/order/monitoring/index.vue
View file @
f12229c9
<
template
>
<
template
>
<div
class=
"monitoring h100"
>
<div
class=
"monitoring h100"
>
<DataGrid
:columns=
"columns"
ref=
"grid"
:action=
"action"
>
<DataGrid
:columns=
"columns"
ref=
"grid"
:action=
"action"
>
<template
slot=
"easySearch"
>
<template
slot=
"easySearch"
>
<Form
ref=
"formInline"
:model=
"easySearch"
inline
style=
"margin-top:5px;"
>
<Form
ref=
"formInline"
:model=
"easySearch"
inline
style=
"margin-top:5px;"
>
<FormItem
prop=
"productingpreparationpeople"
style=
"width:200px"
>
<FormItem
prop=
"productingpreparationpeople"
style=
"width:200px"
>
<departmentSelect
v-model=
"easySearch.productingpreparationpeople.value"
:type=
"3"
></departmentSelect>
<departmentSelect
v-model=
"easySearch.productingpreparationpeople.value"
:type=
"3"
></departmentSelect>
</FormItem>
</FormItem>
<FormItem
prop=
"keys"
>
<FormItem
prop=
"keys"
>
<Input
placeholder=
"请输入订单编号"
v-model=
"easySearch.keys.value"
/>
<Input
placeholder=
"请输入订单编号"
v-model=
"easySearch.keys.value"
/>
</FormItem>
</FormItem>
<FormItem>
<FormItem>
<Button
type=
"primary"
@
click=
"search"
>
查询
</Button>
<Button
type=
"primary"
@
click=
"search"
>
查询
</Button>
</FormItem>
</FormItem>
</Form>
</Form>
</
template
>
</
template
>
<
template
slot=
"searchForm"
>
<
template
slot=
"searchForm"
>
<Search
/>
<Search
/>
</
template
>
</
template
>
</DataGrid>
</DataGrid>
<Modal
v-model=
"suspendModal"
title=
"暂停原因"
footer-hide
class=
"suspend"
>
<Modal
v-model=
"suspendModal"
title=
"暂停原因"
footer-hide
class=
"suspend"
>
<Suspend
@
on-close=
"cancel"
@
on-ok=
"suspendOk"
ref=
"addBug"
:rowSuspend=
"rowSuspend"
/>
<Suspend
@
on-close=
"cancel"
@
on-ok=
"suspendOk"
ref=
"addBug"
:rowSuspend=
"rowSuspend"
/>
</Modal>
</Modal>
<Modal
v-model=
"recordModal"
title=
"暂停记录"
fullscreen
footer-hide
class=
"recordM"
>
<Modal
v-model=
"recordModal"
title=
"暂停记录"
fullscreen
footer-hide
class=
"recordM"
>
<Record
:eid=
"recordId"
/>
<Record
:eid=
"recordId"
/>
</Modal>
</Modal>
<Modal
v-model=
"SpeedModal"
title=
"工单信息"
fullscreen
footer-hide
class=
"recordM"
>
<Modal
v-model=
"SpeedModal"
title=
"工单信息"
fullscreen
footer-hide
class=
"recordM"
>
<Speed
<Speed
:result=
"result"
:load=
"loading"
@
on-close=
"clsoeSpeedModal"
:executeId=
"dispatchExecuteId"
:orderId=
"orderId"
/>
:result=
"result"
:load=
"loading"
@
on-close=
"clsoeSpeedModal"
:executeId=
"dispatchExecuteId"
:orderId=
"orderId"
/>
</Modal>
</Modal>
<Modal
v-model=
"recycleModal"
title=
"确定回收订单"
width=
"600"
class=
"suspend"
>
<Modal
v-model=
"recycleModal"
title=
"确定回收订单"
width=
"600"
class=
"suspend"
>
<Form
ref=
"form"
:model=
"recovery"
:rules=
"rulesRecycle"
:label-width=
"120"
>
<Form
ref=
"form"
:model=
"recovery"
:rules=
"rulesRecycle"
:label-width=
"120"
>
<Row>
<Row>
<Col
:span=
"24"
>
<Col
:span=
"24"
>
<FormItem
:label=
"l('mesCode')"
>
{{mesCode}}
</FormItem>
<FormItem
:label=
"l('mesCode')"
>
{{mesCode}}
</FormItem>
</Col>
</Col>
<Col
:span=
"24"
>
<Col
:span=
"24"
>
<FormItem
:label=
"l('demandFinishDate')"
prop=
"demandFinishDate"
>
<FormItem
:label=
"l('demandFinishDate')"
prop=
"demandFinishDate"
>
<DatePicker
<DatePicker
type=
"date"
placeholder=
"请选择日期"
style=
"width:240px"
v-model=
"recovery.demandFinishDate"
></DatePicker>
type=
"date"
</FormItem>
placeholder=
"请选择日期"
</Col>
style=
"width:240px"
</Row>
v-model=
"recovery.demandFinishDate"
</Form>
></DatePicker>
<div
slot=
"footer"
>
</FormItem>
<Button
@
click=
"cancelRecycle"
>
取消
</Button>
</Col>
<Button
type=
"primary"
@
click=
"changeFinishiDate"
>
确定
</Button>
</Row>
</div>
</Form>
<div
slot=
"footer"
>
<Button
@
click=
"cancelRecycle"
>
取消
</Button>
<Button
type=
"primary"
@
click=
"changeFinishiDate"
>
确定
</Button>
</div>
</Modal>
</Modal>
</div>
</div>
</template>
</template>
<
script
>
<
script
>
import
Api
from
"./api"
;
import
Api
from
"./api"
;
import
Suspend
from
"./suspend"
;
import
Suspend
from
"./suspend"
;
...
@@ -66,580 +56,595 @@ import Search from "./search";
...
@@ -66,580 +56,595 @@ import Search from "./search";
import
Speed
from
"./speed"
;
import
Speed
from
"./speed"
;
export
default
{
export
default
{
name
:
"index"
,
name
:
"index"
,
components
:
{
components
:
{
Record
,
Record
,
Search
,
Search
,
Suspend
,
Suspend
,
Speed
,
Speed
,
},
},
data
()
{
data
()
{
return
{
return
{
result
:
[],
result
:
[],
dispatchExecuteId
:
null
,
//任务id
dispatchExecuteId
:
null
,
//任务id
orderId
:
null
,
//订单id
orderId
:
null
,
//订单id
SpeedModal
:
false
,
SpeedModal
:
false
,
rowSuspend
:
{},
rowSuspend
:
{},
recordId
:
0
,
recordId
:
0
,
laster
:
0
,
laster
:
0
,
action
:
Api
.
index
,
action
:
Api
.
index
,
easySearch
:
{
easySearch
:
{
keys
:
{
op
:
"mesCode"
,
value
:
null
},
keys
:
{
productingpreparationpeople
:
{
op
:
"Equal"
,
value
:
null
},
op
:
"mesCode"
,
},
value
:
null
suspendModal
:
false
,
},
recordModal
:
false
,
productingpreparationpeople
:
{
deletelModal
:
false
,
op
:
"Equal"
,
recycleModal
:
false
,
value
:
null
curId
:
0
,
},
columns
:
[
},
{
key
:
"id"
,
title
:
this
.
l
(
"id"
),
hide
:
true
,
align
:
"left"
},
suspendModal
:
false
,
{
recordModal
:
false
,
title
:
"序号"
,
deletelModal
:
false
,
type
:
"index"
,
recycleModal
:
false
,
width
:
70
,
curId
:
0
,
align
:
"center"
,
columns
:
[{
},
key
:
"id"
,
{
title
:
this
.
l
(
"id"
),
key
:
"status"
,
hide
:
true
,
title
:
this
.
l
(
"status"
),
align
:
"left"
code
:
"plan.order.status"
,
},
align
:
"center"
,
{
easy
:
true
,
title
:
"序号"
,
high
:
true
,
type
:
"index"
,
width
:
100
,
width
:
70
,
},
align
:
"center"
,
{
},
key
:
"mesCode"
,
{
title
:
this
.
l
(
"mesCode"
),
key
:
"status"
,
align
:
"left"
,
title
:
this
.
l
(
"status"
),
render
:
(
h
,
params
)
=>
{
code
:
"plan.order.status"
,
return
h
(
"div"
,
[
align
:
"center"
,
params
.
row
.
mesCode
,
easy
:
true
,
[
high
:
true
,
h
(
width
:
100
,
"Poptip"
,
},
{
{
props
:
{
key
:
"mesCode"
,
content
:
"开工预警:"
+
params
.
row
.
startWarning
+
"条"
,
title
:
this
.
l
(
"mesCode"
),
trigger
:
"hover"
,
align
:
"left"
,
},
render
:
(
h
,
params
)
=>
{
style
:
{
return
h
(
"div"
,
[
cursor
:
"pointer"
,
params
.
row
.
mesCode
,
},
[
},
h
(
[
"Poptip"
,
{
h
(
props
:
{
params
.
row
.
startWarning
>
0
?
"Badge"
:
""
,
content
:
"开工预警:"
+
params
.
row
.
startWarning
+
"条"
,
{
trigger
:
"hover"
,
props
:
{
},
type
:
"warning"
,
style
:
{
// count: 2,
cursor
:
"pointer"
,
count
:
params
.
row
.
startWarning
,
},
},
},
style
:
{
[
marginTop
:
"12px"
,
h
(
marginLeft
:
"5px"
,
params
.
row
.
startWarning
>
0
?
"Badge"
:
""
,
{
},
props
:
{
},
type
:
"warning"
,
[
// count: 2,
h
(
"Icon"
,
{
count
:
params
.
row
.
startWarning
,
props
:
{
},
type
:
"md-alert"
,
style
:
{
},
marginTop
:
"12px"
,
style
:
{
marginLeft
:
"5px"
,
fontSize
:
"16px"
,
},
color
:
"#f1cb08"
,
},
},
[
}),
h
(
"Icon"
,
{
]
props
:
{
),
type
:
"md-alert"
,
]
},
),
style
:
{
h
(
fontSize
:
"16px"
,
"Poptip"
,
color
:
"#f1cb08"
,
{
},
props
:
{
}),
content
:
"完工预警:"
+
params
.
row
.
finishWarning
+
"条"
,
]
trigger
:
"hover"
,
),
]
),
h
(
"Poptip"
,
{
props
:
{
content
:
"完工预警:"
+
params
.
row
.
finishWarning
+
"条"
,
trigger
:
"hover"
,
},
},
[
h
(
params
.
row
.
finishWarning
>
0
?
"Badge"
:
""
,
{
props
:
{
type
:
"info"
,
// count: 2,
count
:
params
.
row
.
finishWarning
,
},
style
:
{
marginTop
:
"12px"
,
marginLeft
:
"5px"
,
},
},
[
h
(
"Icon"
,
{
props
:
{
type
:
"md-alert"
,
},
style
:
{
fontSize
:
"16px"
,
color
:
"#31F8E6"
,
marginLeft
:
"5px"
,
},
}),
]
),
]
),
],
]);
},
},
},
},
[
h
(
params
.
row
.
finishWarning
>
0
?
"Badge"
:
""
,
{
props
:
{
type
:
"info"
,
// count: 2,
count
:
params
.
row
.
finishWarning
,
},
style
:
{
marginTop
:
"12px"
,
marginLeft
:
"5px"
,
},
},
[
h
(
"Icon"
,
{
props
:
{
type
:
"md-alert"
,
},
style
:
{
fontSize
:
"16px"
,
color
:
"#31F8E6"
,
marginLeft
:
"5px"
,
},
}),
]
),
]
),
],
]);
},
},
{
key
:
"productName"
,
title
:
this
.
l
(
"productName"
),
align
:
"left"
,
easy
:
true
,
high
:
true
,
},
{
key
:
"demandStartDate"
,
title
:
this
.
l
(
"demandStartDate"
),
align
:
"center"
,
high
:
true
,
width
:
130
,
render
:
(
h
,
params
)
=>
{
return
h
(
"span"
,
this
.
sliceStr
(
params
.
row
.
demandStartDate
+
" "
,
0
,
10
),
params
.
row
.
demandStartDate
);
},
},
{
key
:
"demandFinishDate"
,
title
:
this
.
l
(
"demandFinishDate"
),
align
:
"center"
,
high
:
true
,
width
:
130
,
render
:
(
h
,
params
)
=>
{
return
h
(
"span"
,
this
.
sliceStr
(
params
.
row
.
demandFinishDate
+
" "
,
0
,
10
),
params
.
row
.
demandFinishDate
);
},
},
{
key
:
"actualStartDate"
,
title
:
this
.
l
(
"actualStartDate"
),
align
:
"center"
,
high
:
true
,
width
:
150
,
render
:
(
h
,
params
)
=>
{
return
h
(
"span"
,
// this.sliceStr(params.row.actualStartDate + ' ', 0, 10),
params
.
row
.
actualStartDate
==
"0001-01-01 00:00:00"
?
""
:
params
.
row
.
actualStartDate
);
},
},
{
key
:
"actualFinishDate"
,
title
:
this
.
l
(
"actualFinishDate"
),
align
:
"center"
,
high
:
true
,
width
:
150
,
render
:
(
h
,
params
)
=>
{
return
h
(
"span"
,
// this.sliceStr(params.row.actualFinishDate + ' ', 0, 10),
params
.
row
.
actualFinishDate
==
"0001-01-01 00:00:00"
?
""
:
params
.
row
.
actualFinishDate
);
},
},
{
key
:
"routingType"
,
title
:
this
.
l
(
"routingType"
),
align
:
"left"
,
code
:
"mes_xingchi_plan.order_material.routingType"
,
easy
:
true
,
high
:
true
,
width
:
100
,
},
{
title
:
this
.
l
(
"jindu"
),
key
:
"action"
,
width
:
200
,
align
:
"center"
,
render
:
(
h
,
params
)
=>
{
return
h
(
"div"
,
[
h
(
"ButtonGroup"
,
{
{
props
:
{
key
:
"productName"
,
shape
:
"circle"
,
title
:
this
.
l
(
"productName"
),
},
align
:
"left"
,
easy
:
true
,
high
:
true
,
},
},
[
h
(
{
"Button
"
,
key
:
"demandStartDate
"
,
{
title
:
this
.
l
(
"demandStartDate"
),
style
:
{
align
:
"center"
,
background
:
"#e4e6ed "
,
high
:
true
,
borderColor
:
"#e4e6ed "
,
width
:
130
,
},
render
:
(
h
,
params
)
=>
{
on
:
{
return
h
(
click
:
()
=>
{
"span"
,
this
.
speed
(
params
.
row
);
this
.
sliceStr
(
params
.
row
.
demandStartDate
+
" "
,
0
,
10
),
},
params
.
row
.
demandStartDate
},
);
},
},
params
.
row
.
unstartCount
//未开工数
},
),
{
h
(
key
:
"demandFinishDate"
,
"Button"
,
title
:
this
.
l
(
"demandFinishDate"
),
{
align
:
"center"
,
style
:
{
high
:
true
,
background
:
"#ffc000"
,
width
:
130
,
borderColor
:
"#ffc000"
,
render
:
(
h
,
params
)
=>
{
},
return
h
(
on
:
{
"span"
,
click
:
()
=>
{
this
.
sliceStr
(
params
.
row
.
demandFinishDate
+
" "
,
0
,
10
),
this
.
speed
(
params
.
row
);
params
.
row
.
demandFinishDate
},
);
},
},
},
params
.
row
.
startCount
//开工数
},
),
{
h
(
key
:
"actualStartDate"
,
"Button"
,
title
:
this
.
l
(
"actualStartDate"
),
align
:
"center"
,
{
high
:
true
,
style
:
{
width
:
150
,
background
:
"#ff7a8b"
,
render
:
(
h
,
params
)
=>
{
borderColor
:
"#ff7a8b"
,
return
h
(
},
"span"
,
// this.sliceStr(params.row.actualStartDate + ' ', 0, 10),
on
:
{
params
.
row
.
actualStartDate
==
"0001-01-01 00:00:00"
?
click
:
()
=>
{
""
:
this
.
speed
(
params
.
row
);
params
.
row
.
actualStartDate
},
);
},
},
},
params
.
row
.
stopCount
//暂停数
},
),
{
h
(
key
:
"actualFinishDate"
,
"Button"
,
title
:
this
.
l
(
"actualFinishDate"
)
,
{
align
:
"center"
,
style
:
{
high
:
true
,
background
:
"#27c149"
,
width
:
150
,
borderColor
:
"#27c149"
,
render
:
(
h
,
params
)
=>
{
// color: '#fff'
return
h
(
}
,
"span"
,
on
:
{
// this.sliceStr(params.row.actualFinishDate + ' ', 0, 10),
click
:
()
=>
{
params
.
row
.
actualFinishDate
==
"0001-01-01 00:00:00"
?
this
.
speed
(
params
.
row
);
""
:
},
params
.
row
.
actualFinishDate
},
);
},
},
params
.
row
.
finishCount
//完成数
},
),
]
),
]);
},
},
{
key
:
"remark"
,
title
:
this
.
l
(
"remark"
),
align
:
"center"
,
hide
:
true
,
},
{
title
:
"暂停记录"
,
key
:
"zanting"
,
width
:
100
,
align
:
"center"
,
render
:
(
h
,
params
)
=>
{
return
h
(
"div"
,
{
class
:
"action"
},
[
h
(
"op"
,
{
{
attrs
:
{
oprate
:
"record"
,
class
:
"edit"
},
key
:
"routingType"
,
on
:
{
click
:
()
=>
this
.
record
(
params
.
row
.
id
)
},
title
:
this
.
l
(
"routingType"
),
align
:
"center"
,
code
:
"mes_xingchi_plan.order_material.routingType"
,
easy
:
true
,
high
:
true
,
width
:
100
,
},
},
"暂停记录"
),
]);
},
},
{
title
:
"操作"
,
key
:
"caozuo"
,
width
:
100
,
align
:
"center"
,
render
:
(
h
,
params
)
=>
{
return
h
(
"div"
,
{
class
:
"action"
},
[
h
(
(
params
.
row
.
status
==
5
&&
params
.
row
.
upSplitId
==
0
)
||
(
params
.
row
.
status
==
5
&&
params
.
row
.
upSplitId
>
0
&&
params
.
row
.
splitCardStatus
==
1
)
?
"Button"
:
""
,
//订单状态暂停,启动
{
{
props
:
{
title
:
this
.
l
(
"jindu"
),
type
:
"error"
,
key
:
"action"
,
size
:
"small"
,
width
:
200
,
icon
:
"md-play"
,
align
:
"center"
,
ghost
:
true
,
render
:
(
h
,
params
)
=>
{
},
return
h
(
"div"
,
[
style
:
{
h
(
fontSize
:
"18px"
,
"ButtonGroup"
,
{
width
:
"50px"
,
props
:
{
height
:
"25px"
,
shape
:
"circle"
,
paddingTop
:
"0"
,
},
},
},
on
:
{
[
click
:
()
=>
{
h
(
this
.
start
(
params
.
row
);
"Button"
,
{
style
:
{
background
:
"#e4e6ed "
,
borderColor
:
"#e4e6ed "
,
},
on
:
{
click
:
()
=>
{
this
.
speed
(
params
.
row
);
},
},
},
params
.
row
.
unstartCount
//未开工数
),
h
(
"Button"
,
{
style
:
{
background
:
"#ffc000"
,
borderColor
:
"#ffc000"
,
},
on
:
{
click
:
()
=>
{
this
.
speed
(
params
.
row
);
},
},
},
params
.
row
.
startCount
//开工数
),
h
(
"Button"
,
{
style
:
{
background
:
"#ff7a8b"
,
borderColor
:
"#ff7a8b"
,
},
on
:
{
click
:
()
=>
{
this
.
speed
(
params
.
row
);
},
},
},
params
.
row
.
stopCount
//暂停数
),
h
(
"Button"
,
{
style
:
{
background
:
"#27c149"
,
borderColor
:
"#27c149"
,
// color: '#fff'
},
on
:
{
click
:
()
=>
{
this
.
speed
(
params
.
row
);
},
},
},
params
.
row
.
finishCount
//完成数
),
]
),
]);
},
},
},
},
},
""
),
h
(
params
.
row
.
status
==
6
?
"Button"
:
""
,
//订单状态执行中,暂停
{
{
props
:
{
key
:
"remark"
,
type
:
"success"
,
title
:
this
.
l
(
"remark"
),
size
:
"small"
,
align
:
"center"
,
icon
:
"ios-pause"
,
hide
:
true
,
ghost
:
true
,
},
tooltip
:
"暂停"
,
{
},
title
:
"暂停记录"
,
style
:
{
key
:
"zanting"
,
fontSize
:
"18px"
,
width
:
100
,
width
:
"50px"
,
align
:
"center"
,
height
:
"25px"
,
render
:
(
h
,
params
)
=>
{
paddingTop
:
"0"
,
return
h
(
"div"
,
{
},
class
:
"action"
on
:
{
},
[
click
:
()
=>
{
h
(
this
.
suspend
(
params
.
row
);
"op"
,
{
attrs
:
{
oprate
:
"record"
,
class
:
"edit"
},
on
:
{
click
:
()
=>
this
.
record
(
params
.
row
.
id
)
},
},
"暂停记录"
),
]);
},
},
},
},
},
""
),
h
(
params
.
row
.
status
==
5
&&
params
.
row
.
splitCardStatus
==
0
?
"op"
:
""
,
//订单状态执行中,暂停
{
{
attrs
:
{
title
:
"操作"
,
icon
:
"md-sync"
,
key
:
"caozuo"
,
type
:
"icon"
,
width
:
100
,
title
:
"回收订单"
,
align
:
"center"
,
oprate
:
"edit"
,
render
:
(
h
,
params
)
=>
{
msg
:
"确认要恢复工序吗?"
,
return
h
(
"div"
,
{
},
class
:
"action"
on
:
{
},
[
click
:
()
=>
{
h
(
this
.
recycle
(
params
.
row
);
(
params
.
row
.
status
==
5
&&
params
.
row
.
upSplitId
==
0
)
||
(
params
.
row
.
status
==
5
&&
params
.
row
.
upSplitId
>
0
&&
params
.
row
.
splitCardStatus
==
1
)
?
"Button"
:
""
,
//订单状态暂停,启动
{
props
:
{
type
:
"error"
,
size
:
"small"
,
icon
:
"md-play"
,
ghost
:
true
,
},
style
:
{
fontSize
:
"18px"
,
width
:
"50px"
,
height
:
"25px"
,
paddingTop
:
"0"
,
},
on
:
{
click
:
()
=>
{
this
.
start
(
params
.
row
);
},
},
},
""
),
h
(
params
.
row
.
status
==
6
?
"Button"
:
""
,
//订单状态执行中,暂停
{
props
:
{
type
:
"success"
,
size
:
"small"
,
icon
:
"ios-pause"
,
ghost
:
true
,
tooltip
:
"暂停"
,
},
style
:
{
fontSize
:
"18px"
,
width
:
"50px"
,
height
:
"25px"
,
paddingTop
:
"0"
,
},
on
:
{
click
:
()
=>
{
this
.
suspend
(
params
.
row
);
},
},
},
""
),
h
(
params
.
row
.
status
==
5
&&
params
.
row
.
splitCardStatus
==
0
?
"op"
:
""
,
//订单状态执行中,暂停
{
attrs
:
{
icon
:
"md-sync"
,
type
:
"icon"
,
title
:
"回收订单"
,
oprate
:
"edit"
,
msg
:
"确认要恢复工序吗?"
,
},
on
:
{
click
:
()
=>
{
this
.
recycle
(
params
.
row
);
},
},
}
),
]);
},
},
},
},
}
],
),
loading
:
false
,
]);
recovery
:
{
},
orderId
:
null
,
},
demandFinishDate
:
""
,
//计划完成时间
],
},
loading
:
false
,
mesCode
:
""
,
recovery
:
{
rulesRecycle
:
{
orderId
:
null
,
demandFinishDate
:
[{
demandFinishDate
:
""
,
//计划完成时间
required
:
true
,
},
message
:
"请选择计划完成时间"
,
mesCode
:
""
,
trigger
:
"change"
,
rulesRecycle
:
{
type
:
"date"
,
demandFinishDate
:
[
},
],
{
},
required
:
true
,
};
message
:
"请选择计划完成时间"
,
trigger
:
"change"
,
type
:
"date"
,
},
],
},
};
},
mounted
()
{},
async
fetch
({
store
,
params
})
{
await
store
.
dispatch
(
"loadDictionary"
);
// 加载数据字典
},
methods
:
{
search
()
{
this
.
$refs
.
grid
.
reload
(
this
.
easySearch
);
},
record
(
id
)
{
this
.
recordModal
=
true
;
this
.
recordId
=
id
;
},
speed
(
row
)
{
if
(
row
.
finishCount
==
0
&&
row
.
stopCount
==
0
&&
row
.
startCount
==
0
&&
row
.
unstartCount
==
0
)
{
this
.
$Message
.
error
(
"进度数据错误"
);
}
else
{
this
.
result
=
[];
this
.
loading
=
true
;
this
.
SpeedModal
=
true
;
this
.
dispatchExecuteId
=
row
.
dispatchExecuteId
;
this
.
orderId
=
row
.
id
;
Api
.
info
({
routingHeaderId
:
row
.
routingHeaderId
,
dispatchExecuteId
:
row
.
dispatchExecuteId
,
})
.
then
((
r
)
=>
{
if
(
r
.
success
)
{
this
.
result
=
r
.
result
;
this
.
loading
=
false
;
}
})
.
catch
((
err
)
=>
{
this
.
$Message
.
error
(
"连接错误"
);
});
}
},
},
suspendOk
()
{
mounted
()
{},
this
.
suspendModal
=
false
;
async
fetch
({
this
.
$refs
.
grid
.
load
();
store
,
// this.curId = 0
params
})
{
await
store
.
dispatch
(
"loadDictionary"
);
// 加载数据字典
},
},
start
(
row
)
{
methods
:
{
this
.
laster
=
this
.
$store
.
state
.
userInfo
.
login_id
;
search
()
{
this
.
$Modal
.
confirm
({
this
.
$refs
.
grid
.
reload
(
this
.
easySearch
);
title
:
"提示"
,
},
content
:
"<p>确定要启动,是否继续?</p>"
,
record
(
id
)
{
onOk
:
()
=>
{
this
.
recordModal
=
true
;
Api
.
start
({
this
.
recordId
=
id
;
id
:
row
.
id
,
},
status
:
6
,
speed
(
row
)
{
laster
:
this
.
laster
,
if
(
}).
then
((
r
)
=>
{
row
.
finishCount
==
0
&&
if
(
r
.
success
)
{
row
.
stopCount
==
0
&&
this
.
$refs
.
grid
.
load
();
row
.
startCount
==
0
&&
this
.
$Message
.
success
(
"启动成功"
);
row
.
unstartCount
==
0
)
{
this
.
$Message
.
error
(
"进度数据错误"
);
}
else
{
this
.
result
=
[];
this
.
loading
=
true
;
this
.
SpeedModal
=
true
;
this
.
dispatchExecuteId
=
row
.
dispatchExecuteId
;
this
.
orderId
=
row
.
id
;
Api
.
info
({
routingHeaderId
:
row
.
routingHeaderId
,
dispatchExecuteId
:
row
.
dispatchExecuteId
,
})
.
then
((
r
)
=>
{
if
(
r
.
success
)
{
this
.
result
=
r
.
result
;
this
.
loading
=
false
;
}
})
.
catch
((
err
)
=>
{
this
.
$Message
.
error
(
"连接错误"
);
});
}
}
});
// this.suspendModal = true
// this.curId = id
},
},
onCancel
:
()
=>
{
suspendOk
()
{
this
.
$Message
.
info
(
"已取消"
);
this
.
suspendModal
=
false
;
this
.
$refs
.
grid
.
load
();
// this.curId = 0
},
start
(
row
)
{
this
.
laster
=
this
.
$store
.
state
.
userInfo
.
login_id
;
this
.
$Modal
.
confirm
({
title
:
"提示"
,
content
:
"<p>确定要启动,是否继续?</p>"
,
onOk
:
()
=>
{
Api
.
start
({
id
:
row
.
id
,
status
:
6
,
laster
:
this
.
laster
,
}).
then
((
r
)
=>
{
if
(
r
.
success
)
{
this
.
$refs
.
grid
.
load
();
this
.
$Message
.
success
(
"启动成功"
);
}
});
// this.suspendModal = true
// this.curId = id
},
onCancel
:
()
=>
{
this
.
$Message
.
info
(
"已取消"
);
},
});
},
clsoeSpeedModal
()
{
this
.
SpeedModal
=
false
;
},
suspend
(
row
)
{
console
.
log
(
row
);
this
.
suspendModal
=
true
;
this
.
rowSuspend
=
row
;
this
.
$refs
.
addBug
.
getEid
();
},
},
});
},
clsoeSpeedModal
()
{
this
.
SpeedModal
=
false
;
},
suspend
(
row
)
{
console
.
log
(
row
);
this
.
suspendModal
=
true
;
this
.
rowSuspend
=
row
;
this
.
$refs
.
addBug
.
getEid
();
},
removeOk
()
{
removeOk
()
{
Api
.
delete
({
id
:
this
.
curId
}).
then
((
r
)
=>
{
Api
.
delete
({
if
(
r
.
success
)
{
id
:
this
.
curId
this
.
$refs
.
grid
.
load
();
}).
then
((
r
)
=>
{
this
.
deletelModal
=
false
;
if
(
r
.
success
)
{
this
.
$Message
.
success
(
"删除成功"
);
this
.
$refs
.
grid
.
load
();
}
this
.
deletelModal
=
false
;
});
this
.
$Message
.
success
(
"删除成功"
);
},
}
recycle
(
row
)
{
});
//回收订单
},
this
.
recycleModal
=
true
;
recycle
(
row
)
{
this
.
mesCode
=
row
.
mesCode
;
//回收订单
this
.
recovery
=
{
this
.
recycleModal
=
true
;
orderId
:
row
.
id
,
this
.
mesCode
=
row
.
mesCode
;
demandFinishDate
:
row
.
demandFinishDate
,
this
.
recovery
=
{
};
orderId
:
row
.
id
,
},
demandFinishDate
:
row
.
demandFinishDate
,
changeFinishiDate
()
{
};
let
temTime
=
this
.
recovery
.
demandFinishDate
;
},
this
.
recovery
.
demandFinishDate
=
""
;
changeFinishiDate
()
{
this
.
recovery
.
demandFinishDate
=
this
.
getFormatDateEnd
(
temTime
);
let
temTime
=
this
.
recovery
.
demandFinishDate
;
Api
.
orderrecovery
(
this
.
recovery
)
this
.
recovery
.
demandFinishDate
=
""
;
.
then
((
res
)
=>
{
this
.
recovery
.
demandFinishDate
=
this
.
getFormatDateEnd
(
temTime
);
if
(
res
.
success
)
{
Api
.
orderrecovery
(
this
.
recovery
)
this
.
$Message
.
success
(
"回收成功"
);
.
then
((
res
)
=>
{
this
.
$refs
.
grid
.
reload
(
this
.
easySearch
);
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
;
this
.
recycleModal
=
false
;
}
},
})
getFinishedDate
(
value
)
{
.
catch
((
err
)
=>
{
this
.
recovery
.
demandFinishDate
=
value
;
this
.
$Message
.
error
(
"数据连接错误"
);
},
});
getFormatDateEnd
(
dates
)
{
},
const
d
=
new
Date
(
dates
);
cancelRecycle
()
{
const
resDate
=
this
.
mesCode
=
""
;
d
.
getFullYear
()
+
this
.
recovery
=
{
"-"
+
orderId
:
null
,
this
.
p
(
d
.
getMonth
()
+
1
)
+
demandFinishDate
:
""
,
//计划完成时间
"-"
+
};
this
.
p
(
d
.
getDate
())
+
this
.
recycleModal
=
false
;
" 23:59:59"
;
},
return
resDate
;
getFinishedDate
(
value
)
{
},
this
.
recovery
.
demandFinishDate
=
value
;
//截取字符串
},
sliceStr
(
str
,
lenS
,
lenE
)
{
getFormatDateEnd
(
dates
)
{
return
str
.
slice
(
lenS
,
lenE
);
const
d
=
new
Date
(
dates
);
},
const
resDate
=
cancel
()
{
d
.
getFullYear
()
+
this
.
curId
=
0
;
"-"
+
this
.
suspendModal
=
false
;
this
.
p
(
d
.
getMonth
()
+
1
)
+
},
"-"
+
p
(
s
)
{
this
.
p
(
d
.
getDate
())
+
return
Number
(
s
)
<
10
?
"0"
+
s
:
s
;
" 23:59:59"
;
},
return
resDate
;
l
(
key
)
{
},
let
vkey
=
"mes_order_watch"
+
"."
+
key
;
//截取字符串
return
this
.
$t
(
vkey
)
||
key
;
sliceStr
(
str
,
lenS
,
lenE
)
{
},
return
str
.
slice
(
lenS
,
lenE
);
},
cancel
()
{
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
;
},
},
},
};
};
</
script
>
</
script
>
<
style
lang=
"less"
>
<
style
lang=
"less"
>
.ivu-btn-group
>
.ivu-btn {
.ivu-btn-group
>
.ivu-btn {
height: 21px !important;
height: 21px !important;
}
}
.ivu-btn-group {
.ivu-btn-group {
height: 21px !important;
height: 21px !important;
}
}
</
style
>
</
style
>
\ No newline at end of file
pages/produce/orderlist.vue
View file @
f12229c9
...
@@ -102,10 +102,10 @@ export default {
...
@@ -102,10 +102,10 @@ export default {
op
:
"mesCode,productName,drawnNumber"
,
op
:
"mesCode,productName,drawnNumber"
,
value
:
null
,
value
:
null
,
},
},
// s
tatus: {
DispatchS
tatus
:
{
//
op: "In",
op
:
"In"
,
//
value: [12, 14, 5, 7, -1]
value
:
[
12
,
14
,
5
,
7
,
-
1
]
//
}
}
},
},
downUrl
:
fileUrlDown
,
downUrl
:
fileUrlDown
,
columns
:
[{
columns
:
[{
...
...
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