Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
attendance-performance-platform
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
赵啸非
attendance-performance-platform
Commits
c16365fd
Commit
c16365fd
authored
Apr 11, 2023
by
赵啸非
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/master'
parents
332e5796
468eee28
Changes
16
Show whitespace changes
Inline
Side-by-side
Showing
16 changed files
with
397 additions
and
622 deletions
+397
-622
attendance-performance-manager-ui/admin/src/assets/less/base.less
...ce-performance-manager-ui/admin/src/assets/less/base.less
+9
-1
attendance-performance-manager-ui/admin/src/components/FormField.vue
...performance-manager-ui/admin/src/components/FormField.vue
+2
-2
attendance-performance-manager-ui/admin/src/components/Header.vue
...ce-performance-manager-ui/admin/src/components/Header.vue
+0
-1
attendance-performance-manager-ui/admin/src/store.js
attendance-performance-manager-ui/admin/src/store.js
+0
-2
attendance-performance-manager-ui/admin/src/views/attendance/group/view.vue
...ance-manager-ui/admin/src/views/attendance/group/view.vue
+129
-33
attendance-performance-manager-ui/admin/src/views/attendance/leave/record/drawershow.vue
...ui/admin/src/views/attendance/leave/record/drawershow.vue
+1
-1
attendance-performance-manager-ui/admin/src/views/attendance/leave/record/list.vue
...nager-ui/admin/src/views/attendance/leave/record/list.vue
+1
-2
attendance-performance-manager-ui/admin/src/views/dept/list.vue
...ance-performance-manager-ui/admin/src/views/dept/list.vue
+1
-0
attendance-performance-manager-ui/admin/src/views/job/list.vue
...dance-performance-manager-ui/admin/src/views/job/list.vue
+5
-3
attendance-performance-manager-ui/admin/src/views/staff/care/list.vue
...erformance-manager-ui/admin/src/views/staff/care/list.vue
+2
-1
attendance-performance-manager-ui/admin/src/views/staff/drawershow.vue
...rformance-manager-ui/admin/src/views/staff/drawershow.vue
+156
-41
attendance-performance-manager-ui/admin/src/views/staff/list.vue
...nce-performance-manager-ui/admin/src/views/staff/list.vue
+86
-11
attendance-performance-manager-ui/admin/src/views/system/menu/dialogshow.vue
...nce-manager-ui/admin/src/views/system/menu/dialogshow.vue
+2
-2
attendance-performance-manager-ui/admin/src/views/system/menu/dialogshow.vue.bak
...manager-ui/admin/src/views/system/menu/dialogshow.vue.bak
+0
-228
attendance-performance-manager-ui/admin/src/views/system/menu/list.vue
...rformance-manager-ui/admin/src/views/system/menu/list.vue
+3
-2
attendance-performance-manager-ui/admin/src/views/system/menu/list.vue.bak
...mance-manager-ui/admin/src/views/system/menu/list.vue.bak
+0
-292
No files found.
attendance-performance-manager-ui/admin/src/assets/less/base.less
View file @
c16365fd
...
...
@@ -85,7 +85,15 @@ sup {
sub {
bottom: -.25em
}
.mt20{
margin-top: 20px;
}
.mt10{
margin-top: 10px;
}
.ml20{
margin-left: 20px;
}
ins,a {
text-decoration: none;
cursor: pointer;
...
...
attendance-performance-manager-ui/admin/src/components/FormField.vue
View file @
c16365fd
...
...
@@ -4,7 +4,7 @@
<el-form-item
:label=
"label"
:prop=
"prop"
class=
'my-form-field'
>
<slot>
<el-input
:disabled=
'disabled'
:placeholder=
'placeholder'
v-model=
"field"
@
change=
"emit"
@
input=
"emit"
v-if=
'type === "text"'
:class=
"inputClass"
:clearable=
'clearable'
></el-input>
<el-input
:disabled=
'disabled'
:placeholder=
'placeholder'
v-model=
"field"
@
change=
"emit"
@
input=
"emit"
@
focus=
"emit"
v-if=
'type === "text"'
:class=
"inputClass"
:clearable=
'clearable'
></el-input>
<el-input
:disabled=
'disabled'
:placeholder=
'placeholder'
v-model=
"field"
@
change=
"emit"
@
input=
"emit"
type=
'password'
v-if=
'type === "password"'
></el-input>
<el-input-number
:disabled=
'disabled'
v-model=
"field"
size=
"small"
:placeholder=
'placeholder'
@
change=
"emit"
@
input=
"emit"
v-if=
'type === "num"'
></el-input-number>
...
...
@@ -82,7 +82,6 @@ export default {
type
:
String
,
default
:
''
,
},
// 字段所需的枚举类型
enumData
:
{
type
:
Object
,
...
...
@@ -126,6 +125,7 @@ export default {
emit
()
{
this
.
$emit
(
'
input
'
,
this
.
newVal
)
this
.
$emit
(
'
change
'
,
this
.
newVal
)
this
.
$emit
(
''
)
}
},
computed
:
{
...
...
attendance-performance-manager-ui/admin/src/components/Header.vue
View file @
c16365fd
...
...
@@ -73,7 +73,6 @@ export default {
this
.
$router
.
push
({
path
})
let
thirdArr
=
this
.
headBar
.
children
.
find
(
item
=>
item
.
path
===
path
)
let
arr
=
[]
console
.
log
(
thirdArr
,
'
ssssss
'
)
if
(
thirdArr
.
children
.
length
===
0
){
arr
.
push
(
{
...
...
attendance-performance-manager-ui/admin/src/store.js
View file @
c16365fd
...
...
@@ -14,9 +14,7 @@ try {
userData
=
JSON
.
parse
(
window
.
sessionStorage
.
userData
||
'
{}
'
);
currentParentName
=
window
.
sessionStorage
.
currentParentName
||
''
headBar
=
JSON
.
parse
(
window
.
sessionStorage
.
headBar
||
'
{}
'
)
CurrentThirdArr
=
JSON
.
parse
(
window
.
sessionStorage
.
CurrentThirdArr
||
'
{}
'
)
ThirdPath
=
window
.
sessionStorage
.
ThirdPath
||
''
CurrentSecondPath
=
window
.
sessionStorage
.
CurrentSecondPath
||
''
}
catch
(
error
)
{
...
...
attendance-performance-manager-ui/admin/src/views/attendance/group/view.vue
View file @
c16365fd
<
template
>
<div
class=
"container"
>
<el-card
style=
"min-height:80vh"
>
<el-card
style=
"min-height:80vh
;padding:15px
"
>
<tab-pane
:activeName=
"activeName"
:thirdList=
"thirdList"
></tab-pane>
<div>
<div
class=
"mt20"
>
<div>
考勤组名称
</div>
<el-input
placeholder=
"请输入考勤组名称"
></el-input>
<el-input
placeholder=
"请输入考勤组名称"
style=
"width:220px"
class=
"mt10"
></el-input>
</div>
<div>
<div
class=
"flex flex-align-center mt20"
>
<div>
考勤人员
</div>
<el-button
type=
"text"
>
设置
</el-button>
<el-button
type=
"text"
class=
"ml20"
@
click=
"drawer1= true"
>
设置
</el-button>
</div>
<div>
<div
class=
"flex flex-align-center mt10"
style=
"color:#999;font-size:14px"
>
<div>
参与考勤人员
</div>
<
el-button
type=
"text"
>
设置
</el-button
>
<
div
class=
"ml20"
>
未设置
</div
>
</div>
<div>
<div
class=
"flex flex-align-center mt10"
style=
"color:#999;font-size:14px"
>
<div>
无需考勤人员
</div>
<
el-button
type=
"text"
>
设置
</el-button
>
<
div
class=
"ml20"
>
未设置
</div
>
</div>
<div
style=
"height:20px"
></div>
<div>
<div
class=
"flex flex-align-center mt20"
>
<div>
考勤组负责人
</div>
<el-button
type=
"text"
>
设置
</el-button>
<el-button
type=
"text"
class=
"ml20"
@
click=
"drawer2= true"
>
设置
</el-button>
</div>
<div>
<div
class=
"flex flex-align-center mt10"
style=
"color:#999;font-size:14px"
>
<div>
主负责人
</div>
<
el-button
type=
"text"
>
设置
</el-button
>
<
div
class=
"ml20"
>
未设置
</div
>
</div>
<div>
<div
class=
"flex flex-align-center mt10"
style=
"color:#999;font-size:14px"
>
<div>
子负责人
</div>
<
el-button
type=
"text"
>
设置
</el-button
>
<
div
class=
"ml20"
>
未设置
</div
>
</div>
<div>
<div
class=
"flex flex-align-center mt10"
style=
"color:#999;font-size:14px"
>
<div>
子负责人权限
</div>
<
el-button
type=
"text"
>
设置
</el-button
>
<
div
class=
"ml20"
>
未设置
</div
>
</div>
<div
style=
"height:20px"
></div>
<div>
<div
class=
"flex flex-align-center mt20"
>
<div>
考勤时间
</div>
<el-button
type=
"text"
>
设置
</el-button>
<el-button
type=
"text"
class=
"ml20"
@
click=
"drawer3= true"
>
设置
</el-button>
</div>
<div>
<div
class=
"flex flex-align-center mt10"
style=
"color:#999;font-size:14px"
>
<div>
考勤类型
</div>
<
el-button
type=
"text"
>
设置
</el-button
>
<
div
class=
"ml20"
>
未设置
</div
>
</div>
<div>
<div
class=
"flex flex-align-center mt10"
style=
"color:#999;font-size:14px"
>
<div>
工作日设置
</div>
<
el-button
type=
"text"
>
设置
</el-button
>
<
div
class=
"ml20"
>
未设置
</div
>
</div>
<div
style=
"height:20px"
></div>
<div>
<div
class=
"flex flex-align-center mt20"
>
<div>
打卡方式
</div>
<el-button
type=
"text"
>
设置
</el-button>
<el-button
type=
"text"
class=
"ml20"
@
click=
"drawer4= true"
>
设置
</el-button>
</div>
<div>
<div
class=
"flex flex-align-center mt10"
style=
"color:#999;font-size:14px"
>
<div>
考勤方式
</div>
<el-button
type=
"text"
>
设置
</el-button>
<div
class=
"ml20"
>
未设置
</div>
</div>
<div
class=
"mt20"
>
<el-button
type=
"primary"
>
保存设置
</el-button>
<el-button>
全部重置
</el-button>
</div>
</el-card>
<!-- 设置考勤人员 -->
<el-drawer
title=
"考勤人员"
:visible.sync=
"drawer"
direction=
"rtl"
:before-close=
"handleClose"
>
<!-- 考勤人员 -->
<div>
参与考勤人员(0)
</div>
<div>
无需考勤人员(0)
</div>
<!-- 考勤组 -->
<div>
<span>
考勤组负责人:
</span>
<el-select>
<el-option></el-option>
</el-select>
</div>
<div>
<span>
主负责人:
</span>
<el-select>
<el-option></el-option>
</el-select>
</div>
<div>
<span>
子负责人:
</span>
<el-select>
<el-option></el-option>
</el-select>
</div>
<div>
<span>
子负责人权限:
</span>
<el-select>
<el-option></el-option>
</el-select>
</div>
<!-- 考勤时间 -->
<div>
<el-radio-group>
<el-radio
label=
""
>
固定班制(固定时间上下班)
</el-radio>
<el-radio
label=
""
>
排班制(按排班上下班)
</el-radio>
<el-radio
label=
""
>
自由工时(不固定时间上下班)
</el-radio>
</el-radio-group>
</div>
<div>
<div>
工作日设置:
</div>
<div>
<el-tag
type=
"primary"
>
快捷设置班次
</el-tag>
<span>
班次名称:
</span>
<el-button
type=
"text"
>
更改班次
</el-button>
</div>
<!-- 班次表 -->
<el-table
:data=
"weekList"
>
<el-table-column
label=
"工作日"
></el-table-column>
<el-table-column
label=
"班次时间段"
></el-table-column>
<el-table-column
label=
"操作"
>
<template
slot-scope=
"scope"
>
<el-button
type=
"text"
@
click=
"changeBanci(scope.row)"
>
更改班次
</el-button>
</
template
>
</el-table-column>
</el-table>
<div>
<el-checkbox>
法定节假日自动排休
</el-checkbox>
</div>
<div>
<div>
特殊日期
</div>
</div>
</div>
</el-drawer>
<!-- 选择biao -->
</div>
</template>
...
...
@@ -75,7 +153,10 @@
tabPane
},
methods
:
{
changeBanci
(
row
){
console
.
log
(
row
)
this
.
isshowBanci
=
true
}
},
data
()
{
return
{
...
...
@@ -96,7 +177,22 @@
name
:
'
新增考勤组
'
,
path
:
'
/attendance/group/view
'
}
]
],
drawer1
:
false
,
drawer2
:
false
,
drawer3
:
false
,
drawer4
:
false
,
setParams
:{
groupName
:
''
,
personNum
:
''
,
responsiblePerson
:
''
,
type
:
''
,
attendanceTime
:
''
,
remark
:
''
},
drawer
:
true
,
weekList
:[],
isshowBanci
:
false
//班次展示
}
}
}
...
...
attendance-performance-manager-ui/admin/src/views/attendance/leave/record/drawershow.vue
View file @
c16365fd
attendance-performance-manager-ui/admin/src/views/attendance/leave/record/list.vue
View file @
c16365fd
<
template
>
<div
class=
"page"
>
<LayoutTable
:data=
"tableData"
:config=
"tableConfig"
>
</LayoutTable>
<LayoutTable
:data=
"tableData"
:config=
"tableConfig"
></LayoutTable>
<drawer-show
ref=
"drawerform"
@
ok=
"getData"
/>
...
...
attendance-performance-manager-ui/admin/src/views/dept/list.vue
View file @
c16365fd
...
...
@@ -49,6 +49,7 @@
// fuzzy: true
// },
// ],
showType
:
'
treetable
'
,
isshowTabPane
:
true
,
columns
:
[
{
type
:
"
selection
"
,
width
:
60
},
...
...
attendance-performance-manager-ui/admin/src/views/job/list.vue
View file @
c16365fd
...
...
@@ -50,6 +50,7 @@
},
mixins
:
[
table
,
tree
],
created
()
{
this
.
getpositions
()
},
computed
:{
thirdList
(){
...
...
@@ -75,7 +76,9 @@
},
// 获取全部职位
getpositions
(){
this
.
$post
(
"
/job/treeselect
"
,
{}).
then
(({
data
})
=>
{
this
.
areaData
=
data
.
result
})
},
handleClick
(
key
){
this
.
$store
.
commit
(
'
setThirdPath
'
,
key
)
...
...
@@ -131,8 +134,7 @@
}
}
]
},
areaData
:[]
}
}
}
};
...
...
attendance-performance-manager-ui/admin/src/views/staff/care/list.vue
View file @
c16365fd
...
...
@@ -93,6 +93,7 @@ export default {
},
isExport
:
false
,
config
:
{
isshowTabPane
:
true
,
search
:
[
{
name
:
"
staffName
"
,
...
...
@@ -169,7 +170,7 @@ export default {
},
{
type
:
"
excel
"
}).
then
(()
=>
this
.
isExport
=
false
).
catch
(
error
=>
{
this
.
isExport
=
false
;
this
.
$message
.
error
(
error
.
message
);
})
;
})
},
/** 重写新增方法 */
toAdd
(
row
)
{
...
...
attendance-performance-manager-ui/admin/src/views/staff/drawershow.vue
View file @
c16365fd
<
template
>
<div>
<!-- 弹出框表单 -->
<el-drawer
:title=
"title"
...
...
@@ -9,7 +10,6 @@
<el-form
ref=
"form"
:model=
"form"
:rules=
"rules"
label-width=
"120px"
>
<el-row>
<!--
<Field
label=
"性别"
prop=
"gender"
v-model=
"form.gender"
type=
"select"
:enumData=
"dict.gender"
placeholder=
"请选择性别"
/>
-->
<!--
<Field
label=
"出生日期"
prop=
"birthday"
v-model=
"form.birthday"
type=
"date"
/>
-->
<!--
<Field
label=
"照片"
prop=
"photoPath"
v-model=
"form.photoPath"
type=
"textarea"
placeholder=
"请输入照片"
/>
-->
...
...
@@ -22,14 +22,13 @@
<Field
label=
"手机号码"
prop=
"phoneNumber"
v-model=
"form.phoneNumber"
placeholder=
"请输入联系电话"
/>
<Field
label=
"所属部门"
prop=
"deptId"
v-model=
"form.deptId"
placeholder=
"请输入所属部门"
/>
<Field
label=
"职位"
prop=
"positionId"
v-model=
"form.positionId"
type=
"select"
placeholder=
"请选择职位"
/>
<Field
label=
"所属部门"
prop=
"deptName"
v-model=
"form.deptName"
placeholder=
"请选择所属部门"
@
focus=
"ishowBumen = true"
/>
<Field
label=
"工号"
prop=
"positionId"
v-model=
"form.positionId"
placeholder=
"请输入工号"
/>
<Field
label=
"职位"
prop=
"positionId"
v-model=
"form.positionId"
:enumData=
"dict.politicalstatus"
type=
"select"
placeholder=
"请选择职位"
/>
<Field
label=
"是否在政务大厅"
prop=
"positionId"
v-model=
"form.positionId"
placeholder=
"请选择"
type=
"select
"
/>
<Field
label=
"工号"
prop=
"workNum"
v-model=
"form.workNum"
placeholder=
"请输入工号
"
/>
<!--
<Field
label=
"是否在政务大厅"
prop=
"positionId"
v-model=
"form.positionId"
placeholder=
"请选择"
type=
"select"
/>
-->
<!--
<Field
label=
"职位名称"
prop=
"positionName"
v-model=
"form.positionName"
placeholder=
"请输入职位名称"
/>
-->
<!--
<Field
label=
"员工类型"
prop=
"staffType"
v-model=
"form.staffType"
type=
"select"
:enumData=
"dict.staffType"
placeholder=
"请选择员工类型"
/>
-->
<!--
<Field
label=
"员工状态"
prop=
"status"
v-model=
"form.status"
type=
"select"
:enumData=
"dict.status"
placeholder=
"请选择员工状态"
/>
-->
...
...
@@ -42,8 +41,48 @@
<form-buttons
@
submit=
'submitForm'
noCancelBtn
/>
</el-form>
</el-drawer>
<!-- 部门选择 -->
<el-dialog
:visible.sync=
"ishowBumen"
width=
"70%"
>
<el-row
type=
"flex"
:gutter=
"20"
style=
"height:40vh"
>
<el-col
:span=
"12"
>
<el-scrollbar
style=
"height: 100%"
>
<el-tree
size=
"mini"
ref=
"siteTree"
:data=
"bumentree"
id=
"el-tree"
node-key=
"id"
indent=
"4"
:props=
"treeProps"
:load=
"loadNode"
highlight-current
default-expand-all
:expand-on-click-node=
"false"
:render-content=
"renderContent"
@
node-click=
"handleNodeClick"
>
</el-tree>
</el-scrollbar>
</el-col>
<el-col
:span=
"12"
>
<div
class=
"titles"
>
已选部门
</div>
<div
class=
"el-tag flex flex-pack-justify mt10"
v-if=
"deptnode.label"
style=
"max-width:80%"
>
<div>
{{
deptnode
.
label
}}
</div>
<div
@
click=
"cancledept()"
>
<i
class=
"el-icon-close"
></i>
</div>
</div>
</el-col>
</el-row>
<div
class=
"mt20"
>
<el-button
type=
"primary"
size=
"mini"
@
click=
"comfirmbument"
>
确定
</el-button>
<el-button
size=
"mini"
@
click=
"ishowBumen = false"
>
取消
</el-button>
</div>
</el-dialog>
</div>
</
template
>
<
script
>
...
...
@@ -51,11 +90,18 @@
export
default
{
name
:
"
StaffDetail
"
,
mixins
:
[
form
],
props
:{
bumentree
:{
type
:
Array
,
default
:[]
}
},
components
:
{
},
created
()
{
this
.
changePath
(
"
staff
"
)
this
.
getjobSelect
()
},
data
()
{
return
{
...
...
@@ -84,14 +130,61 @@
{
required
:
true
,
message
:
"
请输入员工姓名
"
,
trigger
:
"
blur
"
},
{
max
:
64
,
message
:
"
最多只能录入64个字符
"
,
trigger
:
"
blur
"
,},
],
// createTime: [
// {required: true,message: "请选择创建时间" },
// ],
phoneNumber
:
[
{
required
:
true
,
message
:
"
请输入员工手机号码
"
,
trigger
:
"
blur
"
},
{
max
:
11
,
message
:
"
最多只能录入11个字符
"
,
trigger
:
"
blur
"
,},
],
deptName
:
[
{
required
:
true
,
message
:
"
请选择所属部门
"
,
trigger
:
"
change
"
},
],
positionId
:
[
{
required
:
true
,
message
:
"
请选择职位
"
,
trigger
:
"
blur
"
}
],
workNum
:
[
{
required
:
true
,
message
:
"
请输入工号
"
},
],
},
treeProps
:
{
id
:
"
id
"
,
label
:
"
label
"
,
areaCode
:
"
areaCode
"
,
type
:
"
type
"
,
isLeaf
:
"
isLeaf
"
,
children
:
"
children
"
,
icon
:
"
icon
"
,
},
ishowBumen
:
false
,
deptnode
:{}
}
};
},
methods
:
{
renderContent
:
function
(
h
,
{
node
,
data
,
store
})
{
return
(
<
span
>
<
i
style
=
"
font-size:16px;color:#409EFF
"
class
=
{
data
.
icon
}
><
/i
>
<
span
style
=
"
padding-left: 2px;font-size:14px
"
>
{
node
.
label
}
<
/span
>
<
/span
>
)
},
async
loadNode
(
node
,
resolve
)
{
if
(
node
.
level
===
0
)
{
return
;
}
resolve
(
data
.
result
);
},
// 点击
handleNodeClick
(
node
)
{
if
(
node
.
children
.
length
>
0
){
return
}
this
.
deptnode
=
node
},
comfirmbument
(){
this
.
form
.
deptId
=
this
.
deptnode
.
id
this
.
form
.
deptName
=
this
.
deptnode
.
label
this
.
ishowBumen
=
false
},
/** 编辑 */
edit
(
row
)
{
this
.
reset
()
...
...
@@ -161,6 +254,14 @@
if
(
this
.
$refs
[
refName
])
{
this
.
$refs
[
refName
].
resetFields
();
}
},
cancledept
(){
this
.
deptnode
=
{}
},
getjobSelect
(){
this
.
$post
(
'
/job/list
'
).
then
(
res
=>
{
console
.
log
(
res
)
})
}
}
}
...
...
@@ -172,4 +273,18 @@
color
:
#999
;
font-size
:
15px
;
}
.titles
{
color
:
#409EFF
;
font-size
:
16px
;
display
:
flex
;
align-items
:
center
;
}
.titles
::before
{
content
:
''
;
width
:
6px
;
height
:
16px
;
background-color
:
#409EFF
;
display
:
inline-block
;
margin-right
:
10px
;
}
</
style
>
\ No newline at end of file
attendance-performance-manager-ui/admin/src/views/staff/list.vue
View file @
c16365fd
...
...
@@ -42,19 +42,16 @@
<el-col
:span=
"18"
:xs=
"12"
>
<el-row>
<div
class=
"controllList"
>
</div>
<LayoutTable
notDel
:data=
"tableData"
:config=
"tableConfig"
>
<el-button
type=
"primary"
size=
"mini"
slot=
"table-head-left2"
>
导出
</el-button>
<el-button
type=
"primary"
@
click=
"doExport"
:disabled=
"isExport"
size=
"mini"
slot=
"table-head-left2"
>
导出
</el-button>
<el-dropdown
class=
"moreControll"
slot=
"table-head-left2"
style=
"margin-left:20px"
>
<el-button
type=
"primary"
size=
"mini"
>
更多操作
<i
class=
"el-icon-arrow-down el-icon--right"
></i>
</el-button>
<el-dropdown-menu
slot=
"dropdown"
>
<el-dropdown-item>
同步数据
</el-dropdown-item>
<el-dropdown-item>
导入花名册
</el-dropdown-item>
<el-dropdown-item
@
click=
"handleImport"
>
导入花名册
</el-dropdown-item>
<el-dropdown-item>
历史花名册
</el-dropdown-item>
<el-dropdown-item>
自定义列表字段
</el-dropdown-item>
</el-dropdown-menu>
...
...
@@ -68,8 +65,48 @@
</el-row>
</el-col>
</el-row>
<drawer-show
ref=
"drawerform"
@
ok=
"getData"
/>
<home-page
v-if=
"isshowHome"
:data=
"personData"
></home-page>
<!-- 导入对话框 -->
<el-dialog
:title=
"upload.title"
:visible.sync=
"upload.open"
width=
"400px"
append-to-body
>
<el-upload
ref=
"upload"
:limit=
"1"
accept=
".xlsx, .xls"
:headers=
"upload.headers"
:action=
"upload.url + '?updateSupport=' + upload.updateSupport"
:disabled=
"upload.isUploading"
:on-progress=
"handleFileUploadProgress"
:on-success=
"handleFileSuccess"
:auto-upload=
"false"
drag
>
<i
class=
"el-icon-upload"
></i>
<div
class=
"el-upload__text"
>
将文件拖到此处,或
<em>
点击上传
</em>
</div>
<div
class=
"el-upload__tip"
slot=
"tip"
>
<el-checkbox
v-model=
"upload.updateSupport"
/>
是否更新已经存在的数据
<el-link
type=
"primary"
style=
"font-size: 14px"
@
click=
"downloadTemplate"
>
下载模板
</el-link
>
</div>
<div
class=
"el-upload__tip"
style=
"color: red"
slot=
"tip"
>
提示:仅允许导入“xls”或“xlsx”格式文件!
</div>
</el-upload>
<div
slot=
"footer"
class=
"dialog-footer"
>
<el-button
type=
"primary"
@
click=
"submitFileForm"
>
确 定
</el-button>
<el-button
@
click=
"upload.open = false"
>
取 消
</el-button>
</div>
</el-dialog>
<drawer-show
ref=
"drawerform"
@
ok=
"getData"
:bumentree=
"areaData"
/>
</div>
</
template
>
...
...
@@ -92,6 +129,11 @@
})
},
methods
:
{
/** 导入 */
handleImport
()
{
this
.
upload
.
title
=
"
员工关怀信息导入
"
;
this
.
upload
.
open
=
true
;
},
handleClick
(
key
){
console
.
log
(
key
)
this
.
$store
.
commit
(
'
setThirdPath
'
,
key
)
...
...
@@ -125,17 +167,46 @@
this
.
currentNode
=
node
;
this
.
query
=
{
deptId
:
node
.
id
};
this
.
getData
();
},
doExport
(){
this
.
isExport
=
true
;
this
.
$download
(
"
/staff/list/exportExcel
"
,
{
"
idList
"
:
this
.
selection
,
'
name
'
:
this
.
$route
.
query
[
'
name
'
],
},
{
type
:
"
excel
"
}).
then
(()
=>
this
.
isExport
=
false
).
catch
(
error
=>
{
this
.
isExport
=
false
;
this
.
$message
.
error
(
error
.
message
);
})
}
},
data
()
{
return
{
// 用户导入参数
upload
:
{
// 是否显示弹出层(员工关怀信息导入)
open
:
false
,
// 弹出层标题(员工关怀信息导入)
title
:
"
导入花名册数据
"
,
// 是否禁用上传
isUploading
:
false
,
// 是否更新已经存在的数据
updateSupport
:
0
,
// 上传的地址
url
:
"
/attendance/staff/list/importData
"
,
},
config
:
{
search
:
[
{
name
:
"
name
"
,
type
:
"
text
"
,
label
:
"
员工姓名
或手机号
"
,
label
:
"
员工姓名
"
,
fuzzy
:
true
},
{
name
:
'
phoneNumber
'
,
type
:
'
text
'
,
label
:
'
手机号
'
,
fuzzy
:
true
}
],
columns
:
[
...
...
@@ -163,7 +234,8 @@
},
activeName
:
'
first
'
,
isshowHome
:
false
,
personData
:[]
personData
:[],
isExport
:
false
}
},
computed
:{
...
...
@@ -192,6 +264,9 @@
</
style
>
<
style
lang=
"scss"
scoped
>
.page
{
min-width
:
1400px
;
}
.totalNum
{
background
:
rgba
(
64
,
158
,
255
,
0
.2
);
padding
:
15px
;
...
...
attendance-performance-manager-ui/admin/src/views/system/menu/dialogshow.vue
View file @
c16365fd
...
...
@@ -14,8 +14,8 @@
</el-form-item>
</el-col>
<!--
<Field
label=
"ID"
prop=
"id"
v-model=
"form.id"
v-if=
'pageInfo.type !== "add"'
disabled
/>
-->
<Field
label=
"名称"
prop=
"name"
v-model=
"form.name"
/>
<!--
<Field
label=
"ID"
prop=
"id"
v-model=
"form.id"
v-if=
'pageInfo.type !== "add"'
disabled
/>
-->
<Field
label=
"名称"
prop=
"name"
v-model=
"form.name"
/>
<Field
label=
"权限类型"
prop=
"authType"
v-model=
"form.authType"
:enumData=
'dict.authType'
type=
'select'
/>
<Field
label=
"访问地址"
prop=
"url"
v-model=
"form.url"
/>
<Field
label=
"状态"
prop=
"status"
v-model=
"form.status"
:enumData=
'dict.status'
type=
'radio'
/>
...
...
attendance-performance-manager-ui/admin/src/views/system/menu/dialogshow.vue.bak
deleted
100644 → 0
View file @
332e5796
// 添加,编辑设备
<template>
<!-- 弹出框表单 -->
<el-dialog :title="title" :visible.sync="open" width="35%" append-to-body>
<el-form
ref="form"
:model="form"
:rules="rules"
label-width="110px"
label-position="right"
>
<el-row>
<Field
:span="22"
label="ID"
prop="id"
v-model="form.id"
v-if="pageInfo.type !== 'add'"
disabled
/>
<Field :span="22" label="名称" prop="name" v-model="form.name" />
<Field
:span="22"
label="权限类型"
prop="authType"
v-model="form.authType"
:enumData="dict.authType"
type="select"
/>
<Field
:span="22"
label="父级菜单"
prop="parentId"
v-model="form.parentId"
:enumData="menu"
type="select"
/>
<Field :span="22" label="访问地址" prop="url" v-model="form.url" />
<Field
:span="22"
label="状态"
prop="status"
v-model="form.status"
:enumData="dict.status"
type="radio"
/>
<Field
:span="22"
label="图标"
placeholder="请输入图标名称"
prop="imgPath"
v-model="form.imgPath"
/>
<!-- <Field v-else :span="22" label="图标" prop="imgPath">
<el-radio-group v-model="form.imgPath" class="form-el-radio-group">
<el-radio-button label="">不需要图标</el-radio-button>
<el-radio-button
v-for="(icon, index) in icons"
:key="index"
:label="icon"
>
<i :class="'el-icon-' + icon"></i>
{{ icon }}
</el-radio-button>
</el-radio-group>
</Field> -->
</el-row>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button
type="primary"
v-if="pageInfo.type !== 'view'"
@click="submitForm"
>确 定</el-button
>
<el-button @click="cancel">取 消</el-button>
</div>
</el-dialog>
</template>
<script>
import form from "@/assets/mixins/formdialog";
import dialogShow from "./dialogshow";
export default {
mixins: [form],
components: {
dialogShow,
},
computed: {
menu() {
let menu = { 0: "无" };
this.$store.state.userData.barList.forEach((item) => {
menu[item.id + ""] = item.name;
});
return menu;
},
},
methods: {
afterSubmit() {
this.$store.dispatch("login");
this.$router.go(-1);
},
/** 编辑 */
edit(row) {
this.reset();
this.query = { id: row.id };
this.urls.currUrl = this.pageInfo.editUrl;
this.getData();
this.pageInfo.type = "edit";
this.title = "修改菜单";
},
/** 新增 */
add(row) {
this.reset();
this.query = { id: row.id };
this.urls.currUrl = this.pageInfo.addUrl;
this.getData();
this.pageInfo.type = "add";
this.open = true;
this.title = "新增菜单";
},
/** 查看*/
view(row) {
this.reset();
this.query = { id: row.id };
this.urls.currUrl = this.pageInfo.viewUrl;
this.getData();
this.pageInfo.type = "view";
this.open = true;
this.title = "菜单详细";
},
/**取消按钮 */
cancel() {
this.open = false;
},
/**获取数据后弹框 */
afterRender(data) {
this.open = true;
},
afterSubmit(data) {
this.open = false;
this.$emit("ok");
},
// 表单重置
reset() {
// this.form={}
this.resetForm("form");
},
resetForm(refName) {
if (this.$refs[refName]) {
this.$refs[refName].resetFields();
}
},
},
data() {
return {
// 遮罩层
loading: true,
// 弹出层标题
title: "菜单",
// 是否显示弹出层
open: false,
toString: ["parentId", "authType", "status"],
icons: [
"info",
"error",
"success",
"warning",
"question",
"tickets",
"document",
"goods",
"sold-out",
"news",
"message",
"date",
"printer",
"time",
"bell",
"mobile-phone",
"service",
"view",
"menu",
"star-on",
"location",
"phone",
"picture",
"delete",
"search",
"edit",
"rank",
"refresh",
"share",
"setting",
"upload",
"upload2",
"download",
"loading",
"reading",
],
rules: {
name: [{ required: true, message: "请输入名称", trigger: "blur" }],
},
};
},
};
</script>
<style lang="less">
.el-select {
width: 100%;
}
.el-date-editor.el-input {
width: 100%;
}
.form-el-radio-group.label {
width: 160px;
}
.el-radio-button__inner {
border: 0;
}
</style>
attendance-performance-manager-ui/admin/src/views/system/menu/list.vue
View file @
c16365fd
<
template
>
<div
className=
"page"
>
<el-card>
<LayoutTable
notPagination
ref=
"layoutTable"
:data=
"tableData"
:config=
"tableConfig"
/>
</el-card>
<dialog-show
ref=
"dialogform"
@
ok=
"getData"
/>
</div>
</
template
>
...
...
attendance-performance-manager-ui/admin/src/views/system/menu/list.vue.bak
deleted
100644 → 0
View file @
332e5796
<template>
<div class="page">
<!-- <LayoutTable :data='tableData' :config='tableConfig' notPagination /> -->
<!-- <dialog-show ref="dialogform" @ok="getData" /> -->
<el-table
:data="tableData"
style="width: 100%;margin-bottom: 20px;"
row-key="id"
border
default-expand-all
:tree-props="{children: 'children', hasChildren: 'hasChildren'}">
<el-table-column
v-for="(item,index) in config.columns" :key="index"
:prop="item.prop"
:label="item.label"
width="180">
</el-table-column>
</el-table>
<el-pagination
@size-change="handleSizeChange"
@current-change="handleCurrentChange"
:current-page="query.page"
:page-sizes="[10, 20, 30, 40]"
:page-size="query.size"
layout="total, sizes, prev, pager, next, jumper"
:total="total">
</el-pagination>
</div>
</template>
<script>
// import table from '@/assets/mixins/table';
import dialogShow from "./dialogshow";
export default {
// mixins: [table],
components: { dialogShow },
methods: {
// 菜单表格
gettableList(){
this.$post('/menu/list',this.query).then(res => {
if(res.code == 1){
// 原数组
let arr = res.data.data
this.tableData = this.resetTableList(arr)
this.total = res.data.total
}
})
},
// 重排表格
resetTableList(arr){
let result = arr.map(item => {
// 一级目录
if(item.childList.length == 0){
return {
...item,
children:[]
}
}else if(item.childList.length > 0){
return {
...item,
children:this.resetTableList(item.childList)
}
}
})
return result
},
//
handleSizeChange(size){
this.query.size = size
this.gettableList()
},
handleCurrentChange(page){
this.query.page = page
this.gettableList()
},
beforeRender(data) {
this.allMenu = this.sortByGroup(this.util_copy(data.data));
console.log(this.allMenu,'菜单数据')
// 存在查询条件,展开全部
if(Object.keys(this.$route.query).length) {
this.select = this.allMenu.filter(i=>!i.parentId).map(i=>i.id);
}
return data;
},
afterRender() {
this.showChild();
},
// 按parentId排序分组
sortByGroup(data) {
return data.filter(i=>!i.parentId).reduce((prev, item)=>{
return prev.concat([item], data.filter(i=>i.parentId == item.id))
}, [])
},
//重排table
resetTable(arr){
// 一级父级
},
// 查看下级菜单
selectHandler({id}) {
// 如果已展开,则关闭
const index = this.select.indexOf(id);
if(index > -1) {
this.select.splice(index, 1);
}else{
this.select.push(id);
}
this.showChild();
},
showChild() {
this.tableData.data = this.allMenu.filter(item=>{
return !item.parentId || this.select.indexOf(item.parentId) > -1
})
},
// 展示菜单图标
showIcon(row, column) {
return <i class={'el-icon-'+row.imgPath}></i>
},
// 操作菜单状态
changeStatus(row, column) {
return (
<my-switch
confirm
url='/menu/save'
row={row}
onChange={this.statusChange}
value={this.tableData.data}
onInput={(data)=>{
this.tableData.data = data;
}}/>
)
},
afterDel(id) {
this.$store.dispatch('login');
},
statusChange() {
this.$store.dispatch('login');
},
handleUp(data) {
let type = 0;
let url = "/menu/upOrDown";
this.switchSort(url, data.id, type);
},
handleDown(data) {
let type = 1;
let url = "/menu/upOrDown";
this.switchSort(url, data.id, type);
},
switchSort(url, id, type) {
this.loading = true;
this.$post(url, {
id: id,
type: type,
})
.then((res) => {
if (res && res.code && res.code == 1) {
this.getData()
this.loading = false;
this.$message.success("更新排序成功!");
}
})
.catch((error) => {
this.loading = false;
this.$message.error(error.message);
});
},
/** 重写新增方法 */
// toAdd(row) {
// this.$refs.dialogform.add(row);
// },
// /** 重写编辑方法 */
// toEdit(row) {
// this.$refs.dialogform.edit(row);
// },
// /** 重写查看方法 */
// toView(row) {
// this.$refs.dialogform.view(row);
// },
},
data() {
return {
tableData:[],
allMenu: [], // 经过分组排序的表格数据
select: [], // 当前展开的树节点
query: {
page:1,
size:10
},
total:0,
config: {
search: [
{
name: 'name',
type: 'text',
label: '菜单名称',
},
],
columns: [
// { type: "selection",reserveSelection:true, width: 60 },
// { type: "index", label: "序号",align:"center", width: 50 },
// {
// width: 60,
// formatter: row => {
// const icon = this.select.indexOf(row.id) === -1 ? 'right' : 'down';
// return (
// !row.parentId||row.childList.length>0
// ? <div onClick={()=>{this.selectHandler(row)}}>
// <i class={'el-icon-arrow-'+icon}></i>
// </div>
// : ''
// )
// }
// },
{
prop: 'id',
label: 'ID',
width: 60,
},
{
prop: 'name',
label: '名称',
width: 160,
},
{
prop: 'imgPath',
label: '图标',
width: 120,
// formatter: this.showIcon,
},
{
prop: 'authType',
label: '权限类型',
formatter: this.formatter,
},
{
prop: 'parentId',
label: '父ID',
},
{
prop: 'url',
label: '地址',
},
{
prop: 'status',
label: '状态',
width: 100,
formatter: this.changeStatus,
},
// {
// label: '操作',
// formatter: (row)=> {
// return (
// <div>
// <el-link
// style="margin-right:5px;margin-left:5px"
// icon="el-icon-top"
// onClick={() => {
// this.handleUp(row);
// }}
// ></el-link>
// <el-link
// style="margin-right:5px;margin-left:5px"
// icon="el-icon-bottom"
// onClick={() => {
// this.handleDown(row);
// }}
// ></el-link>
// <table-buttons noView row={row} onEdit={this.toEdit} onDel={this.toDel} />
// </div>
// )
// },
// },
],
},
}
},
created(){
this.gettableList()
}
}
</script>
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