Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
micro-system
/
system
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 64d9ec70
authored
Nov 12, 2020
by
胡悦
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
添加搜索时间开始限制、编辑时对删除的字典进行处理
1 parent
3e0cf74b
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
30 additions
and
21 deletions
src/styles/common.scss
src/views/dictionaryManage/dictionaryData/index.vue
src/views/dictionaryManage/index.vue
src/views/orginizaManage/index.vue
src/views/user/index.vue
src/views/workLog/index.vue
src/styles/common.scss
View file @
64d9ec7
...
...
@@ -26,7 +26,7 @@
.user-tree
{
margin-top
:
20px
;
padding
:
2
0px
;
padding
:
1
0px
;
// float: left;
display
:
inline-block
;
width
:
200px
;
...
...
src/views/dictionaryManage/dictionaryData/index.vue
View file @
64d9ec7
...
...
@@ -122,7 +122,7 @@ export default {
prop
:
'daterange'
,
pickerOptions
:
{
disabledDate
(
time
)
{
return
time
.
getTime
()
>
Date
.
now
()
;
return
time
.
getTime
()
>
Date
.
now
()
||
time
.
getTime
()
<
new
Date
(
'2017-12-31'
).
getTime
()
}
}
}
...
...
src/views/dictionaryManage/index.vue
View file @
64d9ec7
...
...
@@ -119,7 +119,7 @@ export default {
prop
:
'daterange'
,
pickerOptions
:
{
disabledDate
(
time
)
{
return
time
.
getTime
()
>
Date
.
now
()
;
return
time
.
getTime
()
>
Date
.
now
()
||
time
.
getTime
()
<
new
Date
(
'2017-12-31'
).
getTime
()
}
}
}
...
...
src/views/orginizaManage/index.vue
View file @
64d9ec7
...
...
@@ -366,7 +366,7 @@ export default {
getTableList
(
params
).
then
((
res
)
=>
{
if
(
res
.
code
==
200
)
{
this
.
total
=
res
.
data
.
totalElements
this
.
orginTableData
=
res
.
data
this
.
orginTableData
=
res
.
data
.
list
}
else
{
this
.
orginTableData
=
[]
}
...
...
src/views/user/index.vue
View file @
64d9ec7
...
...
@@ -14,6 +14,7 @@
:data=
"treedata"
accordion
node-key=
"id"
highlight-current
@
node-click=
"handleNodeClick"
:render-content=
"renderContent"
>
...
...
@@ -123,9 +124,8 @@
</div>
</div>
</
template
>
<
script
>
// import UserService from 'services/user';
<
script
>
import
{
getUserList
,
getSuperUser
,
addUser
,
editUser
,
detailUser
,
deleteUser
,
roleList
,
dictInfo
}
from
'services/user'
;
import
{
getSimpleList
,
getTreeOrg
}
from
'services/orginizaManage'
export
default
{
...
...
@@ -214,7 +214,6 @@ export default {
userVisible
:
false
,
userForm
:
{
account
:
''
,
gender
:
'2'
,
departmentName
:
''
,
superiorName
:
''
,
enableStatus
:
true
...
...
@@ -249,6 +248,8 @@ export default {
},
addRule
:
[{
required
:
true
,
message
:
'请输入密码'
,
trigger
:
'blur'
},
{
min
:
6
,
max
:
50
,
message
:
'长度在 6 到 50 个字符'
,
trigger
:
'blur'
}],
sexList
:
[],
positionList
:
[],
// 部门弹窗
filterDialogTitle
:
'选择组织'
,
filterVisible
:
false
,
...
...
@@ -345,11 +346,11 @@ export default {
this
.
userDialogTitle
=
'新增用户'
this
.
$set
(
this
.
userRules
,
'password'
,
this
.
addRule
)
this
.
userForm
=
{
gender
:
'2'
,
departmentName
:
''
,
superiorName
:
''
,
enableStatus
:
true
}
this
.
userForm
.
gender
=
this
.
sexList
.
length
>
0
?
this
.
sexList
[
0
].
dictValue
:
''
this
.
userData
.
map
(
item
=>
{
if
(
item
.
prop
==
'superiorName'
)
{
item
.
hidden
=
true
...
...
@@ -372,15 +373,26 @@ export default {
},
// 编辑触发事件
editEvent
(
row
)
{
console
.
log
(
row
)
detailUser
({
id
:
row
.
id
}).
then
(
res
=>
{
this
.
userDialogTitle
=
'编辑用户'
this
.
userForm
=
JSON
.
parse
(
JSON
.
stringify
(
res
.
data
))
this
.
userForm
.
enableStatus
=
res
.
data
.
enableStatus
==
1
?
true
:
false
this
.
userForm
.
gender
=
this
.
userForm
.
gender
+
''
//
this.userForm.gender = this.userForm.gender + ''
this
.
userData
.
map
(
item
=>
{
if
(
item
.
prop
==
'superiorName'
)
{
item
.
hidden
=
this
.
userForm
.
deptDepth
==
0
}
else
if
(
item
.
prop
==
'gender'
)
{
let
flag
=
false
item
.
options
.
map
(
i
=>
{
if
(
i
.
dictValue
==
this
.
userForm
.
gender
)
flag
=
true
})
this
.
userForm
.
gender
=
flag
?
this
.
userForm
.
gender
+
''
:
''
}
else
if
(
item
.
prop
==
'position'
)
{
let
isFlag
=
false
item
.
options
.
map
(
j
=>
{
if
(
j
.
dictValue
==
this
.
userForm
.
position
)
isFlag
=
true
})
if
(
!
isFlag
)
this
.
userForm
.
position
=
''
}
})
this
.
handleClose
(
res
.
data
)
...
...
@@ -435,10 +447,8 @@ export default {
this
.
filterVisible
=
!
this
.
filterVisible
},
filterConfirm
()
{
console
.
log
(
this
.
$refs
.
tree
.
getCurrentNode
())
if
(
this
.
filterDialogTitle
==
'选择直接上级'
)
{
if
(
this
.
$refs
.
tree
.
getCurrentNode
().
disabled
)
{
console
.
log
(
'jinlaile......'
)
this
.
$message
(
'该选项不可选择为直接上级'
)
}
else
{
this
.
userForm
.
superiorId
=
this
.
$refs
.
tree
.
getCurrentNode
().
id
...
...
@@ -500,19 +510,18 @@ export default {
// 岗位列表
getPosti
(
value
)
{
dictInfo
(
'sys_position'
).
then
(
res
=>
{
// const arr = []
// res.data.map(item => {
// if (!item.disabled) arr.push(item)
// })
res
.
data
.
map
(
item
=>
{
if
(
!
item
.
disabled
)
this
.
positionList
.
length
>
0
?
this
.
positionList
.
push
(
item
)
:
''
})
this
.
userData
[
this
.
userData
.
length
-
1
].
options
=
res
.
data
})
},
getSex
()
{
dictInfo
(
'sys_user_sex'
).
then
(
res
=>
{
// const arr = []
// res.data.map(item => {
// if (!item.disabled) arr.push(item
)
// }
)
res
.
data
.
map
(
item
=>
{
if
(
!
item
.
disabled
)
this
.
sexList
.
push
(
item
)
}
)
console
.
log
(
this
.
sexList
)
this
.
userData
.
map
(
item
=>
{
if
(
item
.
prop
==
'gender'
)
{
item
.
options
=
res
.
data
...
...
src/views/workLog/index.vue
View file @
64d9ec7
...
...
@@ -57,7 +57,7 @@ export default {
prop
:
'daterange'
,
pickerOptions
:
{
disabledDate
(
time
)
{
return
time
.
getTime
()
>
Date
.
now
()
;
return
time
.
getTime
()
>
Date
.
now
()
||
time
.
getTime
()
<
new
Date
(
'2017-12-31'
).
getTime
()
}
}
}
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment