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
1570df73
Commit
1570df73
authored
1 year ago
by
赵啸非
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
临时修改部门编辑
parent
32935e0a
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
114 additions
and
62 deletions
+114
-62
attendance-performance-manager-ui/admin/src/assets/utils/table.js
...ce-performance-manager-ui/admin/src/assets/utils/table.js
+1
-3
attendance-performance-manager-ui/admin/src/views/dept/dialogshow.vue
...erformance-manager-ui/admin/src/views/dept/dialogshow.vue
+0
-1
attendance-performance-manager-ui/admin/src/views/dept/list.vue
...ance-performance-manager-ui/admin/src/views/dept/list.vue
+102
-54
attendance-performance-manager-ui/admin/src/views/staff/drawershow.vue
...rformance-manager-ui/admin/src/views/staff/drawershow.vue
+7
-1
attendance-performance-manager-ui/admin/vue.config.js
attendance-performance-manager-ui/admin/vue.config.js
+3
-1
attendance-performance-manager/src/main/java/com/mortals/xhx/module/dept/web/DeptController.java
.../java/com/mortals/xhx/module/dept/web/DeptController.java
+1
-2
No files found.
attendance-performance-manager-ui/admin/src/assets/utils/table.js
View file @
1570df73
...
...
@@ -128,8 +128,7 @@ function handleTree(data, id, parentId, children, rootId) {
data
.
map
((
item
)
=>
{
return
item
[
parentId
];
})
)
||
null
;
)
;
//对源数据深度克隆
const
cloneData
=
JSON
.
parse
(
JSON
.
stringify
(
data
));
//循环所有项
...
...
@@ -142,7 +141,6 @@ function handleTree(data, id, parentId, children, rootId) {
//返回第一层
return
father
[
parentId
]
===
rootId
;
});
console
.
log
(
treeData
);
return
treeData
!=
""
?
treeData
:
data
;
}
...
...
This diff is collapsed.
Click to expand it.
attendance-performance-manager-ui/admin/src/views/dept/dialogshow.vue
View file @
1570df73
...
...
@@ -15,7 +15,6 @@
</el-col>
<Field
:span=
"22"
label=
"部门名称"
prop=
"deptName"
v-model=
"form.deptName"
type=
"textarea"
placeholder=
"请输入部门名称"
/>
<Field
:span=
"22"
label=
"部门状态"
prop=
"deptStatus"
v-model=
"form.deptStatus"
type=
"select"
:enumData=
"dict.deptStatus"
placeholder=
"请选择部门状态"
/>
<Field
:span=
"22"
label=
"顺序"
prop=
"orderNum"
v-model=
"form.orderNum"
placeholder=
"请输入顺序"
/>
<Field
:span=
"22"
label=
"备注"
prop=
"remark"
v-model=
"form.remark"
type=
"textarea"
placeholder=
"请输入备注"
/>
...
...
This diff is collapsed.
Click to expand it.
attendance-performance-manager-ui/admin/src/views/dept/list.vue
View file @
1570df73
<
template
>
<div
className=
"page"
>
<el-card
style=
"height:80vh;overflow:scroll-y"
>
<LayoutTable
notPagination
:data=
"tableData"
<LayoutTable
ref=
"layoutTable"
:data=
"tableData"
:config=
"tableConfig"
/>
<dialog-show
ref=
"dialogform"
@
ok=
"getData"
/>
ref=
"layoutTable"
:config=
"tableConfig"
notSearch
></LayoutTable>
</el-card>
<drawer-show
ref=
"drawerform"
@
ok=
"getData"
/>
</div>
</
template
>
<
script
>
/** 表单弹出框模式需引入 */
import
{
handleTree
}
from
"
@/assets/utils/table
"
;
import
{
handleTree
}
from
"
@/assets/utils/table
"
;
import
Treeselect
from
"
@riophae/vue-treeselect
"
;
import
"
@riophae/vue-treeselect/dist/vue-treeselect.css
"
;
import
drawerShow
from
"
./drawershow
"
;
import
table
from
"
@/assets/mixins/table
"
;
import
dialogShow
from
"
./dialogshow
"
;
export
default
{
name
:
"
DeptList
"
,
components
:
{
drawerShow
,
Treeselect
,
},
name
:
"
Dept
"
,
mixins
:
[
table
],
components
:
{
Treeselect
,
dialogShow
},
created
()
{
this
.
query
=
{
page
:
1
,
size
:
-
1
};
},
methods
:
{
afterRender
(
data
)
{
data
.
data
=
handleTree
(
data
.
data
,
"
id
"
,
"
parentId
"
);
console
.
log
(
"
tree
"
,
data
.
data
)
this
.
deptOptions
=
data
.
data
;
this
.
$refs
.
layoutTable
.
showType
=
"
treetable
"
},
handleAdd
(
row
)
{
this
.
$refs
.
dialogform
.
add
(
row
,
this
.
deptOptions
);
},
/** 重写新增方法 */
toAdd
(
row
)
{
this
.
$refs
.
d
rawerform
.
add
(
row
,
this
.
menu
Options
);
this
.
$refs
.
d
ialogform
.
add
(
row
,
this
.
dept
Options
);
},
/** 重写编辑方法 */
toEdit
(
row
)
{
this
.
$refs
.
drawerform
.
edit
(
row
,
this
.
menuOptions
);
this
.
loading
=
true
;
this
.
$post
(
this
.
pageInfo
.
exclude
,
{
id
:
row
.
id
})
.
then
((
res
)
=>
{
if
(
res
&&
res
.
code
&&
res
.
code
==
1
)
{
this
.
deptOptions
=
handleTree
(
res
.
data
.
result
);
this
.
$refs
.
dialogform
.
edit
(
row
,
this
.
deptOptions
);
this
.
loading
=
false
;
}
})
.
catch
((
error
)
=>
{
this
.
$message
.
error
(
error
.
message
);
});
},
/** 重写查看方法 */
toView
(
row
)
{
this
.
$refs
.
drawerform
.
view
(
row
,
this
.
menuOptions
);
},
afterRender
(
data
)
{
data
.
data
=
handleTree
(
data
.
data
,
"
id
"
,
"
parentId
"
);
console
.
log
(
"
tree data:
"
,
data
.
data
);
this
.
menuOptions
=
data
.
data
;
this
.
$refs
.
layoutTable
.
showType
=
"
treetable
"
;
this
.
$refs
.
dialogform
.
view
(
row
,
this
.
deptOptions
);
},
},
data
()
{
return
{
config
:
{
showType
:
"
treetable
"
,
isshowTabPane
:
true
,
/** 树表是否默认展开 */
expand
:
true
,
showType
:
"
treetable
"
,
search
:
[],
columns
:
[
{
type
:
"
selection
"
,
width
:
60
},
{
label
:
"
部门名称
"
,
prop
:
"
deptName
"
},
{
label
:
"
成员数量
"
,
prop
:
"
personNum
"
},
{
label
:
"
负责人
"
,
prop
:
"
workName
"
},
// {label: "部门状态", prop: "deptStatus",formatter: this.formatter},
// {label: "顺序", prop: "orderNum",formatter: this.formatter},
{
label
:
"
部门名称
"
,
prop
:
"
deptName
"
},
{
label
:
"
部门编码
"
,
prop
:
"
deptCode
"
},
{
label
:
"
顺序
"
,
prop
:
"
orderNum
"
},
{
label
:
"
部门人数
"
,
prop
:
"
personNum
"
},
{
label
:
"
绩效分数
"
,
prop
:
"
score
"
,
formatter
:
this
.
formatterMoney
},
// {label: "创建用户", prop: "createUserId", formatter: this.formatter},
{
label
:
"
操作
"
,
width
:
2
4
0
,
formatter
:
(
row
)
=>
{
width
:
2
8
0
,
formatter
:
row
=>
{
return
(
<
table
-
buttons
noAdd
noView
row
=
{
row
}
onEdit
=
{
this
.
toEdit
}
onView
=
{
this
.
toView
}
onDel
=
{
this
.
toDel
}
/
>
<
div
>
<
el
-
button
size
=
"
mini
"
type
=
"
text
"
icon
=
"
el-icon-edit-outline
"
onClick
=
{()
=>
{
this
.
handleAdd
(
row
);
}}
>
新增
<
/el-button
>
<
table
-
buttons
noAdd
noView
row
=
{
row
}
onEdit
=
{
this
.
toEdit
}
onView
=
{
this
.
toView
}
onDel
=
{
this
.
toDel
}
/
>
<
/div
>
);
}
,
}
,
]
,
}
,
}
}
]
}
};
}
,
}
};
</
script
>
<
style
lang=
"scss"
>
.ml-row
{
margin-bottom
:
5px
;
}
.el-radio-button__inner
{
// width: 82px;
height
:
36px
;
border-radius
:
4px
0px
0px
4px
;
border
:
1px
solid
rgba
(
0
,
0
,
0
,
0
)
!
important
;
border-radius
:
2px
!
important
;
background-color
:
rgba
(
0
,
0
,
0
,
0
);
font-size
:
14px
;
font-weight
:
400
;
color
:
#606677
;
line-height
:
14px
;
outline
:
none
;
box-shadow
:
none
;
}
.el-radio-button__orig-radio
:checked
+
.el-radio-button__inner
{
background
:
rgba
(
0
,
0
,
0
,
0
);
border
:
1px
solid
#3E7BFA
!
important
;
color
:
#3E7BFA
;
line-height
:
14px
;
outline
:
none
;
box-shadow
:
none
;
}
.ml-top-button
{
border-color
:
#ffffff
;
background
:
rgba
(
0
,
0
,
0
,
0
);
font-size
:
16px
;
margin
:
0
10px
0
10px
;
}
</
style
>
This diff is collapsed.
Click to expand it.
attendance-performance-manager-ui/admin/src/views/staff/drawershow.vue
View file @
1570df73
...
...
@@ -14,6 +14,8 @@
label-width=
"120px"
style=
"width: 100%;"
>
<div
class=
"cell2"
>
<div
class=
"history"
>
<span>
姓名:
</span>
...
...
@@ -109,6 +111,9 @@
>
</el-switch>
</div>
</div>
<el-row>
<Field
label=
"所属部门"
...
...
@@ -119,7 +124,8 @@
placeholder=
"请选择所属部门"
/>
</div>
</el-row>
<form-buttons
@
submit=
"submitForm"
noCancelBtn
...
...
This diff is collapsed.
Click to expand it.
attendance-performance-manager-ui/admin/vue.config.js
View file @
1570df73
...
...
@@ -10,7 +10,9 @@ module.exports = {
'
/attendance
'
:
{
//target: 'http://192.168.0.98:11039',
// target: 'http://112.19.80.237:11039',
target
:
'
http://localhost:17500
'
,
// target: 'http://localhost:17500',
// target: 'http://118.122.189.109:11039',
target
:
'
http://10.102.252.13:11039
'
,
changeOrigin
:
true
,
secure
:
false
,
cookieDomainRewrite
:
'
localhost
'
,
...
...
This diff is collapsed.
Click to expand it.
attendance-performance-manager/src/main/java/com/mortals/xhx/module/dept/web/DeptController.java
View file @
1570df73
...
...
@@ -66,7 +66,6 @@ public class DeptController extends BaseCRUDJsonBodyMappingController<DeptServic
Map
<
String
,
Object
>
model
=
new
HashMap
<>();
JSONObject
ret
=
new
JSONObject
();
String
busiDesc
=
"查询"
+
this
.
getModuleDesc
();
// Long id = form.getId()[0];
int
code
=
VALUE_RESULT_SUCCESS
;
try
{
List
<
DeptEntity
>
collect
=
this
.
service
.
find
(
new
DeptQuery
()).
stream
().
map
(
item
->
{
...
...
@@ -75,7 +74,7 @@ public class DeptController extends BaseCRUDJsonBodyMappingController<DeptServic
}
return
item
;
}).
filter
(
f
->
f
!=
null
).
collect
(
Collectors
.
toList
());
model
.
put
(
"
result
"
,
collect
);
model
.
put
(
"
data
"
,
collect
);
recordSysLog
(
request
,
busiDesc
+
" 【成功】"
);
}
catch
(
Exception
e
)
{
code
=
VALUE_RESULT_FAILURE
;
...
...
This diff is collapsed.
Click to expand it.
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