yuang-framework-ui-common 1.0.48 → 1.0.49

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.
@@ -66,8 +66,9 @@ http.interceptors.response.use(async (res: any) => {
66
66
  return Promise.reject(new Error(res?.data?.message));
67
67
  } else if (res?.data?.statusCode === 500822001) {
68
68
  clearGatewayConfig();
69
- window.location.reload();
70
- return Promise.reject(new Error(res?.data?.message));
69
+ await initGatewayConfig();
70
+ // 重发请求
71
+ return axios.request(res.config);
71
72
  } else if (res?.data?.statusCode === 500815001) {
72
73
  showErrorMessage(res?.data?.message || messageMap.requestError);
73
74
  clearSsoAccessToken();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "yuang-framework-ui-common",
3
- "version": "1.0.48",
3
+ "version": "1.0.49",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "scripts": {
@@ -26,10 +26,9 @@ const router = createRouter({
26
26
  path: '/config/gateway-config',
27
27
  component: () => import('@/views/config/gateway-config.vue')
28
28
  },
29
-
30
29
  {
31
30
  path: '/utils/aes-utils',
32
- component: () => import('@/views/utils/aes-utils.vue')
31
+ component: () => import('@/views/utils/aes-utils.vue'),
33
32
  },
34
33
  {
35
34
  path: '/utils/rsa-utils',
@@ -43,8 +42,13 @@ const router = createRouter({
43
42
  path: '/utils/message-utils',
44
43
  component: () => import('@/views/utils/message-utils.vue')
45
44
  },
46
-
47
-
45
+ {
46
+ path: '/utils/gateway-utils',
47
+ component: () => import('@/views/utils/gateway-utils.vue'),
48
+ meta: {
49
+ isSsoExcluded: true
50
+ }
51
+ },
48
52
 
49
53
  {
50
54
  path: '/example/table/index',
@@ -0,0 +1,21 @@
1
+ <template>
2
+ <div>
3
+ <el-button @click="sendRequest">发送请求</el-button>
4
+ </div>
5
+ </template>
6
+
7
+ <script setup lang="ts">
8
+ import { http } from "../../../lib/config/httpConfig";
9
+ import { ElMessage } from 'element-plus/es';
10
+
11
+ const sendRequest = () => {
12
+ // 测试
13
+ http.get("/sso-api/standard/framework-captcha/getSliderCaptcha", { params: {} }).then((res) => {
14
+ ElMessage.success('发送成功');
15
+ });
16
+ }
17
+ </script>
18
+
19
+ <style scoped>
20
+
21
+ </style>