vue2-client 1.4.13 → 1.4.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +9 -0
- package/package.json +1 -1
- package/src/assets/img/querySlotDemo.svg +16 -0
- package/src/base-client/components/common/CreateQuery/CreateQuery.vue +595 -591
- package/src/layouts/SinglePageView.vue +86 -78
- package/src/pages/system/monitor/loginInfor/index.vue +36 -0
- package/src/pages/system/monitor/operLog/index.vue +36 -0
- package/src/router/async/router.map.js +65 -61
|
@@ -1,78 +1,86 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<page-toggle-transition :disabled="animate.disabled" :animate="animate.name" :direction="animate.direction">
|
|
3
|
-
<template v-if="login">
|
|
4
|
-
<iframe
|
|
5
|
-
ref="singlepage"
|
|
6
|
-
:src="
|
|
7
|
-
:name="this.fullPath"
|
|
8
|
-
class="single-page-iframe"
|
|
9
|
-
@load="load">
|
|
10
|
-
</iframe>
|
|
11
|
-
</template>
|
|
12
|
-
</page-toggle-transition>
|
|
13
|
-
</template>
|
|
14
|
-
|
|
15
|
-
<script>
|
|
16
|
-
import PageToggleTransition from '@vue2-client/components/transition/PageToggleTransition'
|
|
17
|
-
import { ACCESS_TOKEN } from '@vue2-client/store/mutation-types'
|
|
18
|
-
import { mapState, mapMutations } from 'vuex'
|
|
19
|
-
|
|
20
|
-
export default {
|
|
21
|
-
name: 'SinglePageView',
|
|
22
|
-
components: { PageToggleTransition },
|
|
23
|
-
props: {
|
|
24
|
-
singlePageUrl: {
|
|
25
|
-
type: String,
|
|
26
|
-
default: ''
|
|
27
|
-
},
|
|
28
|
-
fullPath: {
|
|
29
|
-
type: String,
|
|
30
|
-
default: ''
|
|
31
|
-
}
|
|
32
|
-
},
|
|
33
|
-
data () {
|
|
34
|
-
return {
|
|
35
|
-
iframe: null
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
...mapState('
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
}
|
|
78
|
-
</
|
|
1
|
+
<template>
|
|
2
|
+
<page-toggle-transition :disabled="animate.disabled" :animate="animate.name" :direction="animate.direction">
|
|
3
|
+
<template v-if="login">
|
|
4
|
+
<iframe
|
|
5
|
+
ref="singlepage"
|
|
6
|
+
:src="url"
|
|
7
|
+
:name="this.fullPath"
|
|
8
|
+
class="single-page-iframe"
|
|
9
|
+
@load="load">
|
|
10
|
+
</iframe>
|
|
11
|
+
</template>
|
|
12
|
+
</page-toggle-transition>
|
|
13
|
+
</template>
|
|
14
|
+
|
|
15
|
+
<script>
|
|
16
|
+
import PageToggleTransition from '@vue2-client/components/transition/PageToggleTransition'
|
|
17
|
+
import { ACCESS_TOKEN } from '@vue2-client/store/mutation-types'
|
|
18
|
+
import { mapState, mapMutations } from 'vuex'
|
|
19
|
+
|
|
20
|
+
export default {
|
|
21
|
+
name: 'SinglePageView',
|
|
22
|
+
components: { PageToggleTransition },
|
|
23
|
+
props: {
|
|
24
|
+
singlePageUrl: {
|
|
25
|
+
type: String,
|
|
26
|
+
default: ''
|
|
27
|
+
},
|
|
28
|
+
fullPath: {
|
|
29
|
+
type: String,
|
|
30
|
+
default: ''
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
data () {
|
|
34
|
+
return {
|
|
35
|
+
iframe: null,
|
|
36
|
+
url: ''
|
|
37
|
+
}
|
|
38
|
+
},
|
|
39
|
+
computed: {
|
|
40
|
+
...mapState('setting', ['animate', 'iframeSrc']),
|
|
41
|
+
...mapState('account', ['login'])
|
|
42
|
+
},
|
|
43
|
+
created () {
|
|
44
|
+
if (this.singlePageUrl.indexOf('http') !== -1) {
|
|
45
|
+
this.url = this.singlePageUrl
|
|
46
|
+
} else {
|
|
47
|
+
this.url = this.iframeSrc
|
|
48
|
+
}
|
|
49
|
+
},
|
|
50
|
+
mounted () {
|
|
51
|
+
if (!this.login) {
|
|
52
|
+
this.setLogin(JSON.parse(sessionStorage.getItem(process.env.VUE_APP_LOGIN_KEY)))
|
|
53
|
+
}
|
|
54
|
+
this.iframe = this.$refs.singlepage.contentWindow
|
|
55
|
+
this.path = this.$route.path
|
|
56
|
+
},
|
|
57
|
+
methods: {
|
|
58
|
+
...mapMutations('account', ['setLogin']),
|
|
59
|
+
load () {
|
|
60
|
+
const appdata = {
|
|
61
|
+
singleValues: this.$appdata.getSingleValues(),
|
|
62
|
+
params: this.$appdata.getParams()
|
|
63
|
+
}
|
|
64
|
+
const data = {
|
|
65
|
+
token: localStorage.getItem(ACCESS_TOKEN),
|
|
66
|
+
login: this.login,
|
|
67
|
+
appdata: appdata,
|
|
68
|
+
page: this.singlePageUrl
|
|
69
|
+
}
|
|
70
|
+
console.log('发送参数', data)
|
|
71
|
+
if (this.iframe) {
|
|
72
|
+
this.iframe.postMessage(data, '*')
|
|
73
|
+
}
|
|
74
|
+
this.$emit('load', this.fullPath)
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
</script>
|
|
79
|
+
|
|
80
|
+
<style lang="less">
|
|
81
|
+
.single-page-iframe {
|
|
82
|
+
width: 100%;
|
|
83
|
+
height: calc(100vh - 117px);
|
|
84
|
+
border: none;
|
|
85
|
+
}
|
|
86
|
+
</style>
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<a-card :bordered="false">
|
|
3
|
+
<x-form-table
|
|
4
|
+
title="登录日志"
|
|
5
|
+
:queryParamsName="queryParamsName"
|
|
6
|
+
@action="toDetail">
|
|
7
|
+
</x-form-table>
|
|
8
|
+
</a-card>
|
|
9
|
+
</template>
|
|
10
|
+
|
|
11
|
+
<script>
|
|
12
|
+
import XFormTable from '@vue2-client/base-client/components/common/XFormTable/XFormTable'
|
|
13
|
+
|
|
14
|
+
export default {
|
|
15
|
+
name: 'loginInfor',
|
|
16
|
+
components: {
|
|
17
|
+
XFormTable
|
|
18
|
+
},
|
|
19
|
+
data () {
|
|
20
|
+
return {
|
|
21
|
+
// 选中的编号
|
|
22
|
+
selectNo: undefined,
|
|
23
|
+
// 查询配置文件名
|
|
24
|
+
queryParamsName: 'loginInforQueryParams',
|
|
25
|
+
// 是否显示详情抽屉
|
|
26
|
+
detailVisible: false
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
methods: {
|
|
30
|
+
toDetail (record, id) {
|
|
31
|
+
this.selectNo = id + ''
|
|
32
|
+
this.detailVisible = true
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
</script>
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<a-card :bordered="false">
|
|
3
|
+
<x-form-table
|
|
4
|
+
title="操作日志"
|
|
5
|
+
:queryParamsName="queryParamsName"
|
|
6
|
+
@action="toDetail">
|
|
7
|
+
</x-form-table>
|
|
8
|
+
</a-card>
|
|
9
|
+
</template>
|
|
10
|
+
|
|
11
|
+
<script>
|
|
12
|
+
import XFormTable from '@vue2-client/base-client/components/common/XFormTable/XFormTable'
|
|
13
|
+
|
|
14
|
+
export default {
|
|
15
|
+
name: 'operLog',
|
|
16
|
+
components: {
|
|
17
|
+
XFormTable
|
|
18
|
+
},
|
|
19
|
+
data () {
|
|
20
|
+
return {
|
|
21
|
+
// 选中的编号
|
|
22
|
+
selectNo: undefined,
|
|
23
|
+
// 查询配置文件名
|
|
24
|
+
queryParamsName: 'operLogQueryParams',
|
|
25
|
+
// 是否显示详情抽屉
|
|
26
|
+
detailVisible: false
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
methods: {
|
|
30
|
+
toDetail (record, id) {
|
|
31
|
+
this.selectNo = id + ''
|
|
32
|
+
this.detailVisible = true
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
</script>
|
|
@@ -1,61 +1,65 @@
|
|
|
1
|
-
// 视图组件
|
|
2
|
-
const view = {
|
|
3
|
-
tabs: () => import('@vue2-client/layouts/tabs'),
|
|
4
|
-
blank: () => import('@vue2-client/layouts/BlankView'),
|
|
5
|
-
page: () => import('@vue2-client/layouts/PageView')
|
|
6
|
-
}
|
|
7
|
-
// 动态路由对象定义
|
|
8
|
-
const routerResource = {}
|
|
9
|
-
// --------------------------------------基本视图组件--------------------------------------
|
|
10
|
-
// 空白视图
|
|
11
|
-
routerResource.blank = view.blank
|
|
12
|
-
// 单页面视图
|
|
13
|
-
routerResource.singlePage = view.blank
|
|
14
|
-
|
|
15
|
-
// --------------------------------------仪表盘--------------------------------------
|
|
16
|
-
routerResource.dashboard = view.blank
|
|
17
|
-
// 工作台
|
|
18
|
-
routerResource.workplace = () => import('@vue2-client/pages/dashboard/workplace')
|
|
19
|
-
// --------------------------------------系统配置--------------------------------------
|
|
20
|
-
routerResource.system = view.blank
|
|
21
|
-
// 字典管理
|
|
22
|
-
routerResource.dictionaryManage = () => import(/* webpackChunkName: "dictionary" */ '@vue2-client/pages/system/dictionary')
|
|
23
|
-
// 查询配置管理
|
|
24
|
-
routerResource.queryParamsManage = () => import(/* webpackChunkName: "queryParams" */ '@vue2-client/pages/system/queryParams')
|
|
25
|
-
// 文件管理
|
|
26
|
-
routerResource.fileManager = () => import('@vue2-client/pages/system/file')
|
|
27
|
-
//
|
|
28
|
-
routerResource.
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
path: '/',
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
1
|
+
// 视图组件
|
|
2
|
+
const view = {
|
|
3
|
+
tabs: () => import('@vue2-client/layouts/tabs'),
|
|
4
|
+
blank: () => import('@vue2-client/layouts/BlankView'),
|
|
5
|
+
page: () => import('@vue2-client/layouts/PageView')
|
|
6
|
+
}
|
|
7
|
+
// 动态路由对象定义
|
|
8
|
+
const routerResource = {}
|
|
9
|
+
// --------------------------------------基本视图组件--------------------------------------
|
|
10
|
+
// 空白视图
|
|
11
|
+
routerResource.blank = view.blank
|
|
12
|
+
// 单页面视图
|
|
13
|
+
routerResource.singlePage = view.blank
|
|
14
|
+
|
|
15
|
+
// --------------------------------------仪表盘--------------------------------------
|
|
16
|
+
routerResource.dashboard = view.blank
|
|
17
|
+
// 工作台
|
|
18
|
+
routerResource.workplace = () => import('@vue2-client/pages/dashboard/workplace')
|
|
19
|
+
// --------------------------------------系统配置--------------------------------------
|
|
20
|
+
routerResource.system = view.blank
|
|
21
|
+
// 字典管理
|
|
22
|
+
routerResource.dictionaryManage = () => import(/* webpackChunkName: "dictionary" */ '@vue2-client/pages/system/dictionary')
|
|
23
|
+
// 查询配置管理
|
|
24
|
+
routerResource.queryParamsManage = () => import(/* webpackChunkName: "queryParams" */ '@vue2-client/pages/system/queryParams')
|
|
25
|
+
// 文件管理
|
|
26
|
+
routerResource.fileManager = () => import('@vue2-client/pages/system/file')
|
|
27
|
+
// 登录日志
|
|
28
|
+
routerResource.loginInfor = () => import('@vue2-client/pages/system/monitor/loginInfor')
|
|
29
|
+
// 操作日志
|
|
30
|
+
routerResource.operLog = () => import('@vue2-client/pages/system/monitor/operLog')
|
|
31
|
+
// 系统问题反馈工单
|
|
32
|
+
routerResource.submitTicket = () => import(/* webpackChunkName: "submitTicket" */ '@vue2-client/pages/system/ticket')
|
|
33
|
+
|
|
34
|
+
// 基础路由组件注册
|
|
35
|
+
const routerMap = {
|
|
36
|
+
login: {
|
|
37
|
+
authority: '*',
|
|
38
|
+
path: '/login',
|
|
39
|
+
component: () => import('@vue2-client/pages/login')
|
|
40
|
+
},
|
|
41
|
+
root: {
|
|
42
|
+
path: '/',
|
|
43
|
+
name: '首页',
|
|
44
|
+
redirect: '/login',
|
|
45
|
+
component: view.tabs
|
|
46
|
+
},
|
|
47
|
+
exp403: {
|
|
48
|
+
authority: '*',
|
|
49
|
+
name: 'exp403',
|
|
50
|
+
path: '403',
|
|
51
|
+
component: () => import('@vue2-client/pages/exception/403')
|
|
52
|
+
},
|
|
53
|
+
exp404: {
|
|
54
|
+
name: 'exp404',
|
|
55
|
+
path: '404',
|
|
56
|
+
component: () => import('@vue2-client/pages/exception/404')
|
|
57
|
+
},
|
|
58
|
+
exp500: {
|
|
59
|
+
name: 'exp500',
|
|
60
|
+
path: '500',
|
|
61
|
+
component: () => import('@vue2-client/pages/exception/500')
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
Object.assign(routerMap, routerResource)
|
|
65
|
+
export default routerMap
|