diff --git a/f/web-kboss/src/router/index.js b/f/web-kboss/src/router/index.js index 4529902..cbebb76 100644 --- a/f/web-kboss/src/router/index.js +++ b/f/web-kboss/src/router/index.js @@ -331,7 +331,7 @@ export const asyncRoutes = [ component: Layout, meta: { title: "资源概览", - fullPath: "/overview", + fullPath: "/overview", noCache: true, icon: "el-icon-s-data" }, diff --git a/f/web-kboss/src/views/homePage/ncmatch/img/tt-banner.png b/f/web-kboss/src/views/homePage/ncmatch/img/tt-banner.png new file mode 100644 index 0000000..ddf57fe Binary files /dev/null and b/f/web-kboss/src/views/homePage/ncmatch/img/tt-banner.png differ diff --git a/f/web-kboss/src/views/homePage/ncmatch/index.vue b/f/web-kboss/src/views/homePage/ncmatch/index.vue index cc0fa66..8851c43 100644 --- a/f/web-kboss/src/views/homePage/ncmatch/index.vue +++ b/f/web-kboss/src/views/homePage/ncmatch/index.vue @@ -1,97 +1,114 @@ + + diff --git a/f/web-kboss/src/views/homePage/ncmatch/supplyAndDemandSquare/index.vue b/f/web-kboss/src/views/homePage/ncmatch/supplyAndDemandSquare/index.vue index 3af4898..a1500e7 100644 --- a/f/web-kboss/src/views/homePage/ncmatch/supplyAndDemandSquare/index.vue +++ b/f/web-kboss/src/views/homePage/ncmatch/supplyAndDemandSquare/index.vue @@ -1,25 +1,11 @@ diff --git a/f/web-kboss/src/views/login/indexNew.vue b/f/web-kboss/src/views/login/indexNew.vue index 2fdec30..abf004d 100644 --- a/f/web-kboss/src/views/login/indexNew.vue +++ b/f/web-kboss/src/views/login/indexNew.vue @@ -99,9 +99,9 @@ - - + + {{ SendCode_text }} @@ -155,7 +155,7 @@ + :disabled="isDisabled1 || isGettingCode1" @click="debouncedGetCode1"> {{ SendCode_text1 }} @@ -246,6 +246,12 @@ export default { timer: null, // 手机登录验证码定时器 timer1: null, // 重置密码验证码定时器 + // 防抖相关 + isGettingCode: false, // 是否正在获取验证码 + isGettingCode1: false, // 是否正在获取重置密码验证码 + debounceTimer: null, // 防抖定时器 + debounceTimer1: null, // 重置密码防抖定时器 + // 对话框和加载状态 dialogVisible: false, // 重置密码对话框是否可见 loading: false, // 登录按钮加载状态 @@ -347,6 +353,50 @@ export default { }, methods: { + // 防抖函数 + debounce(func, wait) { + return function() { + const context = this; + const args = arguments; + clearTimeout(this.debounceTimer); + this.debounceTimer = setTimeout(() => { + func.apply(context, args); + }, wait); + }; + }, + + // 防抖后的获取验证码方法 + debouncedGetCode: function() { + if (this.isDisabled || this.isGettingCode) return; + + this.isGettingCode = true; + + // 清除之前的定时器 + clearTimeout(this.debounceTimer); + + // 设置新的定时器,300ms后执行 + this.debounceTimer = setTimeout(() => { + this.getCode(); + this.isGettingCode = false; + }, 300); + }, + + // 防抖后的获取重置密码验证码方法 + debouncedGetCode1: function() { + if (this.isDisabled1 || this.isGettingCode1) return; + + this.isGettingCode1 = true; + + // 清除之前的定时器 + clearTimeout(this.debounceTimer1); + + // 设置新的定时器,300ms后执行 + this.debounceTimer1 = setTimeout(() => { + this.getCode1(); + this.isGettingCode1 = false; + }, 300); + }, + // 跳转到百度产品页面 goBaidu(listUrl, url) { this.$store.commit('setRedirectUrl', url) @@ -695,6 +745,9 @@ export default { }); } } + }).catch(error => { + this.isGettingCode = false; + this.$message.error('验证码获取失败'); }); }, @@ -743,6 +796,9 @@ export default { type: "error", }); } + }).catch(error => { + this.isGettingCode1 = false; + this.$message.error('验证码获取失败'); }); },