sasp-admin 0.2.57
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/index.js +227 -0
- package/package.json +19 -0
- package/router.js +83 -0
- package/src/assets/font/iconfont.css +1346 -0
- package/src/assets/font/iconfont.eot +0 -0
- package/src/assets/font/iconfont.js +1 -0
- package/src/assets/font/iconfont.svg +827 -0
- package/src/assets/font/iconfont.ttf +0 -0
- package/src/assets/font/iconfont.woff +0 -0
- package/src/assets/images/loading-bar.gif +0 -0
- package/src/assets/js/adminInstall.js +36 -0
- package/src/assets/js/api/apiAdmin.js +613 -0
- package/src/assets/js/global/dataGlobal.js +260 -0
- package/src/assets/js/global/logGlobal.js +22 -0
- package/src/assets/js/global/paramGlobal.js +67 -0
- package/src/assets/js/global/resGlobal.js +91 -0
- package/src/assets/js/global/userGlobal.js +283 -0
- package/src/components/complexViewRendering.vue +601 -0
- package/src/components/ifmLink.vue +71 -0
- package/src/components/public/data/plDataCascader.vue +85 -0
- package/src/components/public/data/plDataRadio.vue +73 -0
- package/src/components/public/data/plDataRadioGroup.vue +70 -0
- package/src/components/public/data/plDataSelect.vue +856 -0
- package/src/components/public/data/plDatePicker.vue +159 -0
- package/src/components/public/org/bg.png +0 -0
- package/src/components/public/org/sysOrgPosUserSelect.vue +1237 -0
- package/src/components/public/org/sysOrgPosUserSelectDark.vue +1402 -0
- package/src/components/public/org/sysOrgPosUserSelectNew.vue +1527 -0
- package/src/components/public/upload/images/compress.png +0 -0
- package/src/components/public/upload/images/emipty.png +0 -0
- package/src/components/public/upload/images/excel.png +0 -0
- package/src/components/public/upload/images/file.png +0 -0
- package/src/components/public/upload/images/pdf.png +0 -0
- package/src/components/public/upload/images/powerpoint.png +0 -0
- package/src/components/public/upload/images/project.png +0 -0
- package/src/components/public/upload/images/sound.png +0 -0
- package/src/components/public/upload/images/txt.png +0 -0
- package/src/components/public/upload/images/video.png +0 -0
- package/src/components/public/upload/images/visio.png +0 -0
- package/src/components/public/upload/images/word.png +0 -0
- package/src/components/public/upload/plImage.vue +287 -0
- package/src/components/public/upload/plImgUpload.vue +137 -0
- package/src/components/public/upload/plUpload.vue +1124 -0
- package/src/components/public/upload/uploadImg.js +8 -0
- package/src/main.js +0 -0
- package/src/views/VueMenuView.vue +143 -0
- package/src/views/cloudMenuView.vue +125 -0
- package/src/views/complex/config/complex.vue +501 -0
- package/src/views/complex/config/complexSetting.vue +1250 -0
- package/src/views/complex/rendering/complexShow.vue +16 -0
- package/src/views/data/dataManage.vue +560 -0
- package/src/views/data/sysData.vue +292 -0
- package/src/views/event/eventManager/vueEventDiy.vue +1184 -0
- package/src/views/event/eventManager/vueEventMain.vue +108 -0
- package/src/views/event/eventManager/vueEventSys.vue +296 -0
- package/src/views/event/js/apiEvent.js +22 -0
- package/src/views/fileLog/fileDownloadLog.vue +437 -0
- package/src/views/initData/initData.vue +4316 -0
- package/src/views/log/dblog/logdbDevelop.vue +306 -0
- package/src/views/log/dblog/logdbEnt.vue +331 -0
- package/src/views/log/dblog/logdbGov.vue +395 -0
- package/src/views/log/error/logError.vue +553 -0
- package/src/views/log/loginlog/logManageDevOrSup.vue +357 -0
- package/src/views/log/loginlog/logManageEnt.vue +343 -0
- package/src/views/log/loginlog/logManageGov.vue +328 -0
- package/src/views/log/sms/logSms.vue +308 -0
- package/src/views/menu/component/menuManageComponent.vue +2402 -0
- package/src/views/menu/component/menuModule.vue +449 -0
- package/src/views/menu/menuLocal.vue +223 -0
- package/src/views/menu/menuManage.vue +1135 -0
- package/src/views/menu/tenantMenuManage.vue +1132 -0
- package/src/views/menuRouter/cview/cviewShow.vue +18 -0
- package/src/views/menuRouter/cviewMenuRouter.vue +183 -0
- package/src/views/menuRouter/menuView.vue +132 -0
- package/src/views/menuRouter/urlMenuRouter.vue +160 -0
- package/src/views/org/entOrgTree.vue +1050 -0
- package/src/views/org/ownerMenu/ownerMenuTree.vue +269 -0
- package/src/views/org/safeValidate/safeValidate.vue +469 -0
- package/src/views/org/sysEntOrgUserDetail.vue +3390 -0
- package/src/views/org/sysOrgDimension.vue +832 -0
- package/src/views/org/sysOrgPosUserDetail.vue +1648 -0
- package/src/views/org/sysOrgPosUserTree.vue +1101 -0
- package/src/views/org/sysOrgTree.vue +864 -0
- package/src/views/param/sysParam.vue +987 -0
- package/src/views/preview/pdfViewer.vue +82 -0
- package/src/views/resources/js/resourcesCommon.js +137 -0
- package/src/views/resources/resRouter/resView.vue +161 -0
- package/src/views/resources/resourcesTabs.vue +82 -0
- package/src/views/resources/tabs/comp/pageResPreview.vue +309 -0
- package/src/views/resources/tabs/comp/pageResRegister.vue +1120 -0
- package/src/views/resources/tabs/dataResources.vue +843 -0
- package/src/views/resources/tabs/pageResources.vue +970 -0
- package/src/views/role/allowMenu.vue +148 -0
- package/src/views/role/authRole/authRole.vue +427 -0
- package/src/views/role/authRole/component/allocateSetting.vue +1056 -0
- package/src/views/role/authRole/component/authSetting.vue +1196 -0
- package/src/views/role/commonRole/commonRole.vue +677 -0
- package/src/views/role/commonRole/compoment/allocateRoleMenuSetting.vue +335 -0
- package/src/views/role/commonRole/compoment/authLinkMenuTree.vue +55 -0
- package/src/views/role/commonRole/compoment/authSettingNew.vue +190 -0
- package/src/views/role/commonRole/compoment/commonSetting.vue +1576 -0
- package/src/views/role/commonRole/compoment/commonSettingAdjust.vue +584 -0
- package/src/views/role/commonRole/compoment/commonSettingNew.vue +572 -0
- package/src/views/role/commonRole/compoment/roleMenuPower.vue +226 -0
- package/src/views/role/commonRole/compoment/roleMenuPowerSetting.vue +69 -0
- package/src/views/role/commonRole/compoment/roleMenuSetting.vue +365 -0
- package/src/views/role/commonRole/compoment/roleSourceSetting.vue +229 -0
- package/src/views/role/commonRole/tenantCommonRole.vue +768 -0
- package/src/views/role/role.vue +135 -0
- package/src/views/role/roleMenuOption.vue +898 -0
- package/src/views/role/roleSynchroRemind.vue +399 -0
- package/src/views/role/sysRole.vue +1525 -0
- package/src/views/role/viewMenuOptDetail.vue +182 -0
- package/src/views/sms/sendSms.vue +164 -0
- package/src/views/station/orgStation.vue +561 -0
- package/src/views/tenant/appContentManager.vue +938 -0
- package/src/views/tenant/appManager.vue +642 -0
- package/src/views/tenant/tenantRoleManager.vue +670 -0
- package/src/views/tenant/tenantUserManager.vue +615 -0
- package/src/views/threeinone/compoment/safeCascadeSelect.vue +327 -0
- package/src/views/threeinone/init/safeInitRegion.vue +203 -0
- package/src/views/threeinone/safeManager.vue +927 -0
- package/src/views/threeinone/safeMenuManage.vue +565 -0
- package/src/views/threeinone/safeOrgSpv.vue +364 -0
- package/src/views/threeinone/safeSpv/safeSpvLeftTree.vue +109 -0
- package/src/views/threeinone/safeSpv/safeSpvMain.vue +335 -0
- package/src/views/threeinone/safeSpvEconView.vue +569 -0
- package/src/views/threeinone/safeValidateRegion.vue +328 -0
- package/src/views/urlResource/urlResource.vue +856 -0
- package/src/views/user/empowerUser/empowerEntUserManage.vue +415 -0
- package/src/views/user/empowerUser/empowerOrgTree.vue +167 -0
- package/src/views/user/empowerUser/empowerUserList.vue +633 -0
- package/src/views/user/empowerUser/empowerUserListMenuDeatil.vue +656 -0
- package/src/views/user/empowerUser/empowerUserListViewMenuTree.vue +257 -0
- package/src/views/user/empowerUser/empowerUserManage.vue +99 -0
- package/src/views/user/stationUserManage.vue +934 -0
- package/src/views/user/userManage.vue +737 -0
- package/src/views/user/userMangement.vue +938 -0
- package/src/views/user/viewMenu/viewMenu.vue +113 -0
- package/src/views/versionupdatetool/versionUpdateTool.vue +225 -0
- package/src/views/versionupdatetool/versioninfomation/verisonInfomationManagement.vue +68 -0
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="preview-pdf">
|
|
3
|
+
<div class="loading-block">
|
|
4
|
+
<img src="../../assets/images/loading-bar.gif" class="loading">
|
|
5
|
+
<p class="loading-word">加载中...</p>
|
|
6
|
+
</div>
|
|
7
|
+
<div ref="pdfViewerRef" style="z-index: 10;"></div>
|
|
8
|
+
</div>
|
|
9
|
+
</template>
|
|
10
|
+
|
|
11
|
+
<script>
|
|
12
|
+
import PDFObject from 'pdfobject';
|
|
13
|
+
|
|
14
|
+
export default {
|
|
15
|
+
name: "pdf-viewer",
|
|
16
|
+
data(){
|
|
17
|
+
return {
|
|
18
|
+
previewUrl: '/converterHtmlController/converterAttachment',
|
|
19
|
+
url: ''
|
|
20
|
+
}
|
|
21
|
+
},
|
|
22
|
+
mounted(){
|
|
23
|
+
this.getPDFUrl();
|
|
24
|
+
},
|
|
25
|
+
methods: {
|
|
26
|
+
getPDFUrl(){
|
|
27
|
+
const fjid = this.$route.query.fjid;
|
|
28
|
+
const fjType = this.$route.query.fjType;
|
|
29
|
+
const url = window.JAVA_URL + "/" + window.ADMIN_NAME +
|
|
30
|
+
this.previewUrl +`?fjid=${fjid}&fjType=${fjType}`;
|
|
31
|
+
PDFObject.embed(url, this.$refs.pdfViewerRef, {style: 'position: absolute'});
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
</script>
|
|
36
|
+
|
|
37
|
+
<style scoped lang="scss">
|
|
38
|
+
.preview-pdf{
|
|
39
|
+
position: absolute;
|
|
40
|
+
top: 0;
|
|
41
|
+
bottom: 0;
|
|
42
|
+
left: 0;
|
|
43
|
+
right: 0;
|
|
44
|
+
overflow-x: hidden;
|
|
45
|
+
overflow-y: hidden;
|
|
46
|
+
|
|
47
|
+
.loading-block{
|
|
48
|
+
position: absolute;
|
|
49
|
+
top: 50%;
|
|
50
|
+
left: 50%;
|
|
51
|
+
width: 150px;
|
|
52
|
+
height: 150px;
|
|
53
|
+
margin-left: -75px;
|
|
54
|
+
margin-top: -75px;
|
|
55
|
+
|
|
56
|
+
.loading{
|
|
57
|
+
width: 150px;
|
|
58
|
+
height: 100px;
|
|
59
|
+
z-index: 1;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
.loading-word{
|
|
63
|
+
width: 150px;
|
|
64
|
+
text-align: center;
|
|
65
|
+
font-size: 14px;
|
|
66
|
+
font-family: "saspiconfont", sans-serif;
|
|
67
|
+
color: #333333;
|
|
68
|
+
letter-spacing: 4px;
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
/deep/{
|
|
73
|
+
.pdfobject-container {
|
|
74
|
+
position: absolute;
|
|
75
|
+
top: 0;
|
|
76
|
+
bottom: 0;
|
|
77
|
+
left: 0;
|
|
78
|
+
right: 0;
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
</style>
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
// 资源分类
|
|
2
|
+
let arrRTypeDatas = [
|
|
3
|
+
{id: 'page', name: '公共页面资源'},
|
|
4
|
+
{id: 'menu', name: '菜单使用资源'},
|
|
5
|
+
{id: 'data', name: '数据资源'}
|
|
6
|
+
];
|
|
7
|
+
let MapRTypeDatas = {
|
|
8
|
+
'page':'公共页面资源',
|
|
9
|
+
'menu':'菜单使用资源',
|
|
10
|
+
'data':'数据资源'
|
|
11
|
+
};
|
|
12
|
+
|
|
13
|
+
// 资源分类
|
|
14
|
+
let arrWhether = [
|
|
15
|
+
{id: '1', name: '是', tag: "success"},
|
|
16
|
+
{id: '0', name: '否', tag: "danger"}
|
|
17
|
+
];
|
|
18
|
+
|
|
19
|
+
// 资源状态
|
|
20
|
+
let arrRStatus = [
|
|
21
|
+
{id: "1", name: "启用", tag: "default"},
|
|
22
|
+
{id: "0", name: "禁用", tag: "danger"},
|
|
23
|
+
];
|
|
24
|
+
|
|
25
|
+
// 数据请求类型
|
|
26
|
+
let arrRDataReqType = [
|
|
27
|
+
{id: "add", name: "添加"},
|
|
28
|
+
{id: "delete", name: "删除"},
|
|
29
|
+
{id: "update", name: "修改"},
|
|
30
|
+
{id: "query", name: "查询"},
|
|
31
|
+
];
|
|
32
|
+
|
|
33
|
+
// 资源来源
|
|
34
|
+
let arrRSource = [
|
|
35
|
+
{id: "form", name: "智能建表"},
|
|
36
|
+
{id: "flow", name: "工作流"},
|
|
37
|
+
{id: "cview", name: "复合视图"},
|
|
38
|
+
{id:"url",name:"URL资源"},
|
|
39
|
+
{id:"sys",name:"系统功能"},
|
|
40
|
+
{id:"singleForm",name:"单表表单"},
|
|
41
|
+
{id: "data", name: "大数据"},
|
|
42
|
+
{id: "gis", name: "GIS"},
|
|
43
|
+
{id: "iot", name: "物联网"},
|
|
44
|
+
];
|
|
45
|
+
|
|
46
|
+
// 是否限制入参
|
|
47
|
+
let arrRIfRestrictedParams = [
|
|
48
|
+
{id: "1", name: "是", tag: ""},
|
|
49
|
+
{id: "0", name: "否", tag: "info"},
|
|
50
|
+
];
|
|
51
|
+
|
|
52
|
+
let objRTypeDatas = {};
|
|
53
|
+
let objWhether = {};
|
|
54
|
+
let objWhetherTag = {};
|
|
55
|
+
let objRStatus = {};
|
|
56
|
+
let objRStatusTag = {};
|
|
57
|
+
let objRSource = {};
|
|
58
|
+
let objRDataReqType = {};
|
|
59
|
+
let objRIfRestrictedParams = {};
|
|
60
|
+
|
|
61
|
+
arrRTypeDatas.forEach(data => {
|
|
62
|
+
objRTypeDatas[data.id] = data.name;
|
|
63
|
+
});
|
|
64
|
+
|
|
65
|
+
arrRStatus.forEach(data => {
|
|
66
|
+
objRStatus[data.id] = data.name;
|
|
67
|
+
objRStatusTag[data.id] = data.tag;
|
|
68
|
+
});
|
|
69
|
+
|
|
70
|
+
arrRSource.forEach(data => {
|
|
71
|
+
objRSource[data.id] = data.name;
|
|
72
|
+
});
|
|
73
|
+
|
|
74
|
+
arrRDataReqType.forEach(data => {
|
|
75
|
+
objRDataReqType[data.id] = data.name;
|
|
76
|
+
});
|
|
77
|
+
|
|
78
|
+
arrRIfRestrictedParams.forEach(data => {
|
|
79
|
+
objRIfRestrictedParams[data.id] = data.name;
|
|
80
|
+
});
|
|
81
|
+
|
|
82
|
+
arrWhether.forEach(data => {
|
|
83
|
+
objWhether[data.id] = data.name;
|
|
84
|
+
console.log("data.tog",data.tag);
|
|
85
|
+
objWhetherTag[data.id] = data.tag;
|
|
86
|
+
});
|
|
87
|
+
|
|
88
|
+
export default {
|
|
89
|
+
arrRTypeDatas,
|
|
90
|
+
MapRTypeDatas,
|
|
91
|
+
objRTypeDatas,
|
|
92
|
+
arrWhether,
|
|
93
|
+
objWhether,
|
|
94
|
+
objWhetherTag,
|
|
95
|
+
arrRStatus,
|
|
96
|
+
objRStatus,
|
|
97
|
+
objRStatusTag,
|
|
98
|
+
arrRSource,
|
|
99
|
+
objRSource,
|
|
100
|
+
arrRIfRestrictedParams,
|
|
101
|
+
objRIfRestrictedParams,
|
|
102
|
+
arrRDataReqType,
|
|
103
|
+
objRDataReqType,
|
|
104
|
+
|
|
105
|
+
/**
|
|
106
|
+
* 获取操作权限
|
|
107
|
+
* @param data
|
|
108
|
+
* @returns {[]}
|
|
109
|
+
*/
|
|
110
|
+
getArrROperationAuthoritys(data) {
|
|
111
|
+
return data.rOperationAuthoritys ? JSON.parse(data.rOperationAuthoritys || '[]') : [];
|
|
112
|
+
},
|
|
113
|
+
|
|
114
|
+
/**
|
|
115
|
+
* 获取数据权限
|
|
116
|
+
* @param data
|
|
117
|
+
* @returns {[]}
|
|
118
|
+
*/
|
|
119
|
+
getArrRDataAuthoritys(data) {
|
|
120
|
+
return data.rDataAuthoritys ? JSON.parse(data.rDataAuthoritys || '[]') : [];
|
|
121
|
+
},
|
|
122
|
+
|
|
123
|
+
/**
|
|
124
|
+
* 获取参数列表
|
|
125
|
+
*/
|
|
126
|
+
getArrRParamLists(data) {
|
|
127
|
+
return data.rparamLists ? JSON.parse(data.rparamLists || '[]') : [];
|
|
128
|
+
},
|
|
129
|
+
|
|
130
|
+
/**
|
|
131
|
+
* 格式化操作类型
|
|
132
|
+
* @param data
|
|
133
|
+
*/
|
|
134
|
+
formatterOpearteType(data){
|
|
135
|
+
return data.powerKey.indexOf("tree")> -1 ? '树' : '按钮';
|
|
136
|
+
}
|
|
137
|
+
}
|
|
@@ -0,0 +1,161 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<!--url 外部链接-->
|
|
3
|
+
<ifm-link :link-url="linkUrl" v-if="isIfm"></ifm-link>
|
|
4
|
+
<keep-alive v-else-if="ifurlnb" >
|
|
5
|
+
<component :is="activeIndex"
|
|
6
|
+
v-bind="paramObj"
|
|
7
|
+
:isRefresh="isRefresh"
|
|
8
|
+
style="height: 100%" ></component>
|
|
9
|
+
</keep-alive>
|
|
10
|
+
<!--url 内部链接 -->
|
|
11
|
+
</template>
|
|
12
|
+
|
|
13
|
+
<script>
|
|
14
|
+
import {IfmLink} from "sasp-admin";
|
|
15
|
+
export default {
|
|
16
|
+
name: "resView",
|
|
17
|
+
components: {IfmLink},
|
|
18
|
+
data(){
|
|
19
|
+
return{
|
|
20
|
+
rAgentUrl:this.$route.params.rAgentUrl, //代理地址
|
|
21
|
+
loginUser:{},
|
|
22
|
+
resourceUrl:{},
|
|
23
|
+
linkUrl:'', //外部链接地址
|
|
24
|
+
isIfm:false,
|
|
25
|
+
activeUrl:"",
|
|
26
|
+
activeParam:"",
|
|
27
|
+
paramObj:{},
|
|
28
|
+
ifurlnb:false,
|
|
29
|
+
activeIndex:{},
|
|
30
|
+
isRefresh:this.COMMON_FUNC.getUUID(),
|
|
31
|
+
allRouterArr:this.$router.options.routes || [],
|
|
32
|
+
}
|
|
33
|
+
},
|
|
34
|
+
watch:{
|
|
35
|
+
'$route.params.rAgentUrl' (to, from) {
|
|
36
|
+
this.initRouter();
|
|
37
|
+
}
|
|
38
|
+
},
|
|
39
|
+
created(){
|
|
40
|
+
//查询资源池
|
|
41
|
+
//获取资源池,然后根据资源池数据获取资源地址
|
|
42
|
+
this.getLoginUser();
|
|
43
|
+
this.initRouter();
|
|
44
|
+
},
|
|
45
|
+
methods:{
|
|
46
|
+
getLoginUser(){
|
|
47
|
+
this.loginUser = this.USER_GLOBAL.getLoginUser();
|
|
48
|
+
},
|
|
49
|
+
|
|
50
|
+
initRouter(){ //初始化跳转
|
|
51
|
+
this.linkUrl = '';
|
|
52
|
+
this.isIfm = false;
|
|
53
|
+
this.ifurlnb = false;
|
|
54
|
+
if(this.resourceUrl.hasOwnProperty(this.resourceId)){
|
|
55
|
+
this.routerPush(this.resourceUrl[this.resourceId]);
|
|
56
|
+
}else {
|
|
57
|
+
if(this.$route.params.rcommon){
|
|
58
|
+
this.rAgentUrl = this.$route.params.rcommon + "/"+this.rAgentUrl;
|
|
59
|
+
}
|
|
60
|
+
this.axios.post(this.api.resources.find,{rAgentUrlEq:this.rAgentUrl,rType:'page',rStatus:'1'}).then(res =>{
|
|
61
|
+
let url = "";
|
|
62
|
+
let resouceArr = [];
|
|
63
|
+
if(res && res.data){
|
|
64
|
+
resouceArr = res.data || [];
|
|
65
|
+
}
|
|
66
|
+
if(resouceArr.length > 0){
|
|
67
|
+
let resouceObj = {};
|
|
68
|
+
let url = "";
|
|
69
|
+
(resouceArr || []).some(item =>{
|
|
70
|
+
if(item.rsource == 'url'){
|
|
71
|
+
this.ifurlnb = true;
|
|
72
|
+
url = item.ragentUrl;
|
|
73
|
+
//执行跳转
|
|
74
|
+
if(url.indexOf(".jsp")>-1||url.indexOf(".html")>-1){
|
|
75
|
+
this.$message("暂无功能!");
|
|
76
|
+
}else if(url.indexOf("http://") > -1 || url.indexOf("https://") > -1){
|
|
77
|
+
this.linkUrl = url;
|
|
78
|
+
this.isIfm = true;
|
|
79
|
+
}else {
|
|
80
|
+
this.isRefresh = this.COMMON_FUNC.getUUID();
|
|
81
|
+
this.activeUrl = '';
|
|
82
|
+
//递归遍历 router 路由 判断当前路由是否存在
|
|
83
|
+
let urlArr = url.split("/");
|
|
84
|
+
this.eachRouterSet(this.allRouterArr,urlArr,0);
|
|
85
|
+
}
|
|
86
|
+
return true;
|
|
87
|
+
}else {
|
|
88
|
+
resouceObj = item;
|
|
89
|
+
this.ifurlnb = true;
|
|
90
|
+
if(!this.isEmptyObject(resouceObj)){
|
|
91
|
+
//判断 资源类型跳转到指定页面
|
|
92
|
+
this.$route.params["resourceId"] = resouceObj.id || ''; //传递resourceId
|
|
93
|
+
if (this.VIEW_COMPONENTS.hasOwnProperty(resouceObj.rsource)
|
|
94
|
+
&&this.VIEW_COMPONENTS[resouceObj.rsource].hasOwnProperty("res")) {
|
|
95
|
+
this.activeIndex = this.VIEW_COMPONENTS[resouceObj.rsource]["res"];//跳转到表单视图预览
|
|
96
|
+
}else{
|
|
97
|
+
this.$message("未引入相关组件,无法渲染!");
|
|
98
|
+
this.activeIndex = {};
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
}
|
|
102
|
+
return true;
|
|
103
|
+
}
|
|
104
|
+
});
|
|
105
|
+
|
|
106
|
+
}
|
|
107
|
+
});
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
},
|
|
111
|
+
eachRouterSet(allRouterArr,urlArr,index){
|
|
112
|
+
allRouterArr.forEach(item =>{
|
|
113
|
+
if(urlArr[index + 1]){
|
|
114
|
+
if((urlArr[index +1] == (item.name ? item.name : item.path))||((item.name ? item.name : item.path)).indexOf(urlArr[index +1]+"/:")>-1){
|
|
115
|
+
//当前匹配
|
|
116
|
+
//判断 urlArr是否存在下级
|
|
117
|
+
if(item.children && item.children.length > 0) {
|
|
118
|
+
//如果存在下级
|
|
119
|
+
allRouterArr = item.children || [];
|
|
120
|
+
index = index + 1;
|
|
121
|
+
this.eachRouterSet(allRouterArr,urlArr,index);
|
|
122
|
+
}else{
|
|
123
|
+
this.activeIndex = item.component;
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
})
|
|
128
|
+
},
|
|
129
|
+
/**
|
|
130
|
+
* 请求跳转
|
|
131
|
+
*/
|
|
132
|
+
routerPush(url) {
|
|
133
|
+
this.$router.push({
|
|
134
|
+
path: url
|
|
135
|
+
});
|
|
136
|
+
|
|
137
|
+
},
|
|
138
|
+
|
|
139
|
+
|
|
140
|
+
/**
|
|
141
|
+
* 判断obj对象是否为空
|
|
142
|
+
* @param obj
|
|
143
|
+
* @returns {boolean}
|
|
144
|
+
*/
|
|
145
|
+
isEmptyObject(obj) {
|
|
146
|
+
for (let key in obj){
|
|
147
|
+
if (obj.hasOwnProperty(key)) {
|
|
148
|
+
return false;//返回false,不为空对象
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
return true;//返回true,为空对象
|
|
152
|
+
},
|
|
153
|
+
|
|
154
|
+
}
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
</script>
|
|
158
|
+
|
|
159
|
+
<style scoped>
|
|
160
|
+
|
|
161
|
+
</style>
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="pos-abs-full" style="overflow-y: hidden;padding:5px;">
|
|
3
|
+
<el-button type="primary"
|
|
4
|
+
size="small"
|
|
5
|
+
style="position: absolute;right:20px;top:20px;z-index:999"
|
|
6
|
+
@click="refreshCache"
|
|
7
|
+
v-if="workTurnOn">刷新资源池缓存</el-button>
|
|
8
|
+
<el-tabs type="border-card" class="el-tabs-rel" @tab-click="tabClick" style="height: 100%;">
|
|
9
|
+
<el-tab-pane>
|
|
10
|
+
<span slot="label"><i class="el-icon-document"></i> 页面资源</span>
|
|
11
|
+
<pl-lazy time="0">
|
|
12
|
+
<page-resources></page-resources>
|
|
13
|
+
</pl-lazy>
|
|
14
|
+
</el-tab-pane>
|
|
15
|
+
<el-tab-pane>
|
|
16
|
+
<span slot="label"><i class="el-icon-coin"></i> 数据资源</span>
|
|
17
|
+
<pl-lazy time="500">
|
|
18
|
+
<data-resources></data-resources>
|
|
19
|
+
</pl-lazy>
|
|
20
|
+
</el-tab-pane>
|
|
21
|
+
</el-tabs>
|
|
22
|
+
|
|
23
|
+
<!-- <div id="resBtnContainer">-->
|
|
24
|
+
<!-- <el-button type="danger" icon="el-icon-refresh-right" @click="refreshCache" size="small">刷新缓存</el-button>-->
|
|
25
|
+
<!-- </div>-->
|
|
26
|
+
</div>
|
|
27
|
+
</template>
|
|
28
|
+
|
|
29
|
+
<script>
|
|
30
|
+
import PageResources from "./tabs/pageResources";
|
|
31
|
+
import DataResources from "./tabs/dataResources";
|
|
32
|
+
import {WORK_GLOBAL} from "sasp-base";
|
|
33
|
+
|
|
34
|
+
export default {
|
|
35
|
+
name: "resources-tabs",
|
|
36
|
+
components: {DataResources, PageResources},
|
|
37
|
+
data() {
|
|
38
|
+
return {
|
|
39
|
+
workTurnOn:false,
|
|
40
|
+
};
|
|
41
|
+
},
|
|
42
|
+
created(){
|
|
43
|
+
this.initWorkStageTurnOn();
|
|
44
|
+
},
|
|
45
|
+
|
|
46
|
+
methods: {
|
|
47
|
+
tabClick(tab) {
|
|
48
|
+
tab && tab.$children && tab.$children[0] && tab.$children[0].$children[0] && tab.$children[0].$children[0].crud && tab.$children[0].$children[0].crud.search();
|
|
49
|
+
},
|
|
50
|
+
|
|
51
|
+
/**
|
|
52
|
+
* 刷新缓存
|
|
53
|
+
* @param noMessage 是否不提示
|
|
54
|
+
*/
|
|
55
|
+
refreshCache(noMessage) {
|
|
56
|
+
this.axios.post(this.api.resources.initData).then(res => {
|
|
57
|
+
!noMessage || this.$message({
|
|
58
|
+
duration: 1000,
|
|
59
|
+
message: res.data.operateMessage,
|
|
60
|
+
type: "success"
|
|
61
|
+
});
|
|
62
|
+
});
|
|
63
|
+
},
|
|
64
|
+
|
|
65
|
+
initWorkStageTurnOn(){
|
|
66
|
+
this.workTurnOn = WORK_GLOBAL.getTurnOn(this.switchOnline,"4669d978200511ec95d7431cceb3a268");
|
|
67
|
+
},
|
|
68
|
+
switchOnline(val){
|
|
69
|
+
this.workTurnOn = val;
|
|
70
|
+
},
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
</script>
|
|
74
|
+
|
|
75
|
+
<style scoped>
|
|
76
|
+
#resBtnContainer {
|
|
77
|
+
position: absolute;
|
|
78
|
+
top: 9px;
|
|
79
|
+
right: 20px;
|
|
80
|
+
display: inline-block;
|
|
81
|
+
}
|
|
82
|
+
</style>
|