Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
A
admin-base
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
new-sing
admin-base
Commits
082a1314
Commit
082a1314
authored
Sep 13, 2018
by
王
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
log
parent
41a1b884
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
135 additions
and
5 deletions
+135
-5
index.js
config/index.js
+2
-2
adminLog.vue
src/components/system/adminLog.vue
+115
-0
index.vue
src/components/user/index.vue
+2
-2
api.js
src/service/api.js
+5
-1
menuList.js
src/util/menuList.js
+11
-0
No files found.
config/index.js
View file @
082a1314
...
@@ -12,8 +12,8 @@ module.exports = {
...
@@ -12,8 +12,8 @@ module.exports = {
//本地代理设置
//本地代理设置
proxyTable
:
{
proxyTable
:
{
'/api'
:
{
'/api'
:
{
//
target: 'http://local.base-api.sing.com', // 接口的域名
target
:
'http://local.base-api.sing.com'
,
// 接口的域名
target
:
'http://wechat.test.singsingenglish.com/'
,
//
target: 'http://wechat.test.singsingenglish.com/',
changeOrigin
:
true
,
// 如果接口跨域,需要进行这个参数配置
changeOrigin
:
true
,
// 如果接口跨域,需要进行这个参数配置
}
}
},
},
...
...
src/components/system/adminLog.vue
0 → 100644
View file @
082a1314
<
template
>
<div
class=
"log"
>
<el-form
ref=
"searchFrom"
:model=
"searchFrom"
label-width=
"80px"
>
<el-row>
<el-col
:span=
"4"
>
<el-form-item
label=
"用户ID"
>
<el-input
v-model=
"searchFrom.admin_id"
></el-input>
</el-form-item>
</el-col>
<el-col
:span=
"4"
>
<el-form-item
label=
"地址"
>
<el-input
v-model=
"searchFrom.url"
></el-input>
</el-form-item>
</el-col>
<el-col
:span=
"4"
>
<el-form-item
label=
"功能名"
>
<el-input
v-model=
"searchFrom.desc"
></el-input>
</el-form-item>
</el-col>
<el-col
:span=
"4"
>
<el-form-item>
<el-button
type=
"primary"
plain
@
click=
"getList"
>
搜索
</el-button>
</el-form-item>
</el-col>
</el-row>
</el-form>
<el-table
:data=
"list"
style=
"width: 100%"
>
<el-table-column
type=
"expand"
>
<template
slot-scope=
"props"
>
<el-form
label-position=
"left"
class=
"demo-table-expand"
>
<el-form-item
label=
"请求方法"
>
<span>
{{
props
.
row
.
method
}}
</span>
</el-form-item>
<el-form-item
label=
"请求链接"
>
<span>
{{
props
.
row
.
url
}}
</span>
</el-form-item>
<el-form-item
label=
"参数"
>
<span>
{{
props
.
row
.
params
}}
</span>
</el-form-item>
<el-form-item
label=
"功能名"
>
<span>
{{
props
.
row
.
desc
}}
</span>
</el-form-item>
</el-form>
</
template
>
</el-table-column>
<el-table-column
label=
"用户名"
prop=
"user_name"
>
</el-table-column>
<el-table-column
label=
"用户ID"
prop=
"admin_id"
>
</el-table-column>
<el-table-column
label=
"用户详情"
prop=
"user_desc"
>
</el-table-column>
</el-table-column>
<el-table-column
prop=
"created_at"
label=
"创建时间"
>
</el-table-column>
</el-table>
<page
:total=
"total"
v-model=
"nowPage"
/>
</div>
</template>
<
script
>
import
{
getAdminLogLisApi
}
from
"../../service/api"
;
import
page
from
'../framework/page'
export
default
{
name
:
"sysConfig"
,
components
:{
page
},
data
()
{
return
{
list
:
[],
total
:
0
,
nowPage
:
1
,
searchFrom
:
{
admin_id
:
''
,
url
:
''
,
desc
:
''
}
}
},
mounted
(){
this
.
getList
()
},
methods
:
{
getList
(){
getAdminLogLisApi
(
this
.
searchFrom
).
then
(
res
=>
{
this
.
list
=
res
.
list
this
.
total
=
res
.
total
})
}
}
}
</
script
>
<
style
scoped
lang=
"less"
>
@import "../../util/public";
.log {
padding: 20px 0;
}
.add-btn {
margin: 10px 0;
}
.top {
margin-bottom:10px;
}
</
style
>
src/components/user/index.vue
View file @
082a1314
...
@@ -19,7 +19,7 @@
...
@@ -19,7 +19,7 @@
</el-col>
</el-col>
<el-col
:span=
"4"
>
<el-col
:span=
"4"
>
<el-form-item>
<el-form-item>
<el-button
type=
"primary"
plain
>
搜索
</el-button>
<el-button
type=
"primary"
plain
@
click=
"getUser"
>
搜索
</el-button>
</el-form-item>
</el-form-item>
</el-col>
</el-col>
</el-row>
</el-row>
...
@@ -100,7 +100,7 @@
...
@@ -100,7 +100,7 @@
},
},
userList
:[],
userList
:[],
total
:
0
,
total
:
0
,
nowPage
:
0
,
nowPage
:
1
,
showDetail
:
false
,
showDetail
:
false
,
showId
:
''
,
showId
:
''
,
dialogObj
:{
dialogObj
:{
...
...
src/service/api.js
View file @
082a1314
...
@@ -472,5 +472,9 @@ const addRelatedTeacherUrl = `${_baseUrl}api/admin/student/bind/`;
...
@@ -472,5 +472,9 @@ const addRelatedTeacherUrl = `${_baseUrl}api/admin/student/bind/`;
export
const
addRelatedTeacherApi
=
function
(
id
,
json
)
{
export
const
addRelatedTeacherApi
=
function
(
id
,
json
)
{
return
Vue
.
prototype
.
$put
(
`
${
addRelatedTeacherUrl
}
/
${
id
}
`
,
json
)
return
Vue
.
prototype
.
$put
(
`
${
addRelatedTeacherUrl
}
/
${
id
}
`
,
json
)
};
};
// 操作日志
const
getAdminLogListUrl
=
`
${
_baseUrl
}
api/admin/user/log`
;
export
const
getAdminLogLisApi
=
function
(
json
)
{
return
Vue
.
prototype
.
$fetch
(
`
${
getAdminLogListUrl
}
`
,
json
)
};
src/util/menuList.js
View file @
082a1314
...
@@ -293,6 +293,17 @@ export default [
...
@@ -293,6 +293,17 @@ export default [
name
:
'sysConfig'
,
name
:
'sysConfig'
,
component
:
e
=>
require
([
'@/components/system/sysConfig'
],
e
),
component
:
e
=>
require
([
'@/components/system/sysConfig'
],
e
),
}
}
},
{
value
:
'管理员操作日志'
,
routerName
:
'adminLog'
,
path
:
'/adminLog'
,
cover
:
'8-5'
,
router
:{
path
:
'/adminLog'
,
name
:
'adminLog'
,
component
:
e
=>
require
([
'@/components/system/adminLog'
],
e
),
}
}
}
]
]
}
}
...
...
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