Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
confucius
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
罗超
confucius
Commits
ee2f9cc1
Commit
ee2f9cc1
authored
Dec 10, 2020
by
黄奎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
页面修改
parent
3e6d3973
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
44 additions
and
26 deletions
+44
-26
dept-form.vue
src/components/system/dept-form.vue
+35
-9
post-form.vue
src/components/system/post-form.vue
+6
-7
deptrelation.vue
src/pages/system/deptrelation.vue
+1
-1
post.vue
src/pages/system/post.vue
+2
-9
No files found.
src/components/system/dept-form.vue
View file @
ee2f9cc1
...
...
@@ -37,13 +37,17 @@
<q-input
filled
stack-label
maxlength=
"50"
:dense=
"false"
v-model=
"objOption.DeptSort"
ref=
"DeptSort"
class=
"col-6 q-pr-lg q-pb-lg"
label=
"排序"
/>
<q-select
filled
stack-label
option-value=
"value"
option-label=
"label"
v-model=
"objOption.IsCompany "
ref=
"DeptTier"
:options=
"IsCompanyL"
label=
"是否校区"
:dense=
"false"
class=
"col-6 q-pr-lg q-pb-lg"
emit-value
map-options
/>
ref=
"DeptTier"
:options=
"IsCompanyL"
label=
"是否校区"
:dense=
"false"
class=
"col-6 q-pr-lg q-pb-lg"
emit-value
map-options
/>
<div
class=
"col-6 q-pr-lg q-pb-lg q-pt-lg"
>
<q-toggle
size=
"md"
label=
"状态"
color=
"primary"
:false-value=
"1"
:true-value=
"0"
v-model=
"objOption.Status"
/>
<div
class=
"text-grey-6 text-caption"
>
注意:关闭后,部门将无法正常使用.
</div>
</div>
<q-select
class=
"col-6 q-pb-lg q-pr-lg"
multiple
clearable
filled
stack-label
use-input
use-chips
option-value=
"PostId"
option-label=
"PostName"
v-model=
"tempPost"
ref=
"PostId"
:options=
"PostList"
label=
"关联岗位"
:dense=
"false"
emit-value
map-options
>
</q-select>
</div>
</q-card-section>
<q-separator
/>
...
...
@@ -74,6 +78,9 @@
import
{
queryEmployee
}
from
'../../api/users/user'
import
{
getPostList
}
from
'../../api/system/post'
export
default
{
props
:
{
saveObj
:
{
...
...
@@ -98,7 +105,7 @@
School_Id
:
0
,
//校区编号
DeptTier
:
0
,
//部门层级
DeptSort
:
0
,
//部门排序
IsCompany
:
0
,
//是否校区1是 0否
IsCompany
:
0
,
//是否校区1是 0否
},
optionTitle
:
""
,
returnString
:
[],
//部门树默认值
...
...
@@ -109,13 +116,21 @@
DeptTierList
:
[],
//部门层级列表
schoolList
:
[],
//校区列表
tempManager
:
[],
//负责人编号数组
IsCompanyL
:[
{
label
:
'是'
,
value
:
1
},
{
label
:
'否'
,
value
:
0
},
]
IsCompanyL
:
[{
label
:
'是'
,
value
:
1
},
{
label
:
'否'
,
value
:
0
},
],
PostList
:
[],
//岗位列表
tempPost
:
[],
//选中的岗位列表
}
},
created
()
{
this
.
queryPostList
();
this
.
queryDeptTier
();
this
.
queryDeptTree
();
this
.
getEmployee
();
...
...
@@ -125,6 +140,14 @@
this
.
initObj
()
},
methods
:
{
//获取岗位列表
queryPostList
()
{
getPostList
({}).
then
(
res
=>
{
if
(
res
.
Code
==
1
)
{
this
.
PostList
=
res
.
Data
;
}
})
},
//筛选员工
filterFn
(
val
,
update
)
{
update
(()
=>
{
...
...
@@ -205,6 +228,7 @@
this
.
objOption
.
DeptTier
=
res
.
Data
.
DeptTier
;
this
.
objOption
.
School_Id
=
res
.
Data
.
School_Id
;
this
.
tempManager
=
res
.
Data
.
ManagerList
;
this
.
tempPost
=
res
.
Data
.
ChoosePostList
;
})
this
.
optionTitle
=
"修改部门信息"
}
else
{
...
...
@@ -219,6 +243,7 @@
this
.
objOption
.
DeptTier
=
0
;
this
.
objOption
.
School_Id
=
0
;
this
.
tempManager
=
[];
this
.
tempPost
=
[];
}
},
//关闭弹窗
...
...
@@ -228,7 +253,7 @@
},
//保存部门
saveDept
()
{
if
(
this
.
objOption
.
IsCompany
==
1
&&
this
.
objOption
.
School_Id
==
0
)
{
if
(
this
.
objOption
.
IsCompany
==
1
&&
this
.
objOption
.
School_Id
==
0
)
{
this
.
$q
.
notify
({
type
:
'warning'
,
position
:
'center'
,
...
...
@@ -248,6 +273,7 @@
//去掉第一个字符
tempStr
=
tempStr
.
substr
(
1
);
}
this
.
objOption
.
ChoosePostList
=
this
.
tempPost
;
this
.
objOption
.
ManagerIds
=
tempStr
;
saveDeptInfo
(
this
.
objOption
).
then
(
res
=>
{
this
.
saveLoading
=
false
...
...
@@ -267,7 +293,7 @@
})
},
returnData
(
data
)
{
this
.
objOption
.
School_Id
=
data
;
this
.
objOption
.
School_Id
=
data
;
}
},
}
...
...
src/components/system/post-form.vue
View file @
ee2f9cc1
...
...
@@ -21,7 +21,7 @@
class=
"col-6 q-pr-lg q-pb-lg"
label=
"岗位名称"
:rules=
"[val => !!val || '请填写岗位名称']"
/>
<selectTree
v-if=
"DeptTreeList&&DeptTreeList.length>0"
:treeData=
'DeptTreeList'
:defaultArray=
"returnString"
nodeKey=
"DeptId"
:multiple=
"false"
labelKey=
"DeptName"
childrenKey=
"ChildList"
tipText=
"所属部门"
@
getChild=
"getChild"
classStr=
"col-6 q-pr-lg q-pb-lg"
></selectTree>
@
getChild=
"getChild"
classStr=
"col-6 q-pr-lg q-pb-lg"
style=
"display:none;"
></selectTree>
<div
class=
"col-6 q-pr-lg q-pb-lg q-pt-lg"
>
<q-toggle
size=
"md"
label=
"状态"
color=
"primary"
:false-value=
"1"
:true-value=
"0"
v-model=
"objOption.Status"
/>
...
...
@@ -31,11 +31,10 @@
<div
class=
"text-caption q-mb-lg q-px-md text-grey-6"
>
绑定角色
</div>
<div
class=
"row wrap tranbox"
>
<template>
<el-transfer
filterable
:filter-method=
"filterMethod"
filter-placeholder=
"请输入
城市拼音
"
<el-transfer
filterable
:filter-method=
"filterMethod"
filter-placeholder=
"请输入
关键字
"
:props=
"
{key: 'RoleId',label: 'RoleName'}" v-model="value" :titles="['可选角色', '已选角色']" :data="data">
</el-transfer>
</
template
>
</div>
</q-card-section>
<q-separator
/>
...
...
@@ -79,7 +78,7 @@
objOption
:
{
PostId
:
0
,
//岗位编号
PostName
:
""
,
//岗位名称
RB_Dept_Id
:
0
,
//所属部门
//
RB_Dept_Id: 0, //所属部门
Status
:
0
,
//状态(0-正常,1-禁用),
PostRoleList
:
[],
//岗位角色列表
},
...
...
@@ -133,8 +132,8 @@
PostId
:
this
.
saveObj
.
PostId
}).
then
(
res
=>
{
this
.
objOption
.
PostId
=
res
.
Data
.
PostId
;
this
.
objOption
.
RB_Dept_Id
=
res
.
Data
.
RB_Dept_Id
.
toString
();
this
.
returnString
.
push
(
this
.
objOption
.
RB_Dept_Id
);
//
this.objOption.RB_Dept_Id = res.Data.RB_Dept_Id.toString();
//
this.returnString.push(this.objOption.RB_Dept_Id);
this
.
objOption
.
PostName
=
res
.
Data
.
PostName
;
this
.
objOption
.
Status
=
res
.
Data
.
Status
;
if
(
res
.
Data
.
PostRoleList
.
length
>
0
)
{
...
...
@@ -147,7 +146,7 @@
}
else
{
this
.
optionTitle
=
"新增岗位"
this
.
objOption
.
PostId
=
0
;
this
.
objOption
.
RB_Dept_Id
=
0
;
//
this.objOption.RB_Dept_Id = 0;
this
.
objOption
.
PostName
=
""
;
this
.
objOption
.
Status
=
0
;
}
...
...
src/pages/system/deptrelation.vue
View file @
ee2f9cc1
...
...
@@ -64,7 +64,7 @@
//判断是否是根节点
if
(
item
.
id
==
this
.
DeptList
.
rootId
)
{
item
.
width
=
120
;
item
.
height
=
20
0
;
item
.
height
=
6
0
;
}
});
}
...
...
src/pages/system/post.vue
View file @
ee2f9cc1
...
...
@@ -11,7 +11,7 @@
emit-value
map-options
label=
"状态"
/>
</div>
</div>
</div>
<div
class=
"page-content"
>
<q-table
:pagination=
"msg"
:loading=
"loading"
no-data-label=
"暂无相关数据"
flat
class=
"sticky-tow-column-table"
...
...
@@ -70,16 +70,9 @@
},
{
name
:
'PostName'
,
required
:
true
,
label
:
'岗位名称'
,
align
:
'left'
,
field
:
row
=>
row
.
PostName
},
{
name
:
'DeptName'
,
label
:
'所属部门'
,
field
:
'DeptName'
,
align
:
'left'
field
:
"PostName"
},
{
name
:
'UpdateByName'
,
...
...
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