Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Hooke
/
data-table
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Graphs
Network
Create a new issue
Commits
Issue Boards
Authored by
hookehuyr
2024-11-21 17:33:21 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
d0b3cee41dcbf9f6f34b81f3dcd53ae0d0f5289b
d0b3cee4
1 parent
64ceb6c6
fix
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
4 deletions
src/router.js
src/views/index.vue
src/router.js
View file @
d0b3cee
/*
* @Date: 2022-05-26 13:57:28
* @LastEditors: hookehuyr hookehuyr@gmail.com
* @LastEditTime: 2024-11-21 17:
17:16
* @LastEditTime: 2024-11-21 17:
32:30
* @FilePath: /data-table/src/router.js
* @Description: 文件描述
*/
...
...
@@ -51,7 +51,7 @@ router.beforeEach((to, from, next) => {
next
({
...
to
.
redirectedFrom
,
replace
:
true
});
},
1000
);
}
else
{
if
(
to
.
query
.
page_type
===
'add'
)
{
// 表单为新增状态, 检查是否有未完成的表单信息
if
(
to
.
query
.
page_type
===
'add'
||
to
.
query
.
page_type
===
undefined
)
{
// 表单为新增状态, 检查是否有未完成的表单信息
const
existingCookie
=
Cookies
.
get
(
to
.
query
.
code
);
if
(
existingCookie
)
{
showConfirmDialog
({
...
...
src/views/index.vue
View file @
d0b3cee
<!--
* @Date: 2022-07-18 10:22:22
* @LastEditors: hookehuyr hookehuyr@gmail.com
* @LastEditTime: 2024-11-21 1
3:02:15
* @LastEditTime: 2024-11-21 1
7:33:00
* @FilePath: /data-table/src/views/index.vue
* @Description: 首页
-->
...
...
@@ -512,7 +512,7 @@ onMounted(async () => {
}
// TAG:不同类型提交表单处理
if (page_type === 'add') { // 表单为新增状态, 检查是否有未完成的表单信息
if (page_type === 'add'
|| page_type === undefined
) { // 表单为新增状态, 检查是否有未完成的表单信息
const existingCookie = Cookies.get($route.query.code);
if (existingCookie) {
// 如果Cookie存在,更新它
...
...
Please
register
or
login
to post a comment