fix: 屏蔽未完成表单弹框功能并优化代码格式
移除未完成表单弹框的相关逻辑,避免在特定场景下显示干扰用户 优化代码格式,统一缩进和换行风格
Showing
2 changed files
with
3 additions
and
1 deletions
| 1 | /* | 1 | /* |
| 2 | * @Date: 2022-05-26 13:57:28 | 2 | * @Date: 2022-05-26 13:57:28 |
| 3 | * @LastEditors: hookehuyr hookehuyr@gmail.com | 3 | * @LastEditors: hookehuyr hookehuyr@gmail.com |
| 4 | - * @LastEditTime: 2025-11-06 10:45:17 | 4 | + * @LastEditTime: 2025-11-06 10:58:08 |
| 5 | * @FilePath: /data-table/src/router.js | 5 | * @FilePath: /data-table/src/router.js |
| 6 | * @Description: 文件描述 | 6 | * @Description: 文件描述 |
| 7 | */ | 7 | */ |
| ... | @@ -91,6 +91,7 @@ router.beforeEach((to, from, next) => { | ... | @@ -91,6 +91,7 @@ router.beforeEach((to, from, next) => { |
| 91 | resetDialogState(); | 91 | resetDialogState(); |
| 92 | } | 92 | } |
| 93 | 93 | ||
| 94 | + // TAG: 屏蔽未完成弹框功能 | ||
| 94 | // 新增:在显示未完成表单弹框之前,对 leader 来源进行特殊处理 | 95 | // 新增:在显示未完成表单弹框之前,对 leader 来源进行特殊处理 |
| 95 | // 如果是新增页面或未指定类型,并且来源为 leader,则提前清理未完成表单的 Cookie,避免弹框 | 96 | // 如果是新增页面或未指定类型,并且来源为 leader,则提前清理未完成表单的 Cookie,避免弹框 |
| 96 | // 这样可以确保不会触发 showUnfinishedFormDialog 或包含“您还未完成的表单,是否继续?”的提示 | 97 | // 这样可以确保不会触发 showUnfinishedFormDialog 或包含“您还未完成的表单,是否继续?”的提示 | ... | ... |
| ... | @@ -168,6 +168,7 @@ const confirmCycleSelection = () => { | ... | @@ -168,6 +168,7 @@ const confirmCycleSelection = () => { |
| 168 | * @param {Object} route 目标路由对象 | 168 | * @param {Object} route 目标路由对象 |
| 169 | */ | 169 | */ |
| 170 | const checkUnfinishedForm = (route) => { | 170 | const checkUnfinishedForm = (route) => { |
| 171 | + // TAG: 屏蔽未完成弹框功能 | ||
| 171 | // 新增:在显示未完成表单弹框之前,对 leader 来源进行特殊处理 | 172 | // 新增:在显示未完成表单弹框之前,对 leader 来源进行特殊处理 |
| 172 | // 如果是新增页面或未指定类型,并且来源为 leader,则提前清理未完成表单的 Cookie,避免弹框 | 173 | // 如果是新增页面或未指定类型,并且来源为 leader,则提前清理未完成表单的 Cookie,避免弹框 |
| 173 | if ((route.query.page_type === 'add' || route.query.page_type === undefined) && (route.query.volunteer_source === 'leader')) { | 174 | if ((route.query.page_type === 'add' || route.query.page_type === undefined) && (route.query.volunteer_source === 'leader')) { | ... | ... |
-
Please register or login to post a comment