udxcms 1.0.37 → 1.0.38

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.
@@ -1,7 +1,7 @@
1
1
  <!--
2
2
  * @Author:
3
3
  * @Date: 2020-11-19 12:38:02
4
- * @LastEditTime: 2025-10-30 21:49:14
4
+ * @LastEditTime: 2025-11-04 11:41:25
5
5
  * @LastEditors: lewis lewis@everylink.ai
6
6
  * @Description:
7
7
  -->
@@ -133,7 +133,7 @@
133
133
  watch: {
134
134
  currencyList: {
135
135
  handler(newVal, oldVal) {
136
- console.log('currencyList watch - new:', newVal, 'old:', oldVal)
136
+ console.log('currencyList watch - new:', newVal, 'old:', oldVal, this.store.state.storeType)
137
137
  },
138
138
  immediate: true,
139
139
  deep: true
@@ -153,8 +153,6 @@ export default {
153
153
  localStorage.removeItem('selectedWallet')
154
154
  localStorage.removeItem('selectedIcon')
155
155
  }
156
- // TODO: 需要删除下一行,业务逻辑应该移到组件之外,历史原因目前阶段临时保留。
157
- this.$store.commit("setDefaultChainId", item.chainId);
158
156
  this.chainId = item.chainId;
159
157
  this.$emit("change", this.chainId);
160
158
  }
@@ -4,7 +4,7 @@
4
4
  * @Author:
5
5
  * @Date: 2021-10-26 16:50:22
6
6
  * @LastEditors: lewis lewis@everylink.ai
7
- * @LastEditTime: 2025-10-24 11:08:09
7
+ * @LastEditTime: 2025-11-04 11:44:15
8
8
  -->
9
9
  <template>
10
10
  <div class='network-box' :style="{visibility: chainShow ? 'visible': 'hidden'}">
@@ -43,7 +43,7 @@
43
43
  },
44
44
  computed: {
45
45
  layer1NetworkList() {
46
- return this.$store.getters['coin/layer1NetworkList'];
46
+ return this.$store.getters['coin/layer1NetworkList'] || [];
47
47
  },
48
48
  networkNeedChange() {
49
49
  return this.$route.name + this.$store.state.wallet.walletChainId
package/dist/index.js CHANGED
@@ -2,7 +2,7 @@
2
2
  * @Author: lewis lewis@everylink.ai
3
3
  * @Date: 2025-09-17 10:50:27
4
4
  * @LastEditors: lewis lewis@everylink.ai
5
- * @LastEditTime: 2025-10-24 11:42:03
5
+ * @LastEditTime: 2025-11-04 11:40:54
6
6
  * @FilePath: /localTools/Users/apple/web-front/web-front/src/common_modules/cms-submodule/index.js
7
7
  * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
8
8
  */
@@ -83,10 +83,15 @@ export function init({ Vue, router, store, Parent, onComponentsRegistered, onRou
83
83
  if (router) {
84
84
  const routes = cmsRouter.Home || []; // 避免变量名冲突,修改变量名
85
85
  routes.forEach(route => {
86
- if (route.component && (route.component === 'parentView' || route.componentName === 'parentView' || route.component === 'Parent')) {
87
- route.component = Parent;
86
+ if (!router.hasRoute(route.name)) {
87
+ if (route.component && (["parentView", "Parent"].includes(route.component) || route.componentName === 'parentView')) {
88
+ route.component = Parent;
89
+ }
90
+ router.addRoute(route);
91
+ }
92
+ else {
93
+ console.log(`[udxCms] 路由已存在,跳过: ${route.name}`);
88
94
  }
89
- router.addRoute(route);
90
95
  });
91
96
  // 调用外部注册回调
92
97
  onRoutesRegistered && onRoutesRegistered();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "udxcms",
3
- "version": "1.0.37",
3
+ "version": "1.0.38",
4
4
  "description": "cms submodule",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",