Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
9
91isoft_vue_manage
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
杨硕
91isoft_vue_manage
Commits
caebd246
Commit
caebd246
authored
Jul 18, 2023
by
杨硕
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
完善模版项目
parent
39e63d54
Changes
12
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
1157 additions
and
520 deletions
+1157
-520
errorLog.js
src/api/monitor/errorLog.js
+10
-4
loginInfo.js
src/api/monitor/loginInfo.js
+10
-4
operLog.js
src/api/monitor/operLog.js
+10
-4
role.js
src/api/system/role.js
+6
-0
user.js
src/api/system/user.js
+2
-2
index.vue
src/views/monitor/errorLog/index.vue
+36
-30
index.vue
src/views/monitor/loginInfo/index.vue
+66
-48
index.vue
src/views/monitor/operLog/index.vue
+37
-30
data.vue
src/views/system/dict/data.vue
+866
-322
index.vue
src/views/system/role/index.vue
+27
-27
index.vue
src/views/system/user/index.vue
+83
-46
vue.config.js
vue.config.js
+4
-3
No files found.
src/api/monitor/errorLog.js
View file @
caebd246
import
request
from
'@/utils/request'
import
request
from
'@/utils/request'
import
Qs
from
'qs'
// 查询异常日志列表
// 查询异常日志列表
export
function
list
(
query
)
{
export
function
list
(
query
)
{
return
request
({
return
request
({
url
:
'/monitor/errorLog/
list
'
,
url
:
'/monitor/errorLog/
queryErrorLogListByPagination
'
,
method
:
'get'
,
method
:
'get'
,
params
:
query
params
:
query
})
})
}
}
// 删除异常日志
// 删除异常日志
export
function
delErrLog
(
operId
)
{
export
function
delErrLog
(
data
)
{
// data = Qs.stringify(data)
return
request
({
return
request
({
url
:
'/monitor/errorLog/'
+
operId
,
url
:
'/monitor/errorLog/delete'
,
method
:
'delete'
method
:
'post'
,
data
,
headers
:
{
'Content-Type'
:
'application/json;charset=UTF-8'
}
})
})
}
}
...
...
src/api/monitor/loginInfo.js
View file @
caebd246
import
request
from
'@/utils/request'
import
request
from
'@/utils/request'
import
Qs
from
'qs'
// 查询登录日志列表
// 查询登录日志列表
export
function
list
(
query
)
{
export
function
list
(
query
)
{
return
request
({
return
request
({
url
:
'/monitor/loginInfo/
list
'
,
url
:
'/monitor/loginInfo/
querySysLoginListByPagination
'
,
method
:
'get'
,
method
:
'get'
,
params
:
query
params
:
query
})
})
}
}
// 删除登录日志
// 删除登录日志
export
function
delLogininfo
(
infoId
)
{
export
function
delLogininfo
(
data
)
{
// data = Qs.stringify(data)
return
request
({
return
request
({
url
:
'/monitor/loginInfo/'
+
infoId
,
url
:
'/monitor/loginInfo/delete'
,
method
:
'delete'
method
:
'post'
,
data
,
headers
:
{
'Content-Type'
:
'application/json;charset=UTF-8'
}
})
})
}
}
...
...
src/api/monitor/operLog.js
View file @
caebd246
import
request
from
'@/utils/request'
import
request
from
'@/utils/request'
import
Qs
from
'qs'
// 查询操作日志列表
// 查询操作日志列表
export
function
list
(
query
)
{
export
function
list
(
query
)
{
return
request
({
return
request
({
url
:
'/monitor/operLog/
list
'
,
url
:
'/monitor/operLog/
queryOperLogListByPagination
'
,
method
:
'get'
,
method
:
'get'
,
params
:
query
params
:
query
})
})
}
}
// 删除操作日志
// 删除操作日志
export
function
delOperLog
(
operId
)
{
export
function
delOperLog
(
data
)
{
// data = Qs.stringify(data)
return
request
({
return
request
({
url
:
'/monitor/operLog/'
+
operId
,
url
:
'/monitor/operLog/delete'
,
method
:
'delete'
method
:
'post'
,
data
,
headers
:
{
'Content-Type'
:
'application/json;charset=UTF-8'
}
})
})
}
}
...
...
src/api/system/role.js
View file @
caebd246
...
@@ -8,6 +8,12 @@ export function listRole(query) {
...
@@ -8,6 +8,12 @@ export function listRole(query) {
params
:
query
params
:
query
})
})
}
}
export
function
getlistRole
()
{
return
request
({
url
:
'system/role/listAll'
,
method
:
'get'
})
}
// 查询角色详细
// 查询角色详细
export
function
getRole
(
businessId
)
{
export
function
getRole
(
businessId
)
{
...
...
src/api/system/user.js
View file @
caebd246
...
@@ -40,10 +40,10 @@ export function addUser(data) {
...
@@ -40,10 +40,10 @@ export function addUser(data) {
// 修改用户
// 修改用户
export
function
updateUser
(
data
)
{
export
function
updateUser
(
data
)
{
const
businessId
=
data
.
businessId
//
const businessId = data.businessId
data
=
Qs
.
stringify
(
data
)
data
=
Qs
.
stringify
(
data
)
return
request
({
return
request
({
url
:
'/system/user/update
/'
+
businessId
,
url
:
'/system/user/update
'
,
method
:
'put'
,
method
:
'put'
,
data
:
data
,
data
:
data
,
headers
:
{
headers
:
{
...
...
src/views/monitor/errorLog/index.vue
View file @
caebd246
...
@@ -98,7 +98,7 @@
...
@@ -98,7 +98,7 @@
<el-table-column
type=
"selection"
width=
"55"
align=
"center"
/>
<el-table-column
type=
"selection"
width=
"55"
align=
"center"
/>
<el-table-column
:show-overflow-tooltip=
"true"
label=
"日志编号"
width=
"100"
align=
"center"
prop=
"businessId"
>
<el-table-column
:show-overflow-tooltip=
"true"
label=
"日志编号"
width=
"100"
align=
"center"
prop=
"businessId"
>
<template
slot-scope=
"scope"
>
<template
slot-scope=
"scope"
>
{{
scope
.
row
.
oper
Id
||
'-'
}}
{{
scope
.
row
.
business
Id
||
'-'
}}
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
:show-overflow-tooltip=
"true"
label=
"系统模块"
align=
"center"
prop=
"systemMode"
>
<el-table-column
:show-overflow-tooltip=
"true"
label=
"系统模块"
align=
"center"
prop=
"systemMode"
>
...
@@ -200,9 +200,9 @@
...
@@ -200,9 +200,9 @@
</el-col>
</el-col>
</el-row>
</el-row>
</el-form>
</el-form>
<!-- <div slot="footer" class="dialog-footer">-->
<!-- <div slot="footer" class="dialog-footer">-->
<!-- <el-button @click="open = false">关 闭</el-button>-->
<!-- <el-button @click="open = false">关 闭</el-button>-->
<!-- </div>-->
<!-- </div>-->
</el-dialog>
</el-dialog>
</div>
</div>
</template>
</template>
...
@@ -276,22 +276,22 @@ export default {
...
@@ -276,22 +276,22 @@ export default {
// const query = Object.assign({}, this.queryParams)
// const query = Object.assign({}, this.queryParams)
// query.operTime = query.operTime ? this.$parseDate(new Date(query.operTime), 'YYYYMM') : ''
// query.operTime = query.operTime ? this.$parseDate(new Date(query.operTime), 'YYYYMM') : ''
list
(
this
.
addDateRange
(
this
.
queryParams
,
this
.
dateRange
)).
then
(
response
=>
{
list
(
this
.
addDateRange
(
this
.
queryParams
,
this
.
dateRange
)).
then
(
response
=>
{
this
.
list
=
response
.
rows
.
map
(
item
=>
{
this
.
list
=
response
.
rows
.
map
(
item
=>
{
const
title
=
item
.
title
const
title
=
item
.
title
if
(
title
)
{
if
(
title
)
{
const
temp
=
title
.
split
(
'-'
)
const
temp
=
title
.
split
(
'-'
)
const
systemMode
=
temp
.
filter
((
item
,
index
)
=>
{
return
index
<
temp
.
length
-
1
}).
join
(
'-'
)
const
systemMode
=
temp
.
filter
((
item
,
index
)
=>
{
return
index
<
temp
.
length
-
1
}).
join
(
'-'
)
item
.
systemMode
=
systemMode
item
.
systemMode
=
systemMode
item
.
optionName
=
temp
[
temp
.
length
-
1
]
item
.
optionName
=
temp
[
temp
.
length
-
1
]
}
else
{
}
else
{
item
.
systemMode
=
undefined
item
.
systemMode
=
undefined
item
.
optionName
=
undefined
item
.
optionName
=
undefined
}
}
return
item
return
item
})
})
this
.
total
=
response
.
total
this
.
total
=
response
.
total
this
.
loading
=
false
this
.
loading
=
false
}
}
)
)
},
},
// 操作日志状态字典翻译
// 操作日志状态字典翻译
...
@@ -315,7 +315,7 @@ export default {
...
@@ -315,7 +315,7 @@ export default {
},
},
// 多选框选中数据
// 多选框选中数据
handleSelectionChange
(
selection
)
{
handleSelectionChange
(
selection
)
{
this
.
ids
=
selection
.
map
(
item
=>
item
.
oper
Id
)
this
.
ids
=
selection
.
map
(
item
=>
item
.
business
Id
)
},
},
/** 详细按钮操作 */
/** 详细按钮操作 */
handleView
(
row
)
{
handleView
(
row
)
{
...
@@ -329,7 +329,13 @@ export default {
...
@@ -329,7 +329,13 @@ export default {
cancelButtonText
:
'取消'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
type
:
'warning'
}).
then
(()
=>
{
}).
then
(()
=>
{
return
delErrLog
(
this
.
ids
)
const
id
=
this
.
ids
.
join
(
','
)
// TODO: clear this log
console
.
log
(
`this.ids`
,
id
)
const
query
=
{
deleteIds
:
id
}
return
delErrLog
(
query
)
}).
then
(()
=>
{
}).
then
(()
=>
{
this
.
getList
()
this
.
getList
()
this
.
$message
.
success
(
'删除成功'
)
this
.
$message
.
success
(
'删除成功'
)
...
@@ -384,14 +390,14 @@ export default {
...
@@ -384,14 +390,14 @@ export default {
}
}
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
.app-container-errlog
{
.app-container-errlog
{
padding
:
0
;
padding
:
0
;
font-size
:
18px
;
font-size
:
18px
;
.placeholder
{
.placeholder
{
height
:
14px
;
height
:
14px
;
background-color
:
#F4F4F4
;
background-color
:
#F4F4F4
;
margin-bottom
:
10px
margin-bottom
:
10px
}
}
}
}
</
style
>
</
style
>
src/views/monitor/loginInfo/index.vue
View file @
caebd246
...
@@ -80,50 +80,60 @@
...
@@ -80,50 +80,60 @@
<div
style=
"padding:10px"
>
<div
style=
"padding:10px"
>
<div
class=
"mb12 font-small-bold"
>
登录日志列表
</div>
<div
class=
"mb12 font-small-bold"
>
登录日志列表
</div>
<el-table
v-loading=
"loading"
border
:data=
"list"
@
selection-change=
"handleSelectionChange"
>
<el-table
v-loading=
"loading"
border
:data=
"list"
@
selection-change=
"handleSelectionChange"
>
<!--
<el-table-column
type=
"selection"
width=
"55"
align=
"center"
/>
-->
<!--
<el-table-column
type=
"selection"
width=
"55"
align=
"center"
/>
-->
<!-- <!–
<el-table-column
type=
"index"
label=
"序号"
width=
"50"
/>
–>
-->
<!-- <!–
<el-table-column
type=
"index"
label=
"序号"
width=
"50"
/>
–>
-->
<!--
<el-table-column
label=
"访问编号"
width=
"100"
align=
"center"
prop=
"infoId"
show-overflow-tooltip
>
-->
<!--
<el-table-column
label=
"访问编号"
width=
"100"
align=
"center"
prop=
"infoId"
show-overflow-tooltip
>
-->
<!--
<template
slot-scope=
"scope"
>
-->
<!--
<template
slot-scope=
"scope"
>
-->
<!--
{{
scope
.
row
.
infoId
||
'-'
}}
-->
<!--
{{
scope
.
row
.
infoId
||
'-'
}}
-->
<!--
</
template
>
-->
<!--
</
template
>
-->
<!-- </el-table-column>-->
<!-- </el-table-column>-->
<!-- <el-table-column label="用户名称" align="center" prop="userName" show-overflow-tooltip>-->
<!-- <el-table-column label="用户名称" align="center" prop="userName" show-overflow-tooltip>-->
<!-- <template slot-scope="scope">-->
<!-- <template slot-scope="scope">-->
<!-- {{ scope.row.userName || '-' }}-->
<!-- {{ scope.row.userName || '-' }}-->
<!-- </template>-->
<!-- </template>-->
<!-- </el-table-column>-->
<!-- </el-table-column>-->
<!-- <el-table-column label="登录地址" align="center" prop="ipaddr" show-overflow-tooltip>-->
<!-- <el-table-column label="登录地址" align="center" prop="ipaddr" show-overflow-tooltip>-->
<!-- <template slot-scope="scope">-->
<!-- <template slot-scope="scope">-->
<!-- {{ scope.row.ipaddr || '-' }}-->
<!-- {{ scope.row.ipaddr || '-' }}-->
<!-- </template>-->
<!-- </template>-->
<!-- </el-table-column>-->
<!-- </el-table-column>-->
<!-- <el-table-column label="操作信息" align="center" prop="msg" show-overflow-tooltip>-->
<!-- <el-table-column label="操作信息" align="center" prop="msg" show-overflow-tooltip>-->
<!-- <template slot-scope="scope">-->
<!-- <template slot-scope="scope">-->
<!-- {{ scope.row.msg || '-' }}-->
<!-- {{ scope.row.msg || '-' }}-->
<!-- </template>-->
<!-- </template>-->
<!-- </el-table-column>-->
<!-- </el-table-column>-->
<!-- <!– <el-table-column label="登录地址" align="center" prop="ipaddr" width="130" :show-overflow-tooltip="true" />–>-->
<!-- <!– <el-table-column label="登录地址" align="center" prop="ipaddr" width="130" :show-overflow-tooltip="true" />–>-->
<!-- <el-table-column label="登录地点" align="center" prop="loginLocation" :show-overflow-tooltip="true" />-->
<!-- <el-table-column label="登录地点" align="center" prop="loginLocation" :show-overflow-tooltip="true" />-->
<!-- <!– <el-table-column label="浏览器" align="center" prop="browser" show-overflow-tooltip>–>-->
<!-- <!– <el-table-column label="浏览器" align="center" prop="browser" show-overflow-tooltip>–>-->
<!-- <!– <template slot-scope="scope">–>-->
<!-- <!– <template slot-scope="scope">–>-->
<!-- <!– {{ scope.row.browser || '-' }}–>-->
<!-- <!– {{ scope.row.browser || '-' }}–>-->
<!-- <!– </template>–>-->
<!-- <!– </template>–>-->
<!-- <!– </el-table-column>–>-->
<!-- <!– </el-table-column>–>-->
<!-- <!– <el-table-column label="操作系统" align="center" prop="os" show-overflow-tooltip>–>-->
<!-- <!– <el-table-column label="操作系统" align="center" prop="os" show-overflow-tooltip>–>-->
<!-- <!– <template slot-scope="scope">–>-->
<!-- <!– <template slot-scope="scope">–>-->
<!-- <!– {{ scope.row.os || '-' }}–>-->
<!-- <!– {{ scope.row.os || '-' }}–>-->
<!-- <!– </template>–>-->
<!-- <!– </template>–>-->
<!-- <!– </el-table-column>–>-->
<!-- <!– </el-table-column>–>-->
<!-- <el-table-column label="登录状态" align="center" prop="status" :formatter="statusFormat" />-->
<!-- <el-table-column label="登录状态" align="center" prop="status" :formatter="statusFormat" />-->
<el-table-column
type=
"selection"
width=
"55"
align=
"center"
/>
<el-table-column
type=
"selection"
width=
"55"
align=
"center"
/>
<el-table-column
label=
"访问编号"
align=
"center"
prop=
"
info
Id"
/>
<el-table-column
label=
"访问编号"
align=
"center"
prop=
"
business
Id"
/>
<el-table-column
label=
"用户名称"
align=
"center"
prop=
"username"
/>
<el-table-column
label=
"用户名称"
align=
"center"
prop=
"username"
/>
<el-table-column
label=
"登录地址"
align=
"center"
prop=
"ipaddr"
width=
"130"
:show-overflow-tooltip=
"true"
/>
<el-table-column
label=
"登录地址"
align=
"center"
prop=
"ipaddr"
width=
"130"
:show-overflow-tooltip=
"true"
/>
<el-table-column
label=
"登录地点"
align=
"center"
prop=
"loginLocation"
:show-overflow-tooltip=
"true"
/>
<el-table-column
label=
"登录地点"
align=
"center"
prop=
"loginLocation"
:show-overflow-tooltip=
"true"
/>
<!-- <el-table-column label="浏览器" align="center" prop="browser" />
<!-- <el-table-column label="浏览器" align="center" prop="browser" />
<el-table-column label="操作系统" align="center" prop="os" />-->
<el-table-column label="操作系统" align="center" prop="os" />-->
<el-table-column
label=
"登录状态"
align=
"center"
prop=
"status"
:formatter=
"statusFormat"
/>
<!-- <el-table-column label="登录状态" align="center" prop="status" :formatter="statusFormat" />-->
<el-table-column
label=
"提示信息"
align=
"center"
prop=
"msg"
/>
<el-table-column
label=
"登录状态"
align=
"center"
prop=
"status"
>
<
template
slot-scope=
"scope"
>
<span
v-if=
"scope.row.status === '0'"
>
失败
</span>
<span
v-if=
"scope.row.status === '1'"
>
成功
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"提示信息"
align=
"center"
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
msg
||
'-'
}}
</
template
>
</el-table-column>
<el-table-column
label=
"登录时间"
align=
"center"
prop=
"loginTime"
width=
"180"
show-overflow-tooltip
>
<el-table-column
label=
"登录时间"
align=
"center"
prop=
"loginTime"
width=
"180"
show-overflow-tooltip
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
<span>
{{
parseTime
(
scope
.
row
.
loginTime
)
|
transformDateByFormat
(
'YYYY-MM-DD HH:mm:ss'
)
}}
</span>
<span>
{{
parseTime
(
scope
.
row
.
loginTime
)
|
transformDateByFormat
(
'YYYY-MM-DD HH:mm:ss'
)
}}
</span>
...
@@ -144,8 +154,10 @@
...
@@ -144,8 +154,10 @@
<
script
>
<
script
>
import
{
list
,
delLogininfo
,
cleanLogininfo
,
exportLogininfo
}
from
'@/api/monitor/loginInfo'
import
{
list
,
delLogininfo
,
cleanLogininfo
,
exportLogininfo
}
from
'@/api/monitor/loginInfo'
import
dictCons
from
'@/utils/dictCons'
import
dictCons
from
'@/utils/dictCons'
import
Template
from
'@/views/instance/Template'
export
default
{
export
default
{
name
:
'LoginInfo'
,
name
:
'LoginInfo'
,
components
:
{
Template
},
data
()
{
data
()
{
return
{
return
{
// 遮罩层
// 遮罩层
...
@@ -226,7 +238,7 @@ export default {
...
@@ -226,7 +238,7 @@ export default {
},
},
// 多选框选中数据
// 多选框选中数据
handleSelectionChange
(
selection
)
{
handleSelectionChange
(
selection
)
{
this
.
ids
=
selection
.
map
(
item
=>
item
.
info
Id
)
this
.
ids
=
selection
.
map
(
item
=>
item
.
business
Id
)
this
.
multiple
=
!
selection
.
length
this
.
multiple
=
!
selection
.
length
},
},
/** 删除按钮操作 */
/** 删除按钮操作 */
...
@@ -236,7 +248,13 @@ export default {
...
@@ -236,7 +248,13 @@ export default {
cancelButtonText
:
'取消'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
type
:
'warning'
}).
then
(()
=>
{
}).
then
(()
=>
{
return
delLogininfo
(
this
.
ids
)
const
id
=
this
.
ids
.
join
(
','
)
// TODO: clear this log
console
.
log
(
`this.ids`
,
id
)
const
query
=
{
deleteIds
:
id
}
return
delLogininfo
(
query
)
}).
then
(()
=>
{
}).
then
(()
=>
{
this
.
getList
()
this
.
getList
()
this
.
$message
.
success
(
'删除成功'
)
this
.
$message
.
success
(
'删除成功'
)
...
@@ -291,14 +309,14 @@ export default {
...
@@ -291,14 +309,14 @@ export default {
}
}
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
.app-container
{
.app-container
{
padding
:
0
;
padding
:
0
;
font-size
:
18px
;
font-size
:
18px
;
.placeholder
{
.placeholder
{
height
:
14px
;
height
:
14px
;
background-color
:
#F4F4F4
;
background-color
:
#F4F4F4
;
margin-bottom
:
10px
margin-bottom
:
10px
}
}
}
}
</
style
>
</
style
>
src/views/monitor/operLog/index.vue
View file @
caebd246
...
@@ -98,7 +98,7 @@
...
@@ -98,7 +98,7 @@
<el-table-column
type=
"selection"
width=
"55"
align=
"center"
/>
<el-table-column
type=
"selection"
width=
"55"
align=
"center"
/>
<el-table-column
:show-overflow-tooltip=
"true"
label=
"日志编号"
width=
"100"
align=
"center"
prop=
"operId"
>
<el-table-column
:show-overflow-tooltip=
"true"
label=
"日志编号"
width=
"100"
align=
"center"
prop=
"operId"
>
<template
slot-scope=
"scope"
>
<template
slot-scope=
"scope"
>
{{
scope
.
row
.
oper
Id
||
'-'
}}
{{
scope
.
row
.
business
Id
||
'-'
}}
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
:show-overflow-tooltip=
"true"
label=
"系统模块"
align=
"center"
prop=
"systemMode"
>
<el-table-column
:show-overflow-tooltip=
"true"
label=
"系统模块"
align=
"center"
prop=
"systemMode"
>
...
@@ -200,9 +200,9 @@
...
@@ -200,9 +200,9 @@
<!-- </el-col>-->
<!-- </el-col>-->
</el-row>
</el-row>
</el-form>
</el-form>
<!-- <div slot="footer" class="dialog-footer">-->
<!-- <div slot="footer" class="dialog-footer">-->
<!-- <el-button @click="open = false">关 闭</el-button>-->
<!-- <el-button @click="open = false">关 闭</el-button>-->
<!-- </div>-->
<!-- </div>-->
</el-dialog>
</el-dialog>
</div>
</div>
</template>
</template>
...
@@ -277,22 +277,22 @@ export default {
...
@@ -277,22 +277,22 @@ export default {
// const query = Object.assign({}, this.queryParams)
// const query = Object.assign({}, this.queryParams)
// query.operTime = query.operTime ? this.$parseDate(new Date(query.operTime), 'YYYY-MM-DD HH:mm:ss') : ''
// query.operTime = query.operTime ? this.$parseDate(new Date(query.operTime), 'YYYY-MM-DD HH:mm:ss') : ''
list
(
this
.
addDateRange
(
this
.
queryParams
,
this
.
dateRange
)).
then
(
response
=>
{
list
(
this
.
addDateRange
(
this
.
queryParams
,
this
.
dateRange
)).
then
(
response
=>
{
this
.
list
=
response
.
rows
.
map
(
item
=>
{
this
.
list
=
response
.
rows
.
map
(
item
=>
{
const
title
=
item
.
title
const
title
=
item
.
title
if
(
title
)
{
if
(
title
)
{
const
temp
=
title
.
split
(
'-'
)
const
temp
=
title
.
split
(
'-'
)
const
systemMode
=
temp
.
filter
((
item
,
index
)
=>
{
return
index
<
temp
.
length
-
1
}).
join
(
'-'
)
const
systemMode
=
temp
.
filter
((
item
,
index
)
=>
{
return
index
<
temp
.
length
-
1
}).
join
(
'-'
)
item
.
systemMode
=
systemMode
item
.
systemMode
=
systemMode
item
.
optionName
=
temp
[
temp
.
length
-
1
]
item
.
optionName
=
temp
[
temp
.
length
-
1
]
}
else
{
}
else
{
item
.
systemMode
=
undefined
item
.
systemMode
=
undefined
item
.
optionName
=
undefined
item
.
optionName
=
undefined
}
}
return
item
return
item
})
})
this
.
total
=
response
.
total
this
.
total
=
response
.
total
this
.
loading
=
false
this
.
loading
=
false
}
}
)
)
},
},
// 操作日志状态字典翻译
// 操作日志状态字典翻译
...
@@ -316,7 +316,7 @@ export default {
...
@@ -316,7 +316,7 @@ export default {
},
},
// 多选框选中数据
// 多选框选中数据
handleSelectionChange
(
selection
)
{
handleSelectionChange
(
selection
)
{
this
.
ids
=
selection
.
map
(
item
=>
item
.
oper
Id
)
this
.
ids
=
selection
.
map
(
item
=>
item
.
business
Id
)
},
},
/** 详细按钮操作 */
/** 详细按钮操作 */
handleView
(
row
)
{
handleView
(
row
)
{
...
@@ -330,7 +330,14 @@ export default {
...
@@ -330,7 +330,14 @@ export default {
cancelButtonText
:
'取消'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
type
:
'warning'
}).
then
(()
=>
{
}).
then
(()
=>
{
return
delOperLog
(
this
.
ids
)
const
id
=
this
.
ids
.
join
(
','
)
// TODO: clear this log
console
.
log
(
`this.ids`
,
id
)
const
query
=
{
deleteIds
:
id
}
// const deleteIds = JSON.stringify(query)
return
delOperLog
(
query
)
}).
then
(()
=>
{
}).
then
(()
=>
{
this
.
getList
()
this
.
getList
()
this
.
$message
.
success
(
'删除成功'
)
this
.
$message
.
success
(
'删除成功'
)
...
@@ -385,14 +392,14 @@ export default {
...
@@ -385,14 +392,14 @@ export default {
}
}
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
.app-container-operlog
{
.app-container-operlog
{
padding
:
0
;
padding
:
0
;
font-size
:
18px
;
font-size
:
18px
;
.placeholder
{
.placeholder
{
height
:
14px
;
height
:
14px
;
background-color
:
#F4F4F4
;
background-color
:
#F4F4F4
;
margin-bottom
:
10px
margin-bottom
:
10px
}
}
}
}
</
style
>
</
style
>
src/views/system/dict/data.vue
View file @
caebd246
This diff is collapsed.
Click to expand it.
src/views/system/role/index.vue
View file @
caebd246
...
@@ -109,13 +109,13 @@
...
@@ -109,13 +109,13 @@
style=
"color: #49cec9"
style=
"color: #49cec9"
@
click=
"handleUpdate(scope.row)"
@
click=
"handleUpdate(scope.row)"
>
修改
</el-button>
>
修改
</el-button>
<
el-button
<
!--
<el-button-->
v-hasPermi=
"['sys:role:update']"
<!-- v-hasPermi="['sys:role:update']"-->
size=
"mini"
<!-- size="mini"-->
type=
"text"
<!-- type="text"-->
icon=
"el-icon-circle-check"
<!-- icon="el-icon-circle-check"-->
@
click=
"handleMenu(scope.row)"
<!-- @click="handleMenu(scope.row)"-->
>
数据权限
</el-button
>
<!-- >数据权限
</el-button>
--
>
<el-button
<el-button
size=
"mini"
size=
"mini"
type=
"text"
type=
"text"
...
@@ -674,28 +674,28 @@ export default {
...
@@ -674,28 +674,28 @@ export default {
}
}
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
.app-container
{
.app-container
{
font-size
:
18px
;
font-size
:
18px
;
padding
:
0
;
padding
:
0
;
.placeholder
{
height
:
1
.3vh
;
background-color
:
#F4F4F4
;
margin-bottom
:
10px
}
.table-drop
{
.placeholder
{
vertical-align
:
2px
;
height
:
1
.3vh
;
line-height
:
20px
;
background-color
:
#F4F4F4
;
margin-left
:
15
px
margin-bottom
:
10
px
}
}
.el-switch
{
.table-drop
{
margin-left
:
15px
;
vertical-align
:
2px
;
}
line-height
:
20px
;
margin-left
:
15px
}
}
.el-divider--vertical
{
height
:
12em
;
.el-switch
{
width
:
4
px
;
margin-left
:
15
px
;
}
}
}
.el-divider--vertical
{
height
:
12em
;
width
:
4px
;
}
</
style
>
</
style
>
src/views/system/user/index.vue
View file @
caebd246
...
@@ -43,14 +43,14 @@
...
@@ -43,14 +43,14 @@
<el-button
type=
"primary"
style=
"padding: 8px 7px;"
icon=
"el-icon-refresh"
size=
"small"
@
click=
"resetQuery"
>
重置
</el-button>
<el-button
type=
"primary"
style=
"padding: 8px 7px;"
icon=
"el-icon-refresh"
size=
"small"
@
click=
"resetQuery"
>
重置
</el-button>
</el-form-item>
</el-form-item>
<el-form-item
style=
"float: right"
>
<el-form-item
style=
"float: right"
>
<!--
<el-button-->
<!--
<el-button-->
<!-- v-hasPermi="['sys:user:add']"-->
<!-- v-hasPermi="['sys:user:add']"-->
<!-- style="padding: 8px 7px;"-->
<!-- style="padding: 8px 7px;"-->
<!-- type="primary"-->
<!-- type="primary"-->
<!-- size="small"-->
<!-- size="small"-->
<!-- icon="el-icon-plus"-->
<!-- icon="el-icon-plus"-->
<!-- @click="handleFormAdd"-->
<!-- @click="handleFormAdd"-->
<!-- >表单页新增模板
</el-button>
-->
<!-- >表单页新增模板
</el-button>
-->
<el-button
<el-button
v-hasPermi=
"['sys:user:add']"
v-hasPermi=
"['sys:user:add']"
style=
"padding: 8px 7px;"
style=
"padding: 8px 7px;"
...
@@ -129,7 +129,7 @@
...
@@ -129,7 +129,7 @@
{{
scope
.
row
.
username
||
'-'
}}
{{
scope
.
row
.
username
||
'-'
}}
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
label=
"用户
类型
"
prop=
"userType"
:show-overflow-tooltip=
"true"
>
<el-table-column
label=
"用户
名称
"
prop=
"userType"
:show-overflow-tooltip=
"true"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
name
||
'-'
}}
{{
scope
.
row
.
name
||
'-'
}}
</
template
>
</
template
>
...
@@ -248,8 +248,8 @@
...
@@ -248,8 +248,8 @@
</el-row>
</el-row>
<el-row>
<el-row>
<el-col
:span=
"12"
>
<el-col
:span=
"12"
>
<el-form-item
label=
"用户
类型
"
prop=
"name"
>
<el-form-item
label=
"用户
名称
"
prop=
"name"
>
<el-input
v-model
.
trim=
"form.name"
placeholder=
"请输入用户
类型
"
/>
<el-input
v-model
.
trim=
"form.name"
placeholder=
"请输入用户
名称
"
/>
</el-form-item>
</el-form-item>
</el-col>
</el-col>
<el-col
:span=
"12"
>
<el-col
:span=
"12"
>
...
@@ -273,11 +273,10 @@
...
@@ -273,11 +273,10 @@
</el-row>
</el-row>
<el-row>
<el-row>
<el-col
:span=
"24"
>
<el-col
:span=
"24"
>
<el-form-item
label=
"
岗位
"
prop=
"postId"
>
<el-form-item
label=
"
部门
"
prop=
"postId"
>
<treeSelect
<treeSelect
v-model=
"form.
pos
tId"
v-model=
"form.
dep
tId"
:disable-branch-nodes=
"true"
:disable-branch-nodes=
"true"
multiple
:options=
"deptChildren"
:options=
"deptChildren"
:show-count=
"true"
:show-count=
"true"
placeholder=
"请选择归属部门"
placeholder=
"请选择归属部门"
...
@@ -286,6 +285,20 @@
...
@@ -286,6 +285,20 @@
</el-form-item>
</el-form-item>
</el-col>
</el-col>
</el-row>
</el-row>
<el-row>
<el-col
:span=
"24"
>
<el-form-item
label=
"角色"
prop=
"postId"
>
<el-select
v-model=
"form.roleList"
multiple
placeholder=
"请选择"
style=
"width: 100%"
@
change=
"roleChange"
>
<el-option
v-for=
"item in options"
:key=
"item.businessId"
:label=
"item.roleName"
:value=
"item.businessId"
/>
</el-select>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-row>
<el-col
:span=
"24"
>
<el-col
:span=
"24"
>
<el-form-item
label=
"备注"
>
<el-form-item
label=
"备注"
>
...
@@ -387,6 +400,7 @@ import { getToken } from '@/utils/auth'
...
@@ -387,6 +400,7 @@ import { getToken } from '@/utils/auth'
import
{
getChildrenDept
,
treeselect
}
from
'@/api/system/dept'
import
{
getChildrenDept
,
treeselect
}
from
'@/api/system/dept'
import
TreeSelect
from
'@riophae/vue-treeselect'
import
TreeSelect
from
'@riophae/vue-treeselect'
import
'@riophae/vue-treeselect/dist/vue-treeselect.css'
import
'@riophae/vue-treeselect/dist/vue-treeselect.css'
import
{
getlistRole
,
listRole
}
from
'@/api/system/role'
export
default
{
export
default
{
name
:
'User'
,
name
:
'User'
,
...
@@ -456,6 +470,7 @@ export default {
...
@@ -456,6 +470,7 @@ export default {
deptOptionsTree
:
undefined
,
deptOptionsTree
:
undefined
,
currentNode
:
undefined
,
currentNode
:
undefined
,
currentNodeKey
:
false
,
currentNodeKey
:
false
,
options
:
[],
// 是否显示弹出层
// 是否显示弹出层
open
:
false
,
open
:
false
,
// 部门名称
// 部门名称
...
@@ -615,9 +630,10 @@ export default {
...
@@ -615,9 +630,10 @@ export default {
}
}
this
.
getList
()
this
.
getList
()
this
.
getTreeSelect
()
this
.
getTreeSelect
()
this
.
getConfigKey
(
'sys.user.initPassword'
).
then
(
response
=>
{
this
.
getRole
()
this
.
initPassword
=
response
.
msg
// this.getConfigKey('sys.user.initPassword').then(response => {
})
// this.initPassword = response.msg
// })
},
},
methods
:
{
methods
:
{
changeValue
()
{
changeValue
()
{
...
@@ -627,12 +643,17 @@ export default {
...
@@ -627,12 +643,17 @@ export default {
getList
()
{
getList
()
{
this
.
loading
=
true
this
.
loading
=
true
listUser
(
this
.
queryParams
).
then
(
response
=>
{
listUser
(
this
.
queryParams
).
then
(
response
=>
{
this
.
userList
=
response
.
rows
this
.
userList
=
response
.
rows
this
.
total
=
response
.
total
this
.
total
=
response
.
total
this
.
loading
=
false
this
.
loading
=
false
}
}
)
)
},
},
roleChange
(
e
)
{
// TODO: clear this log
console
.
log
(
`e`
,
e
)
this
.
$forceUpdate
()
},
/** 查询部门下拉树结构 */
/** 查询部门下拉树结构 */
getTreeSelect
()
{
getTreeSelect
()
{
treeselect
().
then
(
response
=>
{
treeselect
().
then
(
response
=>
{
...
@@ -648,11 +669,18 @@ export default {
...
@@ -648,11 +669,18 @@ export default {
},
},
/** 查询子部门 */
/** 查询子部门 */
getChildrenDept
(
userId
)
{
getChildrenDept
(
userId
)
{
getChildrenDept
(
userId
).
then
(
response
=>
{
treeselect
(
).
then
(
response
=>
{
this
.
deptChildren
=
response
.
data
.
postChildren
this
.
deptChildren
=
response
.
data
this
.
form
.
postId
=
response
.
data
.
checkedKeys
//
this.form.postId = response.data.checkedKeys
})
})
},
},
getRole
()
{
getlistRole
().
then
(
response
=>
{
this
.
options
=
response
.
data
}
)
},
// 筛选节点
// 筛选节点
filterNode
(
value
,
data
)
{
filterNode
(
value
,
data
)
{
if
(
!
value
)
return
true
if
(
!
value
)
return
true
...
@@ -754,6 +782,15 @@ export default {
...
@@ -754,6 +782,15 @@ export default {
getUser
(
userId
).
then
(
response
=>
{
getUser
(
userId
).
then
(
response
=>
{
this
.
open
=
true
this
.
open
=
true
this
.
form
=
response
.
data
this
.
form
=
response
.
data
const
data
=
response
.
data
.
roleIds
.
split
(
','
)
// TODO: clear this log
console
.
log
(
`data`
,
data
)
this
.
form
.
roleList
=
[]
data
.
forEach
(
item
=>
{
const
id
=
Number
(
item
)
this
.
form
.
roleList
.
push
(
id
)
})
// this.form.postId = response.data.deptId
this
.
title
=
'修改'
this
.
title
=
'修改'
})
})
this
.
getChildrenDept
(
userId
)
this
.
getChildrenDept
(
userId
)
...
@@ -954,31 +991,31 @@ export default {
...
@@ -954,31 +991,31 @@ export default {
}
}
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
.user-manage
{
.user-manage
{
font-size
:
18px
;
font-size
:
18px
;
.placeholder
{
.placeholder
{
height
:
14px
;
height
:
14px
;
background-color
:
#F4F4F4
background-color
:
#F4F4F4
}
}
.table-drop
{
margin-left
:
15px
;
font-size
:
16px
;
font-weight
:
bold
;
color
:
#46BCF3
;
}
}
}
.table-drop
{
margin-left
:
15px
;
font-size
:
16px
;
font-weight
:
bold
;
color
:
#46BCF3
;
}
</
style
>
</
style
>
<
style
lang=
"scss"
>
<
style
lang=
"scss"
>
.user-manage
{
.user-manage
{
.formClass
{
.formClass
{
}
}
.paddingFixed
{
.paddingFixed
{
.el-dialog__body
{
.el-dialog__body
{
padding-bottom
:
17px
;
padding-bottom
:
17px
;
}
}
.el-form-item__label-wrap
{
margin-left
:
0
!
important
;
}
}
}
}
.el-form-item__label-wrap
{
margin-left
:
0
!
important
;
}
}
</
style
>
</
style
>
vue.config.js
View file @
caebd246
...
@@ -79,9 +79,10 @@ module.exports = {
...
@@ -79,9 +79,10 @@ module.exports = {
// }
// }
// },
// },
[
process
.
env
.
VUE_APP_BASE_API
]:
{
[
process
.
env
.
VUE_APP_BASE_API
]:
{
// target: `http://192.168.1.
17:10010/internal
`,
// target: `http://192.168.1.
29:8088/
`,
// target: `http://10.5.87.231:10010/internal`,
// target: `http://10.5.87.231:10010/internal`,
target
:
`http://117.122.212.91:32012/`
,
// target: `http://117.122.212.91:32012/`,
target
:
`http://192.144.239.97:20070/`
,
changeOrigin
:
true
,
changeOrigin
:
true
,
pathRewrite
:
{
pathRewrite
:
{
[
'^'
+
process
.
env
.
VUE_APP_BASE_API
]:
''
[
'^'
+
process
.
env
.
VUE_APP_BASE_API
]:
''
...
@@ -150,7 +151,7 @@ module.exports = {
...
@@ -150,7 +151,7 @@ module.exports = {
.
plugin
(
'ScriptExtHtmlWebpackPlugin'
)
.
plugin
(
'ScriptExtHtmlWebpackPlugin'
)
.
after
(
'html'
)
.
after
(
'html'
)
.
use
(
'script-ext-html-webpack-plugin'
,
[{
.
use
(
'script-ext-html-webpack-plugin'
,
[{
// `runtime` must same as runtimeChunk name. default is `runtime`
// `runtime` must same as runtimeChunk name. default is `runtime`
inline
:
/runtime
\.
.*
\.
js$/
inline
:
/runtime
\.
.*
\.
js$/
}])
}])
.
end
()
.
end
()
...
...
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