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.
Files changed (141) hide show
  1. package/index.js +227 -0
  2. package/package.json +19 -0
  3. package/router.js +83 -0
  4. package/src/assets/font/iconfont.css +1346 -0
  5. package/src/assets/font/iconfont.eot +0 -0
  6. package/src/assets/font/iconfont.js +1 -0
  7. package/src/assets/font/iconfont.svg +827 -0
  8. package/src/assets/font/iconfont.ttf +0 -0
  9. package/src/assets/font/iconfont.woff +0 -0
  10. package/src/assets/images/loading-bar.gif +0 -0
  11. package/src/assets/js/adminInstall.js +36 -0
  12. package/src/assets/js/api/apiAdmin.js +613 -0
  13. package/src/assets/js/global/dataGlobal.js +260 -0
  14. package/src/assets/js/global/logGlobal.js +22 -0
  15. package/src/assets/js/global/paramGlobal.js +67 -0
  16. package/src/assets/js/global/resGlobal.js +91 -0
  17. package/src/assets/js/global/userGlobal.js +283 -0
  18. package/src/components/complexViewRendering.vue +601 -0
  19. package/src/components/ifmLink.vue +71 -0
  20. package/src/components/public/data/plDataCascader.vue +85 -0
  21. package/src/components/public/data/plDataRadio.vue +73 -0
  22. package/src/components/public/data/plDataRadioGroup.vue +70 -0
  23. package/src/components/public/data/plDataSelect.vue +856 -0
  24. package/src/components/public/data/plDatePicker.vue +159 -0
  25. package/src/components/public/org/bg.png +0 -0
  26. package/src/components/public/org/sysOrgPosUserSelect.vue +1237 -0
  27. package/src/components/public/org/sysOrgPosUserSelectDark.vue +1402 -0
  28. package/src/components/public/org/sysOrgPosUserSelectNew.vue +1527 -0
  29. package/src/components/public/upload/images/compress.png +0 -0
  30. package/src/components/public/upload/images/emipty.png +0 -0
  31. package/src/components/public/upload/images/excel.png +0 -0
  32. package/src/components/public/upload/images/file.png +0 -0
  33. package/src/components/public/upload/images/pdf.png +0 -0
  34. package/src/components/public/upload/images/powerpoint.png +0 -0
  35. package/src/components/public/upload/images/project.png +0 -0
  36. package/src/components/public/upload/images/sound.png +0 -0
  37. package/src/components/public/upload/images/txt.png +0 -0
  38. package/src/components/public/upload/images/video.png +0 -0
  39. package/src/components/public/upload/images/visio.png +0 -0
  40. package/src/components/public/upload/images/word.png +0 -0
  41. package/src/components/public/upload/plImage.vue +287 -0
  42. package/src/components/public/upload/plImgUpload.vue +137 -0
  43. package/src/components/public/upload/plUpload.vue +1124 -0
  44. package/src/components/public/upload/uploadImg.js +8 -0
  45. package/src/main.js +0 -0
  46. package/src/views/VueMenuView.vue +143 -0
  47. package/src/views/cloudMenuView.vue +125 -0
  48. package/src/views/complex/config/complex.vue +501 -0
  49. package/src/views/complex/config/complexSetting.vue +1250 -0
  50. package/src/views/complex/rendering/complexShow.vue +16 -0
  51. package/src/views/data/dataManage.vue +560 -0
  52. package/src/views/data/sysData.vue +292 -0
  53. package/src/views/event/eventManager/vueEventDiy.vue +1184 -0
  54. package/src/views/event/eventManager/vueEventMain.vue +108 -0
  55. package/src/views/event/eventManager/vueEventSys.vue +296 -0
  56. package/src/views/event/js/apiEvent.js +22 -0
  57. package/src/views/fileLog/fileDownloadLog.vue +437 -0
  58. package/src/views/initData/initData.vue +4316 -0
  59. package/src/views/log/dblog/logdbDevelop.vue +306 -0
  60. package/src/views/log/dblog/logdbEnt.vue +331 -0
  61. package/src/views/log/dblog/logdbGov.vue +395 -0
  62. package/src/views/log/error/logError.vue +553 -0
  63. package/src/views/log/loginlog/logManageDevOrSup.vue +357 -0
  64. package/src/views/log/loginlog/logManageEnt.vue +343 -0
  65. package/src/views/log/loginlog/logManageGov.vue +328 -0
  66. package/src/views/log/sms/logSms.vue +308 -0
  67. package/src/views/menu/component/menuManageComponent.vue +2402 -0
  68. package/src/views/menu/component/menuModule.vue +449 -0
  69. package/src/views/menu/menuLocal.vue +223 -0
  70. package/src/views/menu/menuManage.vue +1135 -0
  71. package/src/views/menu/tenantMenuManage.vue +1132 -0
  72. package/src/views/menuRouter/cview/cviewShow.vue +18 -0
  73. package/src/views/menuRouter/cviewMenuRouter.vue +183 -0
  74. package/src/views/menuRouter/menuView.vue +132 -0
  75. package/src/views/menuRouter/urlMenuRouter.vue +160 -0
  76. package/src/views/org/entOrgTree.vue +1050 -0
  77. package/src/views/org/ownerMenu/ownerMenuTree.vue +269 -0
  78. package/src/views/org/safeValidate/safeValidate.vue +469 -0
  79. package/src/views/org/sysEntOrgUserDetail.vue +3390 -0
  80. package/src/views/org/sysOrgDimension.vue +832 -0
  81. package/src/views/org/sysOrgPosUserDetail.vue +1648 -0
  82. package/src/views/org/sysOrgPosUserTree.vue +1101 -0
  83. package/src/views/org/sysOrgTree.vue +864 -0
  84. package/src/views/param/sysParam.vue +987 -0
  85. package/src/views/preview/pdfViewer.vue +82 -0
  86. package/src/views/resources/js/resourcesCommon.js +137 -0
  87. package/src/views/resources/resRouter/resView.vue +161 -0
  88. package/src/views/resources/resourcesTabs.vue +82 -0
  89. package/src/views/resources/tabs/comp/pageResPreview.vue +309 -0
  90. package/src/views/resources/tabs/comp/pageResRegister.vue +1120 -0
  91. package/src/views/resources/tabs/dataResources.vue +843 -0
  92. package/src/views/resources/tabs/pageResources.vue +970 -0
  93. package/src/views/role/allowMenu.vue +148 -0
  94. package/src/views/role/authRole/authRole.vue +427 -0
  95. package/src/views/role/authRole/component/allocateSetting.vue +1056 -0
  96. package/src/views/role/authRole/component/authSetting.vue +1196 -0
  97. package/src/views/role/commonRole/commonRole.vue +677 -0
  98. package/src/views/role/commonRole/compoment/allocateRoleMenuSetting.vue +335 -0
  99. package/src/views/role/commonRole/compoment/authLinkMenuTree.vue +55 -0
  100. package/src/views/role/commonRole/compoment/authSettingNew.vue +190 -0
  101. package/src/views/role/commonRole/compoment/commonSetting.vue +1576 -0
  102. package/src/views/role/commonRole/compoment/commonSettingAdjust.vue +584 -0
  103. package/src/views/role/commonRole/compoment/commonSettingNew.vue +572 -0
  104. package/src/views/role/commonRole/compoment/roleMenuPower.vue +226 -0
  105. package/src/views/role/commonRole/compoment/roleMenuPowerSetting.vue +69 -0
  106. package/src/views/role/commonRole/compoment/roleMenuSetting.vue +365 -0
  107. package/src/views/role/commonRole/compoment/roleSourceSetting.vue +229 -0
  108. package/src/views/role/commonRole/tenantCommonRole.vue +768 -0
  109. package/src/views/role/role.vue +135 -0
  110. package/src/views/role/roleMenuOption.vue +898 -0
  111. package/src/views/role/roleSynchroRemind.vue +399 -0
  112. package/src/views/role/sysRole.vue +1525 -0
  113. package/src/views/role/viewMenuOptDetail.vue +182 -0
  114. package/src/views/sms/sendSms.vue +164 -0
  115. package/src/views/station/orgStation.vue +561 -0
  116. package/src/views/tenant/appContentManager.vue +938 -0
  117. package/src/views/tenant/appManager.vue +642 -0
  118. package/src/views/tenant/tenantRoleManager.vue +670 -0
  119. package/src/views/tenant/tenantUserManager.vue +615 -0
  120. package/src/views/threeinone/compoment/safeCascadeSelect.vue +327 -0
  121. package/src/views/threeinone/init/safeInitRegion.vue +203 -0
  122. package/src/views/threeinone/safeManager.vue +927 -0
  123. package/src/views/threeinone/safeMenuManage.vue +565 -0
  124. package/src/views/threeinone/safeOrgSpv.vue +364 -0
  125. package/src/views/threeinone/safeSpv/safeSpvLeftTree.vue +109 -0
  126. package/src/views/threeinone/safeSpv/safeSpvMain.vue +335 -0
  127. package/src/views/threeinone/safeSpvEconView.vue +569 -0
  128. package/src/views/threeinone/safeValidateRegion.vue +328 -0
  129. package/src/views/urlResource/urlResource.vue +856 -0
  130. package/src/views/user/empowerUser/empowerEntUserManage.vue +415 -0
  131. package/src/views/user/empowerUser/empowerOrgTree.vue +167 -0
  132. package/src/views/user/empowerUser/empowerUserList.vue +633 -0
  133. package/src/views/user/empowerUser/empowerUserListMenuDeatil.vue +656 -0
  134. package/src/views/user/empowerUser/empowerUserListViewMenuTree.vue +257 -0
  135. package/src/views/user/empowerUser/empowerUserManage.vue +99 -0
  136. package/src/views/user/stationUserManage.vue +934 -0
  137. package/src/views/user/userManage.vue +737 -0
  138. package/src/views/user/userMangement.vue +938 -0
  139. package/src/views/user/viewMenu/viewMenu.vue +113 -0
  140. package/src/views/versionupdatetool/versionUpdateTool.vue +225 -0
  141. package/src/views/versionupdatetool/versioninfomation/verisonInfomationManagement.vue +68 -0
@@ -0,0 +1,260 @@
1
+ import admin from "../api/apiAdmin";
2
+ let apiAdmin = admin.apis;
3
+ let axios = null;
4
+
5
+ export default {
6
+ name: "DATA_GLOBAL",
7
+
8
+ OBJ_DATAS: {}, // 数据字典ID 对 本级数据字典数组
9
+ OBJ_DATAOBJS: {},
10
+ OBJ_TREE_DATAS: {}, // 数据字典ID 对 数据字典树
11
+ KEY_NAME: {}, // 存放元数据的key和name,用作其他模块的使用
12
+ install(Vue,opts){
13
+ axios = opts.axios;
14
+ },
15
+
16
+ /**
17
+ * 根据typeId刷新数据字典缓存
18
+ * @param typeId
19
+ */
20
+ refreshByTypeId(typeId) {
21
+ let vm = this;
22
+ Object.keys(vm.OBJ_DATAS).forEach(function (key) {
23
+ if (key.indexOf(typeId) > -1) {
24
+ let arrKeys = key.split("_");
25
+ vm.getDatas(arrKeys[0], arrKeys[1]);
26
+ }
27
+ });
28
+
29
+ Object.keys(vm.OBJ_TREE_DATAS).forEach(function (key) {
30
+ if (key.indexOf(typeId) > -1) {
31
+ let arrKeys = key.split("_");
32
+ vm.getTreeDatas(arrKeys[0], arrKeys[1]);
33
+ }
34
+ });
35
+ },
36
+
37
+ /**
38
+ * 获取数据字典(数组形式)
39
+ * @param typeId
40
+ * @param parentId
41
+ * @param ifRefresh 是否刷新
42
+ * @returns {*}
43
+ */
44
+ getDatas(typeId, parentId, ifRefresh) {
45
+ let vm = this;
46
+ if (!typeId) {
47
+ return [];
48
+ }
49
+ parentId = parentId || "";
50
+ ifRefresh = ifRefresh || false;
51
+ return new Promise(function (resolve) {
52
+
53
+ if (vm.OBJ_DATAS[typeId + "_" + parentId] && !ifRefresh) {
54
+ resolve(vm.OBJ_DATAS[typeId + "_" + parentId]);
55
+ } else {
56
+ let objDatas = [];
57
+ axios.post(apiAdmin.data.getDataByType, {typeId: typeId, parentId: parentId}).then(function (res) {
58
+ objDatas.push(...res.data);
59
+ vm.OBJ_DATAS[typeId + "_" + parentId] = objDatas;
60
+ resolve(objDatas);
61
+ });
62
+ }
63
+ });
64
+ },
65
+
66
+ /**
67
+ * 获取数据字典(数组形式)
68
+ * @param typeId
69
+ * @param parentId
70
+ * @param ifRefresh 是否刷新
71
+ * @param getOutDate 是否查询过期数据,1:默认查询,0:不查询
72
+ * @returns {*}
73
+ */
74
+ getDatasContainOutDate(typeId, parentId, ifRefresh,getOutDate) {
75
+ let vm = this;
76
+ if (!typeId) {
77
+ return [];
78
+ }
79
+ parentId = parentId || "";
80
+ ifRefresh = ifRefresh || false;
81
+ getOutDate = getOutDate || "1";
82
+ return new Promise(function (resolve) {
83
+ if (vm.OBJ_DATAS[typeId + "_" + parentId + "_" + getOutDate] && !ifRefresh) {
84
+ resolve(vm.OBJ_DATAS[typeId + "_" + parentId + "_" + getOutDate]);
85
+ } else {
86
+ let objDatas = [];
87
+ axios.post(apiAdmin.data.getDataByType, {typeId: typeId, parentId: parentId, getOutDate:getOutDate}).then(function (res) {
88
+ objDatas.push(...res.data);
89
+ vm.OBJ_DATAS[typeId + "_" + parentId+ "_" + getOutDate] = objDatas;
90
+ resolve(objDatas);
91
+ });
92
+ }
93
+ });
94
+ },
95
+
96
+ /**
97
+ * 获取数据字典(对象形式)
98
+ * @param typeId
99
+ * @param parentId
100
+ * @param ifRefresh 是否刷新
101
+ * @returns {*}
102
+ */
103
+ getDataObjs(typeId, parentId, ifRefresh) {
104
+ let vm = this;
105
+ if (!typeId) {
106
+ return {};
107
+ }
108
+
109
+ parentId = parentId || "-1";
110
+ ifRefresh = ifRefresh || false;
111
+ return new Promise(function (resolve) {
112
+ if (vm.OBJ_DATAOBJS[typeId + "_" + parentId] && !ifRefresh) {
113
+ resolve(vm.OBJ_DATAOBJS[typeId + "_" + parentId]);
114
+ } else {
115
+ vm.getDatas(typeId, parentId, ifRefresh).then(datas => {
116
+ let objData = {};
117
+ datas.forEach(data => {
118
+ objData[data.id] = data;
119
+ });
120
+ vm.OBJ_DATAOBJS[typeId + "_" + parentId] = objData;
121
+ resolve(objData);
122
+ });
123
+ }
124
+ });
125
+ },
126
+
127
+ /**
128
+ * 获取多层级数据字典
129
+ * @param typeId
130
+ * @param parentId
131
+ * @param ifRefresh 是否刷新
132
+ * @returns {*}
133
+ */
134
+ getTreeDatas(typeId, parentId, ifRefresh) {
135
+ let vm = this;
136
+ if (!typeId) {
137
+ return [];
138
+ }
139
+ parentId = parentId || "-1";
140
+ ifRefresh = ifRefresh || false;
141
+ return new Promise(function (resolve) {
142
+ if (vm.OBJ_TREE_DATAS[typeId + "_" + parentId] && !ifRefresh) {
143
+ resolve(Object.assign([], vm.OBJ_TREE_DATAS[typeId + "_" + parentId]));
144
+ } else {
145
+ axios.post(apiAdmin.data.getDataTree, {typeId: typeId, parentId: parentId}).then(function (res) {
146
+
147
+ // 如果原先已存在数据字典缓存信息,那么不直接赋值修改对象,应用引用型数据的特性
148
+ if (vm.OBJ_TREE_DATAS[typeId + "_" + parentId]) {
149
+ vm.OBJ_TREE_DATAS[typeId + "_" + parentId].splice(0, vm.OBJ_TREE_DATAS[typeId + "_" + parentId].length);
150
+ res.data.forEach(function (data) {
151
+ vm.OBJ_TREE_DATAS[typeId + "_" + parentId].push(data);
152
+ });
153
+ } else {
154
+ vm.OBJ_TREE_DATAS[typeId + "_" + parentId] = res.data;
155
+ }
156
+ resolve(Object.assign([], vm.OBJ_TREE_DATAS[typeId + "_" + parentId]));
157
+ });
158
+ }
159
+ });
160
+ },
161
+
162
+ /*
163
+ ** 存入key name
164
+ */
165
+ setKeyName(key, name) {
166
+ this.KEY_NAME[key] = name;
167
+ },
168
+ /*
169
+ ** 获取key name
170
+ */
171
+ getKeyName(key) {
172
+ return this.KEY_NAME[key];
173
+ },
174
+
175
+
176
+ /**
177
+ * 根据数据字典 ids (多个用逗号分隔)
178
+ * @param ids
179
+ * @returns {*}
180
+ */
181
+ getDataByIds(ids){
182
+ let vm = this;
183
+ if (!ids) {
184
+ return "";
185
+ }
186
+ return new Promise(resolve=>{
187
+ let dataNameArr = [];
188
+ let idArr = ids.split(",") || [];
189
+ let dataIdObj = {};
190
+ let sIds = "";
191
+ idArr.forEach(id =>{
192
+ dataIdObj[id] = this.getKeyName(id) || '';
193
+ if(!this.getKeyName(id)){
194
+ sIds += "," +id;
195
+ }
196
+ dataNameArr.push(this.getKeyName(id) || '');
197
+ });
198
+ if(sIds){
199
+ sIds = sIds.substring(1);
200
+ axios.post(apiAdmin.data.getByIds, {ids: sIds}).then(res=> {
201
+ let arr = [];
202
+ (res.data || []).forEach(item =>{
203
+ //放入缓存中
204
+ if(item && item.id && item.dataName){
205
+ vm.setKeyName(item.id,item.dataName);
206
+ // arr.push(item.dataName);
207
+ dataIdObj[item.id] = item.dataName;
208
+ }
209
+ })
210
+ idArr.forEach(id =>{
211
+ arr.push(dataIdObj[id]);
212
+ })
213
+ if(arr.length == 1){
214
+ resolve(arr[0]);
215
+ }else {
216
+ resolve(arr);
217
+ }
218
+ });
219
+ }else {
220
+ if(dataNameArr.length == 1){
221
+ resolve(dataNameArr[0]);
222
+ }else {
223
+ resolve(dataNameArr);
224
+ }
225
+ }
226
+ });
227
+ },
228
+
229
+ /**
230
+ * 根据数据字典 id 先走缓存没有数据再查后台
231
+ * @param id
232
+ * @returns {*}
233
+ */
234
+ getDataById(id){
235
+ let vm = this;
236
+ return new Promise(function (resolve) {
237
+ let dataName=vm.getKeyName(id);
238
+ if(!dataName){//缓存不存在 查后台
239
+ axios.post(apiAdmin.data.getByIds, {ids: id}).then(res=> {
240
+ if(res.data && res.data[0]!=null){
241
+ let item=res.data[0];
242
+ //放入缓存中
243
+ if(item && item.id && item.dataName){
244
+ vm.setKeyName(item.id,item.dataName);
245
+ }
246
+ resolve(item.dataName);
247
+ }else{
248
+ dataName=id;
249
+ resolve(dataName);
250
+ }
251
+ });
252
+ }else{
253
+ resolve(dataName);
254
+ }
255
+
256
+ })
257
+
258
+ }
259
+
260
+ }
@@ -0,0 +1,22 @@
1
+ import admin from "../api/apiAdmin";
2
+ let apiAdmin = admin.apis;
3
+ let axios = null;
4
+
5
+ export default {
6
+ name: "LOG_GLOBAL",
7
+
8
+ USER_LOGIN_LOG:{},//登录用户对用的登录日志
9
+ install(Vue,opts){
10
+ axios = opts.axios;
11
+ },
12
+
13
+ insertLogError(errorTime,errorInfo){
14
+ return new Promise(resolve => {
15
+ axios.post(apiAdmin,{errorTime:errorTime,errorInfo:errorInfo}).then(res => {
16
+ if(res && res.data){
17
+ resolve(res.data);
18
+ }
19
+ });
20
+ });
21
+ }
22
+ }
@@ -0,0 +1,67 @@
1
+ import admin from "../api/apiAdmin";
2
+ let apiAdmin = admin.apis;
3
+ let axios = null;
4
+
5
+ export default {
6
+ name: "PARAM_GLOBAL",
7
+
8
+ OBJ_SYSPARAM: {}, // 系统参数
9
+ KEY_NAME: {}, // 存放元数据的key和name,用作其他模块的使用
10
+ install(Vue,opts){
11
+ axios = opts.axios;
12
+ },
13
+
14
+ async init() {
15
+ if (Object.keys(this.OBJ_SYSPARAM).length == 0) {
16
+ await axios.post(apiAdmin.param.getSysParamsMap).then(res => {
17
+ this.OBJ_SYSPARAM = res.data || {};
18
+ });
19
+ }
20
+ },
21
+
22
+ /**
23
+ * 获取系统参数对象
24
+ * @param key
25
+ * @returns {*}
26
+ */
27
+ getByKey(key) {
28
+ this.init();
29
+ return this.OBJ_SYSPARAM[key] || key;
30
+ },
31
+
32
+ /**
33
+ * 根据key获取值(Promise的方式,给首页这些刷新页面即需要获取参数值得地方使用)
34
+ * @param key
35
+ * @returns {string|*}
36
+ */
37
+ async getByKeyAsync(key) {
38
+ await this.init();
39
+ return this.OBJ_SYSPARAM[key] || key;
40
+ },
41
+
42
+ /**
43
+ *
44
+ * @param key
45
+ * @returns {string|*}
46
+ */
47
+ getValByKey(key) {
48
+ this.init();
49
+ if (!this.OBJ_SYSPARAM[key]) {
50
+ return key;
51
+ }
52
+ return this.OBJ_SYSPARAM[key].paramVal.trim();
53
+ },
54
+
55
+ /**
56
+ * 根据key获取值(Promise的方式,给首页这些刷新页面即需要获取参数值得地方使用)
57
+ * @param key
58
+ * @returns {string|*}
59
+ */
60
+ async getValByKeyAsync(key) {
61
+ await this.init();
62
+ if (!this.OBJ_SYSPARAM[key]) {
63
+ return key;
64
+ }
65
+ return this.OBJ_SYSPARAM[key].paramVal.trim();
66
+ }
67
+ }
@@ -0,0 +1,91 @@
1
+ import userGlobal from "./userGlobal";
2
+ import admin from "../api/apiAdmin";
3
+ let apiAdmin = admin.apis;
4
+ let axios = null;
5
+
6
+ export default {
7
+ name: "RES_GLOBAL",
8
+
9
+ OBJ_RES: {}, // 系统参数
10
+ ARR_OWN_MENU_OPT: [],
11
+ ARR_OPERATE_ROOT: [],
12
+ ALL_ROLE_ID:[],
13
+ initSuccess:false,
14
+ callBackArr:[], // 回调队列
15
+ install(Vue,opts){
16
+ axios = opts.axios;
17
+ },
18
+
19
+ init(arrResIds) {
20
+ this.ARR_OWN_MENU_OPT = null;
21
+ axios.post(apiAdmin.resources.getResMaps, {ids: arrResIds.join(",")}).then(res => {
22
+ this.OBJ_RES = res.data || {};
23
+ });
24
+ this.initOwnMenuOpt();
25
+ },
26
+
27
+ initOwnMenuOpt() {
28
+ return new Promise(resolve => {
29
+ let loginUser = userGlobal.getLoginUser();
30
+ axios.post(apiAdmin.auth.getOwnMenuOpt, {
31
+ userId: loginUser.id,
32
+ userType: loginUser.userType,
33
+ optType: 'menu'
34
+ }).then(res => {
35
+ this.ALL_ROLE_ID = [];
36
+ (res.data || []).forEach(item => {
37
+ if(this.ALL_ROLE_ID.indexOf(item.roleId) == -1){
38
+ this.ALL_ROLE_ID.push(item.roleId);
39
+ }
40
+ })
41
+ this.ARR_OWN_MENU_OPT = res.data;
42
+ this.initSuccess = true;
43
+ this.callBackArr.forEach(callback => {
44
+ callback && callback(this.ALL_ROLE_ID.join(","));
45
+ })
46
+ resolve(this.ARR_OWN_MENU_OPT);
47
+ })
48
+ });
49
+ },
50
+
51
+ getAllRoleId(callBack){
52
+ if(this.initSuccess){
53
+ callBack && callBack(this.ALL_ROLE_ID.join(","));
54
+ }else{
55
+ this.callBackArr.push(callBack);
56
+ }
57
+ },
58
+
59
+ getUserOwnMenuOpt() {
60
+ return new Promise(resolve => {
61
+ if(this.ARR_OWN_MENU_OPT == null || this.ARR_OWN_MENU_OPT.length == 0){
62
+ this.initOwnMenuOpt().then(data => {
63
+ resolve(this.ARR_OWN_MENU_OPT);
64
+ });
65
+ }else{
66
+ resolve(this.ARR_OWN_MENU_OPT);
67
+ }
68
+ });
69
+ },
70
+
71
+ /**
72
+ * 根据ID获取资源地址
73
+ * @param id
74
+ * @param userType 当前登陆用户类型(开发者用户不走缓存)
75
+ * @returns {*}
76
+ */
77
+ getById(id,userType) {
78
+ return new Promise(resolve => {
79
+ if(!this.OBJ_RES.hasOwnProperty(id)||!this.OBJ_RES[id] || userType == 'sup'){
80
+ axios.post(apiAdmin.resources.findResourcesById, {id: id}).then(res => {
81
+ if(res.data && res.data.operateObj){
82
+ this.OBJ_RES[id] = res.data.operateObj|| {};
83
+ resolve(this.OBJ_RES[id]);
84
+ }
85
+ });
86
+ }else{
87
+ resolve(this.OBJ_RES[id]);
88
+ }
89
+ });
90
+ }
91
+ }