Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
B
boyueCEnd
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
游洁
boyueCEnd
Commits
1e131472
Commit
1e131472
authored
Dec 02, 2025
by
youjie
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
绑定line
parent
357589c3
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
16 additions
and
8 deletions
+16
-8
index.ts
src/router/index.ts
+1
-1
forgePassword.vue
src/views/auth/forgePassword.vue
+2
-2
accountCenter.vue
src/views/personalCenter/accountCenter.vue
+7
-1
LeftView.vue
src/views/personalCenter/components/LeftView.vue
+1
-1
account.vue
...views/personalCenter/components/accountCenter/account.vue
+4
-2
index.vue
src/views/personalCenter/index.vue
+1
-1
No files found.
src/router/index.ts
View file @
1e131472
...
@@ -39,7 +39,7 @@ const router = createRouter({
...
@@ -39,7 +39,7 @@ const router = createRouter({
component
:
()
=>
import
(
'../views/personalCenter/myCoupon.vue'
)
component
:
()
=>
import
(
'../views/personalCenter/myCoupon.vue'
)
},
},
{
{
path
:
'/accountCenter/:type?'
,
//账号中心
path
:
'/accountCenter/:type
/:reType
?'
,
//账号中心
meta
:
{
title
:
"page.accountCenter"
},
meta
:
{
title
:
"page.accountCenter"
},
component
:
()
=>
import
(
'../views/personalCenter/accountCenter.vue'
)
component
:
()
=>
import
(
'../views/personalCenter/accountCenter.vue'
)
},
},
...
...
src/views/auth/forgePassword.vue
View file @
1e131472
...
@@ -234,7 +234,7 @@ const goPage = (path:string) => {
...
@@ -234,7 +234,7 @@ const goPage = (path:string) => {
router
.
push
(
path
)
router
.
push
(
path
)
return
return
}
}
router
.
push
(
'/accountCenter'
)
router
.
push
(
'/accountCenter
/1
'
)
}
}
// 验证邮箱是否可用
// 验证邮箱是否可用
...
@@ -371,7 +371,7 @@ const handleSubmit = async () => {
...
@@ -371,7 +371,7 @@ const handleSubmit = async () => {
// 延迟跳转到登录页
// 延迟跳转到登录页
setTimeout
(()
=>
{
setTimeout
(()
=>
{
if
(
params
&&
params
.
email
){
if
(
params
&&
params
.
email
){
router
.
push
(
'/accountCenter'
)
router
.
push
(
'/accountCenter
/1
'
)
}
else
{
}
else
{
router
.
push
(
'/login'
)
router
.
push
(
'/login'
)
}
}
...
...
src/views/personalCenter/accountCenter.vue
View file @
1e131472
...
@@ -26,7 +26,7 @@
...
@@ -26,7 +26,7 @@
</div>
</div>
</
template
>
</
template
>
<
script
setup
lang=
"ts"
>
<
script
setup
lang=
"ts"
>
import
{
ref
,
onMounted
}
from
'vue'
import
{
ref
,
onMounted
,
watch
}
from
'vue'
import
{
useI18n
}
from
'vue-i18n'
import
{
useI18n
}
from
'vue-i18n'
import
{
useRouter
}
from
'vue-router'
import
{
useRouter
}
from
'vue-router'
import
account
from
"./components/accountCenter/account.vue"
import
account
from
"./components/accountCenter/account.vue"
...
@@ -62,6 +62,12 @@ const TitleBars = [
...
@@ -62,6 +62,12 @@ const TitleBars = [
value
:
4
value
:
4
}
}
]
]
console
.
log
(
router
,
'newVal-----'
)
watch
(()
=>
router
,
(
newVal
,
oldVal
)
=>
{
if
(
newVal
){
console
.
log
(
newVal
,
'newVal-----'
)
}
})
const
changeStatus
=
(
value
:
number
)
=>
{
const
changeStatus
=
(
value
:
number
)
=>
{
current
.
value
=
value
current
.
value
=
value
...
...
src/views/personalCenter/components/LeftView.vue
View file @
1e131472
...
@@ -11,7 +11,7 @@
...
@@ -11,7 +11,7 @@
</div>
</div>
<div
class=
"mt-[13px] text-lg font-medium text-center truncate"
>
{{
userInfo
?.
name
||
''
}}
</div>
<div
class=
"mt-[13px] text-lg font-medium text-center truncate"
>
{{
userInfo
?.
name
||
''
}}
</div>
<div
class=
"flex justify-center items-center mt-[10px] cursor-pointer"
<div
class=
"flex justify-center items-center mt-[10px] cursor-pointer"
@
click=
"goPage('/accountCenter')"
>
@
click=
"goPage('/accountCenter
/1
')"
>
<span
v-if=
"!userInfo?.IsComplete"
class=
"LeftViewTisp w-[6px] h-[6px] rounded-full"
></span>
<span
v-if=
"!userInfo?.IsComplete"
class=
"LeftViewTisp w-[6px] h-[6px] rounded-full"
></span>
<span
class=
"LeftViewData ml-[5px] text-sm font-medium text-[#666]"
>
<span
class=
"LeftViewData ml-[5px] text-sm font-medium text-[#666]"
>
{{
t
(
'personal.completeProfile'
)
}}
{{
t
(
'personal.completeProfile'
)
}}
...
...
src/views/personalCenter/components/accountCenter/account.vue
View file @
1e131472
...
@@ -245,7 +245,10 @@ const generateState = () => {
...
@@ -245,7 +245,10 @@ const generateState = () => {
// line授权
// line授权
const
loginWithLine
=
()
=>
{
const
loginWithLine
=
()
=>
{
const
channelId
=
openInfo
.
value
.
appId
;
// 替换为你的 LINE Channel ID
const
channelId
=
openInfo
.
value
.
appId
;
// 替换为你的 LINE Channel ID
const
redirectUri
=
encodeURIComponent
(
openInfo
.
value
.
redirectUri
||
'https://www.oytour.com/#/login/2/3'
);
// 替换为你的重定向 URI
// https://www.oytour.com/#/login/2/3
console
.
log
(
openInfo
.
value
,
'----------'
)
// return
const
redirectUri
=
encodeURIComponent
(
openInfo
.
value
.
redirectUri
||
'http://localhost:8002/accountCenter/2/3'
);
// 替换为你的重定向 URI
const
state
=
generateState
();
// 防止 CSRF 攻击,生成随机的 state 参数
const
state
=
generateState
();
// 防止 CSRF 攻击,生成随机的 state 参数
// 构造 LINE 授权 URL
// 构造 LINE 授权 URL
const
lineLoginUrl
=
`https://access.line.me/oauth2/v2.1/authorize?response_type=code&client_id=
${
channelId
}
&redirect_uri=
${
redirectUri
}
&state=
${
state
}
&scope=openid%20profile`
;
const
lineLoginUrl
=
`https://access.line.me/oauth2/v2.1/authorize?response_type=code&client_id=
${
channelId
}
&redirect_uri=
${
redirectUri
}
&state=
${
state
}
&scope=openid%20profile`
;
...
@@ -375,7 +378,6 @@ const initGoogleSDK = async () => {
...
@@ -375,7 +378,6 @@ const initGoogleSDK = async () => {
document
.
head
.
appendChild
(
script
);
document
.
head
.
appendChild
(
script
);
});
});
};
};
onMounted
(
async
()
=>
{
onMounted
(
async
()
=>
{
setTimeout
(()
=>
{
setTimeout
(()
=>
{
loading
.
value
=
false
loading
.
value
=
false
...
...
src/views/personalCenter/index.vue
View file @
1e131472
...
@@ -55,7 +55,7 @@ const menuList = ref([
...
@@ -55,7 +55,7 @@ const menuList = ref([
},
},
{
{
name
:
t
(
'personal.menu.accountCenter'
),
name
:
t
(
'personal.menu.accountCenter'
),
path
:
'/accountCenter'
,
path
:
'/accountCenter
/1
'
,
key
:
'accountCenter'
,
key
:
'accountCenter'
,
},
},
{
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment