imatrix-ui 2.9.59-dw → 2.9.61-dw
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/package.json
CHANGED
|
@@ -233,11 +233,32 @@ function exportListData(excelName, listCode, data, functionCode, uuid, isAsync,
|
|
|
233
233
|
param['isPermission'] = isPermission
|
|
234
234
|
Vue.prototype.$http.post(Vue.prototype.baseURL + '/dsc/commons/export-list-data', param).then(data => {
|
|
235
235
|
if (isAsync) {
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
236
|
+
const message = getI18n().t('imatrixUIMessage.asyncExport')
|
|
237
|
+
const exportPageUrl = getDcExportPageUrl()
|
|
238
|
+
let vnode
|
|
239
|
+
if (exportPageUrl) {
|
|
240
|
+
vnode = '<p><span>' + message + '</span>'
|
|
241
|
+
// 请点击进行权限申请
|
|
242
|
+
const asyncExportJumpMsg = getI18n().t('imatrixUIMessage.asyncExportJumpMsg')
|
|
243
|
+
vnode += '<a href="#" style="color: #1800ff;font-weight: bold;text-decoration:underline" onclick="window.open(\'' + exportPageUrl + '\')">' + asyncExportJumpMsg + '</a>'
|
|
244
|
+
vnode += '</p>'
|
|
245
|
+
}
|
|
246
|
+
if (vnode) {
|
|
247
|
+
Message({
|
|
248
|
+
showClose: true,
|
|
249
|
+
dangerouslyUseHTMLString: true,
|
|
250
|
+
message: vnode,
|
|
251
|
+
type: 'success',
|
|
252
|
+
duration: 10 * 1000
|
|
253
|
+
})
|
|
254
|
+
} else {
|
|
255
|
+
Message({
|
|
256
|
+
showClose: true,
|
|
257
|
+
message: message,
|
|
258
|
+
type: 'success',
|
|
259
|
+
duration: 5 * 1000
|
|
260
|
+
})
|
|
261
|
+
}
|
|
241
262
|
localStorage.setItem(uuid, 'ok')
|
|
242
263
|
} else {
|
|
243
264
|
if (data.indexOf('~~') >= 0) {
|
|
@@ -258,6 +279,18 @@ function exportListData(excelName, listCode, data, functionCode, uuid, isAsync,
|
|
|
258
279
|
}
|
|
259
280
|
})
|
|
260
281
|
}
|
|
282
|
+
// 获得文件中心/导出任务菜单的路由地址
|
|
283
|
+
function getDcExportPageUrl() {
|
|
284
|
+
let exportPageUrl
|
|
285
|
+
const baseAPI = Vue.prototype.baseAPI
|
|
286
|
+
if (baseAPI) {
|
|
287
|
+
// 获得平台的域名和端口
|
|
288
|
+
const baseUrls = baseAPI.split('/')
|
|
289
|
+
const baseUrlPrefix = baseUrls[0] + '//' + baseUrls[2]
|
|
290
|
+
exportPageUrl = baseUrlPrefix + '/document-center/#/file-task/file-export-task/list'
|
|
291
|
+
}
|
|
292
|
+
return exportPageUrl
|
|
293
|
+
}
|
|
261
294
|
/**
|
|
262
295
|
* 根据uuid获取导出情况
|
|
263
296
|
* @param {*} uuid
|
package/src/i18n/langs/cn.js
CHANGED
|
@@ -77,7 +77,8 @@ const cn = {
|
|
|
77
77
|
asyncExport: '正在异步导出,请等待消息通知!',
|
|
78
78
|
selectedWorkingGroup: '已选工作组',
|
|
79
79
|
forbiddenExceptionLinkUrl: '请点击进行权限申请',
|
|
80
|
-
forbiddenExceptionLinkUser: '如有疑问请联系'
|
|
80
|
+
forbiddenExceptionLinkUser: '如有疑问请联系',
|
|
81
|
+
asyncExportJumpMsg: '或点击我跳转到下载页面'
|
|
81
82
|
},
|
|
82
83
|
// 列表组件
|
|
83
84
|
superGrid: {
|
package/src/i18n/langs/en.js
CHANGED
|
@@ -77,7 +77,8 @@ const en = {
|
|
|
77
77
|
asyncExport: 'Asynchronous export, please wait for message notification!',
|
|
78
78
|
selectedWorkingGroup: 'Selected working group',
|
|
79
79
|
forbiddenExceptionLinkUrl: 'please click to apply',
|
|
80
|
-
forbiddenExceptionLinkUser: 'if you have any questions,please contact'
|
|
80
|
+
forbiddenExceptionLinkUser: 'if you have any questions,please contact',
|
|
81
|
+
asyncExportJumpMsg: 'Or click me to jump to download page.'
|
|
81
82
|
},
|
|
82
83
|
superGrid: {
|
|
83
84
|
columnConfig: 'Column Config',
|
package/src/utils/common-util.js
CHANGED
|
@@ -104,22 +104,43 @@ export function getLoginUrl() {
|
|
|
104
104
|
let systemPath = href
|
|
105
105
|
let routerPath = ''
|
|
106
106
|
let param = ''
|
|
107
|
+
console.log('getLoginUrl---href=', href)
|
|
107
108
|
if (href.indexOf('#/') > 0 && href.indexOf('#/login') < 0) {
|
|
108
109
|
systemPath = href.substring(0, href.indexOf('#'))
|
|
109
110
|
const suffix = href.substring(href.indexOf('#') + 1)
|
|
111
|
+
console.log('getLoginUrl---suffix=', suffix)
|
|
110
112
|
routerPath = suffix
|
|
111
113
|
if (suffix.indexOf('?') > 0) {
|
|
112
114
|
// 如果包含参数,则需要截取参数
|
|
113
115
|
routerPath = suffix.substring(0, suffix.indexOf('?'))
|
|
114
116
|
param = suffix.substring(suffix.indexOf('?') + 1)
|
|
115
117
|
}
|
|
118
|
+
} else {
|
|
119
|
+
systemPath = null
|
|
116
120
|
}
|
|
121
|
+
console.log('getLoginUrl---param=', param)
|
|
117
122
|
getPortalFrontendUrl().then(portalUrl => {
|
|
118
|
-
let loginUrl = portalUrl + '#/login
|
|
123
|
+
let loginUrl = portalUrl + '#/login'
|
|
124
|
+
if (systemPath) {
|
|
125
|
+
loginUrl = loginUrl + '?systemPath=' + systemPath
|
|
126
|
+
}
|
|
127
|
+
if (routerPath) {
|
|
128
|
+
if (loginUrl.indexOf('?') > 0) {
|
|
129
|
+
loginUrl = loginUrl + '&routerPath=' + routerPath
|
|
130
|
+
} else {
|
|
131
|
+
loginUrl = loginUrl + '?routerPath=' + routerPath
|
|
132
|
+
}
|
|
133
|
+
}
|
|
119
134
|
if (param) {
|
|
120
|
-
loginUrl
|
|
135
|
+
if (loginUrl.indexOf('?') > 0) {
|
|
136
|
+
loginUrl = loginUrl + '&' + param
|
|
137
|
+
} else {
|
|
138
|
+
loginUrl = loginUrl + '?' + param
|
|
139
|
+
}
|
|
121
140
|
}
|
|
141
|
+
console.log('getLoginUrl---loginUrl11=', loginUrl)
|
|
122
142
|
loginUrl = replacePrefix(loginUrl)
|
|
143
|
+
console.log('getLoginUrl---loginUr222=', loginUrl)
|
|
123
144
|
resolve(loginUrl)
|
|
124
145
|
}).catch(error => {
|
|
125
146
|
reject(error)
|
|
@@ -335,14 +356,3 @@ export function cacheCurrentLanguageUtil(http) {
|
|
|
335
356
|
}
|
|
336
357
|
})
|
|
337
358
|
}
|
|
338
|
-
|
|
339
|
-
// 刷新浏览器页面
|
|
340
|
-
export function refreshLocationHref(url, locationObj) {
|
|
341
|
-
if (!locationObj) {
|
|
342
|
-
locationObj = window.location
|
|
343
|
-
}
|
|
344
|
-
if (!url) {
|
|
345
|
-
return
|
|
346
|
-
}
|
|
347
|
-
locationObj.href = url
|
|
348
|
-
}
|