imatrix-ui 2.8.592-dw → 2.9.0-dw-tmp2

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 (46) hide show
  1. package/.babelrc +17 -0
  2. package/build/components.json +4 -0
  3. package/build/gen-style.js +32 -0
  4. package/build/webpack.base.js +140 -0
  5. package/build/webpack.component.js +40 -0
  6. package/build/webpack.prod.js +35 -0
  7. package/lib/DepartmentTree.js +8 -0
  8. package/lib/SuperGrid.js +28 -0
  9. package/lib/super-ui.min.js +72 -0
  10. package/package.json +51 -24
  11. package/src/i18n/langs/cn.js +3 -1
  12. package/src/i18n/langs/en.js +3 -1
  13. package/src/index.js +93 -0
  14. package/src/permission.js +4 -0
  15. package/src/styles/display-layout.scss +34 -0
  16. package/src/styles/index.scss +32 -4
  17. package/src/styles/theme/dark-blue/button.scss +9 -0
  18. package/src/styles/theme/dark-blue/card.scss +64 -0
  19. package/src/styles/theme/dark-blue/checkbox.scss +10 -0
  20. package/src/styles/theme/dark-blue/dark-blue-var.scss +8 -0
  21. package/src/styles/theme/dark-blue/dialog.scss +21 -0
  22. package/src/styles/theme/dark-blue/element-variables.scss +7 -0
  23. package/src/styles/theme/dark-blue/font.scss +71 -0
  24. package/src/styles/theme/dark-blue/form.scss +51 -0
  25. package/src/styles/theme/dark-blue/index.scss +247 -0
  26. package/src/styles/theme/dark-blue/input.scss +15 -0
  27. package/src/styles/theme/dark-blue/pagination.scss +14 -0
  28. package/src/styles/theme/dark-blue/scrollbar-style.scss +32 -0
  29. package/src/styles/theme/dark-blue/sidebar.scss +296 -0
  30. package/src/styles/theme/dark-blue/tab.scss +83 -0
  31. package/src/styles/theme/dark-blue/table.scss +60 -0
  32. package/src/styles/theme/dark-blue/tree.scss +31 -0
  33. package/src/styles/theme/dark-blue/var.scss +1028 -0
  34. package/src/utils/auth-api.js +115 -0
  35. package/src/utils/auth.js +34 -42
  36. package/src/utils/calculator/calculator-factory.js +2 -2
  37. package/src/utils/common-util.js +21 -0
  38. package/src/utils/jump-page-utils.js +28 -5
  39. package/src/utils/request.js +17 -1
  40. package/src/utils/util.js +7 -3
  41. package/src/views/dsc-component/Sidebar/Item.vue +4 -4
  42. package/src/views/dsc-component/Sidebar/SidebarItem.vue +2 -1
  43. package/src/views/dsc-component/Sidebar/index.vue +20 -12
  44. package/src/views/dsc-component/tabs/tab-content.vue +5 -1
  45. package/lib/super-ui.css +0 -1
  46. package/lib/super-ui.umd.min.js +0 -67
@@ -0,0 +1,115 @@
1
+ import Cookies from 'js-cookie'
2
+ import Vue from 'vue'
3
+
4
+ const jwtKey = 'JWT'
5
+ const currentUserNameKey = 'USERNAME'
6
+ const currentUserInfoKey = 'CURRENT_USER'
7
+
8
+ function getToken() {
9
+ let token = getCookieCache(jwtKey)
10
+ const projectModel = Vue.prototype.projectModel
11
+ if (!token && projectModel && projectModel === 'developing.model') {
12
+ // 如果是开发环境从sessionStorage中获得token
13
+ token = getSessionCache(jwtKey)
14
+ }
15
+ return token
16
+ }
17
+
18
+ function setToken(token) {
19
+ setCookieCache(jwtKey, token)
20
+ setSessionCache(jwtKey, token)
21
+ }
22
+
23
+ function removeToken() {
24
+ removeCookieCache(jwtKey)
25
+ removeSessionCache(jwtKey)
26
+ }
27
+
28
+ function getUsername() {
29
+ let username = getCookieCache(currentUserNameKey)
30
+ if (!username) {
31
+ username = getSessionCache(currentUserNameKey)
32
+ }
33
+ return username
34
+ }
35
+
36
+ function setUsername(username) {
37
+ setSessionCache(currentUserNameKey, username)
38
+ setCookieCache(currentUserNameKey, username)
39
+ }
40
+
41
+ function removeUsername() {
42
+ removeSessionCache(currentUserNameKey)
43
+ removeCookieCache(currentUserNameKey)
44
+ }
45
+
46
+ function getCurrentUser() {
47
+ let userJson = getCookieCache(currentUserInfoKey)
48
+ if (!userJson) {
49
+ userJson = getSessionCache(currentUserInfoKey)
50
+ }
51
+ if (userJson) {
52
+ return JSON.parse(userJson)
53
+ }
54
+ }
55
+
56
+ function setCurrentUser(userInfo) {
57
+ if (userInfo) {
58
+ if (userInfo.password) {
59
+ userInfo.password = null
60
+ }
61
+ const userinfoStr = JSON.stringify(userInfo)
62
+ setSessionCache(currentUserInfoKey, userinfoStr)
63
+ setCookieCache(currentUserInfoKey, userinfoStr)
64
+ }
65
+ }
66
+
67
+ function removeCurrentUser() {
68
+ removeSessionCache(currentUserInfoKey)
69
+ removeCookieCache(currentUserInfoKey)
70
+ }
71
+
72
+ function getCookieCache(key) {
73
+ return Cookies.get(key)
74
+ }
75
+
76
+ function setCookieCache(key, value) {
77
+ Cookies.set(key, value, {
78
+ path: '/'
79
+ })
80
+ }
81
+
82
+ function removeCookieCache(key) {
83
+ Cookies.remove(key, {
84
+ path: '/'
85
+ })
86
+ }
87
+
88
+ function getSessionCache(key) {
89
+ return sessionStorage.getItem(key)
90
+ }
91
+
92
+ function setSessionCache(key, value) {
93
+ return sessionStorage.setItem(key, value)
94
+ }
95
+
96
+ function removeSessionCache(key) {
97
+ sessionStorage.removeItem(key)
98
+ }
99
+ export default {
100
+ getToken,
101
+ setToken,
102
+ removeToken,
103
+ getUsername,
104
+ setUsername,
105
+ removeUsername,
106
+ getCurrentUser,
107
+ setCurrentUser,
108
+ removeCurrentUser,
109
+ getCookieCache,
110
+ setCookieCache,
111
+ removeCookieCache,
112
+ getSessionCache,
113
+ setSessionCache,
114
+ removeSessionCache
115
+ }
package/src/utils/auth.js CHANGED
@@ -1,69 +1,61 @@
1
- import sessionStorage from 'sessionstorage'
2
- import Cookies from 'js-cookie'
3
- import Vue from 'vue'
4
-
5
- const jwtKey = 'JWT'
6
- const currentUserNameKey = 'USERNAME'
7
- const currentUserInfoKey = 'CURRENT_USER'
1
+ import authApi from './auth-api'
8
2
 
9
3
  export function getToken() {
10
- let jwt = sessionStorage.getItem(jwtKey)
11
- // console.log('auth-sessionStorage.getToken=', jwt)
12
- if (!jwt) {
13
- jwt = Cookies.get(jwtKey)
14
- // console.log('auth-Cookies.getToken=', jwt)
15
- }
16
- return jwt
4
+ return authApi.getToken()
17
5
  }
18
6
 
19
7
  export function setToken(token) {
20
- if (Vue.prototype.projectModel && Vue.prototype.projectModel === 'developing.model') {
21
- // 如果是开发模式,需要设置cookie。不设置expires,就是session cookie,表示关闭浏览器,cookie即失效
22
- // console.log('auth-Cookies.setToken=', token)
23
- // 必须是“/”否则无法移除token
24
- Cookies.set(jwtKey, token, { path: '/' })
25
- } else {
26
- // console.log('auth-sessionStorage.setToken=', token)
27
- return sessionStorage.setItem(jwtKey, token)
28
- }
8
+ authApi.setToken(token)
29
9
  }
30
10
 
31
11
  export function removeToken() {
32
- sessionStorage.removeItem(jwtKey)
33
- // console.log('auth-sessionStorage.removeToken=', getToken())
34
- // 必须和setToken中的path“/”一致,否则无法移除token
35
- Cookies.remove(jwtKey, { path: '/' })
36
- // console.log('auth-Cookies.removeToken=', getToken())
12
+ authApi.removeToken()
37
13
  }
38
14
 
39
15
  export function getUsername() {
40
- return sessionStorage.getItem(currentUserNameKey)
16
+ return authApi.getUsername()
41
17
  }
42
18
 
43
19
  export function setUsername(username) {
44
- sessionStorage.setItem(currentUserNameKey, username)
20
+ authApi.setUsername(username)
45
21
  }
46
22
 
47
23
  export function removeUsername() {
48
- sessionStorage.removeItem(currentUserNameKey)
24
+ authApi.removeUsername()
49
25
  }
50
26
 
51
27
  export function getCurrentUser() {
52
- const userJson = sessionStorage.getItem(currentUserInfoKey)
53
- if (userJson) {
54
- return JSON.parse(userJson)
55
- }
28
+ return authApi.getCurrentUser()
56
29
  }
57
30
 
58
31
  export function setCurrentUser(userInfo) {
59
- if (userInfo) {
60
- if (userInfo.password) {
61
- userInfo.password = null
62
- }
63
- sessionStorage.setItem(currentUserInfoKey, JSON.stringify(userInfo))
64
- }
32
+ authApi.setCurrentUser(userInfo)
65
33
  }
66
34
 
67
35
  export function removeCurrentUser() {
68
- sessionStorage.removeItem(currentUserInfoKey)
36
+ authApi.removeCurrentUser()
37
+ }
38
+
39
+ export function getCookieCache(key) {
40
+ return authApi.getCookieCache(key)
41
+ }
42
+
43
+ export function setCookieCache(key, value) {
44
+ authApi.setCookieCache(key, value)
45
+ }
46
+
47
+ export function removeCookieCache(key) {
48
+ authApi.removeCookieCache(key)
49
+ }
50
+
51
+ export function getSessionCache(key) {
52
+ return authApi.getSessionCache(key)
53
+ }
54
+
55
+ export function setSessionCache(key, value) {
56
+ return authApi.setSessionCache(key, value)
57
+ }
58
+
59
+ export function removeSessionCache(key) {
60
+ authApi.removeSessionCache(key)
69
61
  }
@@ -45,7 +45,7 @@ class NumberCalculator extends CalculatorFactory {
45
45
  this.result = true
46
46
  } else if (this.isEQEmptyValue(leftVale, operator, rightValue)) {
47
47
  this.result = true
48
- } else if (leftVale === null) {
48
+ } else if (leftVale === undefined || leftVale === null) {
49
49
  this.result = false
50
50
  } else {
51
51
  const preOperand = Number(leftVale + '')
@@ -81,7 +81,7 @@ class TextCalculator extends CalculatorFactory {
81
81
  this.result = true
82
82
  } else if (this.isNotNullValue(leftVale, operator)) {
83
83
  this.result = true
84
- } else if (leftVale === null) {
84
+ } else if (leftVale === undefined || leftVale === null) {
85
85
  this.result = false
86
86
  } else {
87
87
  if (operator === 'NET') {
@@ -202,3 +202,24 @@ export function getOrignUrl() {
202
202
  }
203
203
  return orignUrl
204
204
  }
205
+
206
+ export function isPromise(p) {
207
+ return p && Object.prototype.toString.call(p) === '[object Promise]'
208
+ }
209
+ /**
210
+ * 获得UTC时区
211
+ * @returns 时区
212
+ */
213
+ export function getTimeZone() {
214
+ const dateStr = new Date() + ''
215
+ let timeZone = ''
216
+ if (dateStr.indexOf('GMT') > 0) {
217
+ const timeZoneSuffix = dateStr.substring(dateStr.indexOf('GMT') + 3, dateStr.indexOf('(')).trim()
218
+ const partPrefix = timeZoneSuffix.substring(0, timeZoneSuffix.length - 2)
219
+ const partSuffix = timeZoneSuffix.substring(timeZoneSuffix.length - 2)
220
+ timeZone = 'UTC' + partPrefix + ':' + partSuffix
221
+ } else if (dateStr.indexOf('UTC') > 0) {
222
+ timeZone = 'UTC' + dateStr.substring(dateStr.indexOf('UTC') + 3, dateStr.indexOf('(')).trim()
223
+ }
224
+ return timeZone
225
+ }
@@ -243,7 +243,8 @@ function jumpToPageTwo(jumpPageSetting, system, dataId, ids, buttonCode, isHasId
243
243
  const frontendUrl = getSystemFrontendUrl(system.frontendUrl)
244
244
  path = frontendUrl + '/#' + path
245
245
  }
246
- jumpToPageWithFullPath(dataId, path, additionalParameterStr, jumpPageSetting, ids, buttonCode, isHasIdParam)
246
+ const systemName = getSystemNameWithLanguage(system)
247
+ jumpToPageWithFullPath(dataId, path, additionalParameterStr, jumpPageSetting, ids, buttonCode, isHasIdParam, systemName)
247
248
  resolve()
248
249
  }
249
250
  })
@@ -255,16 +256,20 @@ function jumpToPageTwo(jumpPageSetting, system, dataId, ids, buttonCode, isHasId
255
256
  * @param {*} additionalParameterStr
256
257
  * @param {*} jumpPage
257
258
  */
258
- function jumpToPageWithFullPath(dataId, path, additionalParameterStr, jumpPage, ids, buttonCode, isHasIdParam) {
259
+ function jumpToPageWithFullPath(dataId, path, additionalParameterStr, jumpPage, ids, buttonCode, isHasIdParam, systemName) {
259
260
  path = packagePathParams(dataId, path, jumpPage, ids, buttonCode, isHasIdParam)
260
261
  // 保持这种情况参数传递,是为了解决不同域时获得不到sessionStorage中存的附加参数问题
261
262
  if (additionalParameterStr && additionalParameterStr !== '') {
263
+ let systemNameParam = ''
264
+ if (systemName) {
265
+ systemNameParam = '&_systemName_=' + encodeURI(systemName)
266
+ }
262
267
  if (path.indexOf('?') !== -1) {
263
268
  path += '&'
264
- path += additionalParameterStr
269
+ path += additionalParameterStr + systemNameParam
265
270
  } else {
266
271
  path += '?'
267
- path += additionalParameterStr
272
+ path += additionalParameterStr + systemNameParam
268
273
  }
269
274
  }
270
275
  let jumpMode = 'refresh'
@@ -448,10 +453,28 @@ function openDialogWhenPopup(jumpPageSetting, system, pageCode, dataId, jumpMode
448
453
 
449
454
  function packageOpenUrl(system, pageCode, dataId, jumpPageSetting, jumpMode, ids, buttonCode, isHasIdParam) {
450
455
  const frontendUrl = getSystemFrontendUrl(system.frontendUrl)
451
- const path = frontendUrl + '/#/dsc-full-screen/page?customSystem=' + system.code + '&pageCode=' + pageCode + '&jumpMode=' + jumpMode
456
+ let path = frontendUrl + '/#/dsc-full-screen/page?customSystem=' + system.code + '&pageCode=' + pageCode + '&jumpMode=' + jumpMode
457
+ const systemName = getSystemNameWithLanguage(system)
458
+ if (systemName) {
459
+ path += '&_systemName_=' + encodeURI(systemName)
460
+ }
452
461
  return packagePathParams(dataId, path, jumpPageSetting, ids, buttonCode, isHasIdParam)
453
462
  }
454
463
 
464
+ function getSystemNameWithLanguage(system) {
465
+ if (system) {
466
+ let locale = 'cn'
467
+ if (window.$locale) {
468
+ locale = window.$locale
469
+ }
470
+ if (locale === 'cn') {
471
+ return system.name
472
+ } else {
473
+ return system.enName
474
+ }
475
+ }
476
+ }
477
+
455
478
  // 解析跳转页面附带参数
456
479
  function analysisAdditionalParameter(paramStoreId) {
457
480
  const additionalParamMap = sessionStorage.getItem(paramStoreId)
@@ -13,7 +13,8 @@ import {
13
13
  getI18n
14
14
  } from './util'
15
15
  import {
16
- getRelativeBaseUrl
16
+ getRelativeBaseUrl,
17
+ getTimeZone
17
18
  } from './common-util'
18
19
  // 创建axios实例
19
20
  const service = axios.create({
@@ -27,6 +28,8 @@ service.interceptors.request.use(
27
28
  config => {
28
29
  // 防止重复发送ajax请求
29
30
  store.commit('togglePreventReclick', true)
31
+ const timeZone = getTimeZone()
32
+ config.headers['timeZone'] = timeZone
30
33
  const token = getToken()
31
34
  if (token) {
32
35
  config.headers['Authorization'] = token // 让每个请求携带自定义token 请根据实际情况自行修改
@@ -112,6 +115,10 @@ service.interceptors.response.use(
112
115
  }
113
116
  console.log(message)
114
117
  let errorMsg = getI18n().t('imatrixUIMessage.internalServerError')
118
+ if (message && message !== 'Internal Server Error') {
119
+ // 表示显示原始异常
120
+ errorMsg = message
121
+ }
115
122
  if (message && (message === 'gateway.timeout' || message === 'gateway.callFailed')) {
116
123
  // 网关的fallback返回的异常信息“接口调用超时”、“接口调用失败”
117
124
  errorMsg = getI18n().t(message)
@@ -124,6 +131,15 @@ service.interceptors.response.use(
124
131
  })
125
132
  return Promise.reject(error)
126
133
  }
134
+ } else {
135
+ const errorMsg = getI18n().t('imatrixUIMessage.internalServerError')
136
+ Message({
137
+ showClose: true,
138
+ message: errorMsg,
139
+ type: 'error',
140
+ duration: 5 * 1000
141
+ })
142
+ return Promise.reject(error)
127
143
  }
128
144
  }
129
145
  )
package/src/utils/util.js CHANGED
@@ -218,7 +218,7 @@ function parseCondition(entity, conditionList, isSql, tableName, additionalParam
218
218
  }
219
219
  }
220
220
  conditions += conditionResult + ' '
221
- if (leftBracket && leftBracket !== null && leftBracket !== '') {
221
+ if (rightBracket && rightBracket !== null && rightBracket !== '') {
222
222
  conditions = conditions + rightBracket
223
223
  conditions = conditions + (' ')
224
224
  // conditions.append(rightBracket).append(' ')
@@ -237,8 +237,12 @@ function parseCondition(entity, conditionList, isSql, tableName, additionalParam
237
237
  }
238
238
  }
239
239
  console.log('parseCondition----conditions=', conditions)
240
- // eslint-disable-next-line no-eval
241
- return eval('(' + conditions + ')')
240
+ if (conditions) {
241
+ // eslint-disable-next-line no-eval
242
+ return eval('(' + conditions + ')')
243
+ } else {
244
+ return true
245
+ }
242
246
  }
243
247
  const REPLACE_DOT = '__'
244
248
 
@@ -29,13 +29,13 @@ export default {
29
29
  if (icon.indexOf('fa-') === 0) {
30
30
  // 表示以“fa-”开头,使用font-awesome中的图标
31
31
  icon = 'fa ' + icon
32
- vnodes.push(<div style='display: inline-block;'><i class={icon}/></div>)
32
+ vnodes.push(<div style='display: inline-block;overflow:hidden;'><i class={icon}/></div>)
33
33
  } else if (icon.indexOf('svg-') === 0) {
34
34
  icon = icon.substring(icon.indexOf('svg-') + 4)
35
- vnodes.push(<div style='display: inline-block;'><svg-icon icon-class={icon}/></div>)
35
+ vnodes.push(<div style='display: inline-block;overflow:hidden;'><svg-icon icon-class={icon}/></div>)
36
36
  } else {
37
37
  icon += ' svg-icon'
38
- vnodes.push(<div style='display: inline-block;'><i class={icon}/></div>)
38
+ vnodes.push(<div style='display: inline-block;overflow:hidden;'><i class={icon}/></div>)
39
39
  }
40
40
  }
41
41
 
@@ -52,7 +52,7 @@ export default {
52
52
  </div>)
53
53
  } else {
54
54
  // 有子菜单时
55
- vnodes.push(<div slot='title' style='display: inline-block'>
55
+ vnodes.push(<div v-slot:title style='display: inline-block'>
56
56
  <div title={title} style={'display: inline-block;width:' + width + ';overflow:hidden;text-overflow:ellipsis;white-space:nowrap;word-break:keep-all;'}>{(title)}</div>
57
57
  </div>)
58
58
  }
@@ -9,7 +9,7 @@
9
9
  </template>
10
10
 
11
11
  <el-submenu v-else :index="resolvePath(item.code,item.path,item.pageType)" :show-timeout="0" :hide-timeout="50" popper-class="sidebar-container-popper">
12
- <template slot="title">
12
+ <template v-slot:title>
13
13
  <item :icon="item.iconName" :title="getI18nName(item)" :has-children="item.children.length > 0?true:false" />
14
14
  </template>
15
15
 
@@ -38,6 +38,7 @@ import AppLink from './Link'
38
38
  import Vue from 'vue'
39
39
  import tabJs from '../../../api/tab'
40
40
  import { getI18nName } from '../../../utils/menu'
41
+ // import { SidebarItemChild } from './SidebarItemChild.vue'
41
42
  export default {
42
43
  name: 'SidebarItem',
43
44
  components: { Item, AppLink },
@@ -1,15 +1,17 @@
1
1
  <template>
2
2
  <div>
3
3
  <el-scrollbar wrap-class="scrollbar-wrapper">
4
- <el-menu
5
- :show-timeout="200"
6
- :default-active="getDefaultActive()"
7
- :collapse="isCollapse"
8
- mode="vertical"
9
- @select="selectMenu"
10
- >
11
- <sidebar-item v-for="menu in menus" :key="menu.code" :item="menu" />
12
- </el-menu>
4
+ <keep-alive>
5
+ <el-menu
6
+ :show-timeout="200"
7
+ :default-active="getDefaultActive()"
8
+ :collapse="isCollapse"
9
+ mode="vertical"
10
+ @select="selectMenu"
11
+ >
12
+ <sidebar-item v-for="menu in menus" :key="menu.code" :item="menu" />
13
+ </el-menu>
14
+ </keep-alive>
13
15
  </el-scrollbar>
14
16
  <hamburger :is-active="sidebar.opened" class="hamburger-container" @toggleClick="toggleSideBar" />
15
17
  </div>
@@ -40,7 +42,7 @@ export default {
40
42
  data() {
41
43
  const menus = getMenus()
42
44
  return {
43
- menus
45
+ menus: Object.freeze(menus)
44
46
  }
45
47
  },
46
48
  computed: {
@@ -55,13 +57,14 @@ export default {
55
57
  }
56
58
  },
57
59
  created() {
60
+ const a = new Date().getTime()
58
61
  this.firstLeafMenu = this.getMyFirstMenu(this.menus)
59
62
  if (this.firstLeafMenu && this.firstLeafMenu.fullPath) {
60
63
  // 跳转到第一个页面
61
64
  if (this.firstLeafMenu.pageType && this.firstLeafMenu.pageType === 'iframe') {
62
65
  const iframeSrc = this.firstLeafMenu.fullPath
63
- const pageCode = this.firstLeafMenu.path
64
- const query = { src: iframeSrc, customSystem: this.systemCode, pageCode: pageCode, _menuCode: this.firstLeafMenu.code, _menuName: getI18nName(this.firstLeafMenu) }
66
+ const path = this.firstLeafMenu.path
67
+ const query = { src: iframeSrc, customSystem: this.systemCode, path: path, _menuCode: this.firstLeafMenu.code, _menuName: getI18nName(this.firstLeafMenu) }
65
68
  this.addTabs(query, this.$store.state.tabContent.openTab, '/dsc/iframe-page', '/dsc/iframe-page')
66
69
  this.$router.push({ path: '/dsc-index/iframe-page', query: query })
67
70
  } else {
@@ -71,6 +74,8 @@ export default {
71
74
  this.$router.push({ path: '/dsc-index/page', query: query })
72
75
  // this.$router.push({ path: this.firstLeafMenu.fullPath })
73
76
  }
77
+ const b = new Date().getTime()
78
+ console.log('菜单组件==>created==>b-a', (b - a))
74
79
  }
75
80
  },
76
81
  methods: {
@@ -92,11 +97,14 @@ export default {
92
97
  Cookies.set('selectMenu', index)
93
98
  },
94
99
  getMyFirstMenu(menus) {
100
+ const a = new Date().getTime()
95
101
  if (menus && menus.length > 0) {
96
102
  let shouldSelectMenu = this.getFirstMenu(menus)
97
103
  if (!shouldSelectMenu) {
98
104
  shouldSelectMenu = this.getFirstMenuWithCookie(menus)
99
105
  }
106
+ const b = new Date().getTime()
107
+ console.log('菜单组件==>getMyFirstMenu==>b-a', (b - a))
100
108
  // 默认不展示第一个有权限的菜单了,可以去掉下面的代码
101
109
  // if (!shouldSelectMenu) {
102
110
  // shouldSelectMenu = this.getSelectMenuWithFirstMenu(menus[0])
@@ -98,7 +98,11 @@ export default {
98
98
  path = src
99
99
  }
100
100
  if (params) {
101
- path += '?' + params
101
+ if (path && path.indexOf('?') > 0) {
102
+ path += '&' + params
103
+ } else {
104
+ path += '?' + params
105
+ }
102
106
  }
103
107
  } else {
104
108
  // 表示页面跳转
package/lib/super-ui.css DELETED
@@ -1 +0,0 @@
1
- .app-breadcrumb.el-breadcrumb[data-v-7da23860]{display:inline-block;font-size:14px;line-height:50px;margin-left:10px}.app-breadcrumb.el-breadcrumb .no-redirect[data-v-7da23860]{color:#97a8be;cursor:text}.hamburger[data-v-79c757aa]{display:inline-block;cursor:pointer;width:14px;height:14px;-webkit-transform:rotate(90deg);transform:rotate(90deg);-webkit-transition:.38s;transition:.38s;-webkit-transform-origin:50% 50%;transform-origin:50% 50%}.hamburger.is-active[data-v-79c757aa]{-webkit-transform:rotate(0deg);transform:rotate(0deg)}.svg-icon[data-v-de244482]{width:1.2em;height:1.2em;vertical-align:-.25em;fill:currentColor;overflow:hidden}.select-top-span{width:100%}.annex-cell[data-v-ae584d44]{padding-right:5px;cursor:pointer;color:#409eff}.grid-search-row[data-v-44ee7f15]{overflow:auto;max-height:320px}.grid-search-form[data-v-f1fa8e36]{overflow:auto}.grid-search-form[data-v-f1fa8e36] .el-form-item{margin-bottom:0}.grid-search-form[data-v-f1fa8e36] .el-form-item__label{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;word-break:keep-all}.grid-search-form[data-v-f1fa8e36] .search-btn{margin-bottom:5px;text-align:center}.grid-search-form[data-v-f1fa8e36] .customComponent,.grid-search-form[data-v-f1fa8e36] .el-select{width:100%}.grid-search-form[data-v-f1fa8e36] .el-row{padding-right:24px}.grid-search-form[data-v-f1fa8e36] .el-col{padding-left:24px;padding-bottom:16px}.grid-search-form[data-v-5d0844ee]{overflow:auto}.grid-search-form[data-v-5d0844ee] .el-form-item{margin-bottom:0}.grid-search-form[data-v-5d0844ee] .search-btn{margin-bottom:5px;text-align:center}.grid-search-form[data-v-5d0844ee] .customComponent,.grid-search-form[data-v-5d0844ee] .el-select{width:100%}li[data-v-19919133]{color:#333}.context-menu[data-v-19919133]{position:fixed;background:#fff;z-index:999;padding:5px;margin:0;margin-top:30px}.context-menu li[data-v-19919133]{min-width:75px;height:28px;line-height:28px;text-align:left;color:#1a1a1a}.context-menu li[data-v-19919133]:hover{background:#42b983;color:#fff}.context-menu[data-v-19919133]{border:1px solid #eee;-webkit-box-shadow:0 .5em 1em 0 rgba(0,0,0,.1);box-shadow:0 .5em 1em 0 rgba(0,0,0,.1);border-radius:5px}li[data-v-19919133]{list-style-type:none}#nprogress{pointer-events:none}#nprogress .bar{background:#29d;position:fixed;z-index:1031;top:0;left:0;width:100%;height:2px}#nprogress .peg{display:block;position:absolute;right:0;width:100px;height:100%;-webkit-box-shadow:0 0 10px #29d,0 0 5px #29d;box-shadow:0 0 10px #29d,0 0 5px #29d;opacity:1;-webkit-transform:rotate(3deg) translateY(-4px);transform:rotate(3deg) translateY(-4px)}#nprogress .spinner{display:block;position:fixed;z-index:1031;top:15px;right:15px}#nprogress .spinner-icon{width:18px;height:18px;-webkit-box-sizing:border-box;box-sizing:border-box;border:2px solid transparent;border-top-color:#29d;border-left-color:#29d;border-radius:50%;-webkit-animation:nprogress-spinner .4s linear infinite;animation:nprogress-spinner .4s linear infinite}.nprogress-custom-parent{overflow:hidden;position:relative}.nprogress-custom-parent #nprogress .bar,.nprogress-custom-parent #nprogress .spinner{position:absolute}@-webkit-keyframes nprogress-spinner{0%{-webkit-transform:rotate(0deg)}to{-webkit-transform:rotate(1turn)}}@keyframes nprogress-spinner{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(1turn);transform:rotate(1turn)}}.grid-area .elTable td[data-v-1d751446],.grid-area .elTable th[data-v-1d751446]{padding:2px 0!important}.inline-select-custom{width:100px}.inline-input-custom{width:98%}.searchResult{color:red}.inline-input-custom{width:90%}.ValidCode[data-v-0e45e064]{display:-webkit-box;display:-ms-flexbox;display:flex;background-color:#fff;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;cursor:pointer}.ValidCode span[data-v-0e45e064]{display:inline-block}.grid-search-form[data-v-398b171b]{overflow:auto}.grid-search-form[data-v-398b171b] .el-form-item{margin-bottom:0}.grid-search-form[data-v-398b171b] .search-btn{margin-bottom:5px;text-align:center}.grid-search-form[data-v-398b171b] .customComponent,.grid-search-form[data-v-398b171b] .el-select{width:100%}.nine-grid-area[data-v-4d6cc5f7]{padding:10px}.nine-grid-area .el-row[data-v-4d6cc5f7]{margin-bottom:20px}.nine-grid-area .el-row[data-v-4d6cc5f7]:last-child{margin-bottom:0}.nine-grid-area .el-col[data-v-4d6cc5f7]{border-radius:4px;margin-bottom:10px}.nine-grid-area .name[data-v-4d6cc5f7]{font-size:12px;color:#555;float:left;width:80%;text-align:left}.nine-grid-area .bottom[data-v-4d6cc5f7]{line-height:13px}.nine-grid-area .state[data-v-4d6cc5f7]{font-size:12px;margin-top:1.5px;float:right;line-height:1;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:right;-ms-flex-align:right;align-items:right;color:#999;width:20%;text-align:right}.nine-grid-area .image[data-v-4d6cc5f7]{width:100%;display:block;height:200px}.nine-grid-area .clearfix[data-v-4d6cc5f7]:after,.nine-grid-area .clearfix[data-v-4d6cc5f7]:before{display:table;content:""}.nine-grid-area .clearfix[data-v-4d6cc5f7]:after{clear:both}.nine-grid-area .input-with-select[data-v-4d6cc5f7]{width:200px;float:right}.nine-grid-area .popContainer[data-v-4d6cc5f7]{position:absolute;width:23.15%;display:block;height:200px;background:rgba(0,0,0,.5);text-align:right}.nine-grid-area .fade-enter-active[data-v-4d6cc5f7],.nine-grid-area .fade-leave-active[data-v-4d6cc5f7]{-webkit-transition:opacity .5s;transition:opacity .5s}.nine-grid-area .fade-enter[data-v-4d6cc5f7],.nine-grid-area .fade-leave-to[data-v-4d6cc5f7]{opacity:0}.nine-grid-area .icons[data-v-4d6cc5f7]{color:#fff;margin:10px 10px 0 0;cursor:pointer}.nine-grid-area .release-status[data-v-4d6cc5f7]{display:block;width:8px;height:8px;margin-right:8px;border-radius:100%}.nine-grid-area .add-screen[data-v-4d6cc5f7]{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;cursor:pointer;height:230px;font-size:12px}.nine-grid-area .el-divider--horizontal[data-v-4d6cc5f7]{margin:5px 0}