Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
mini_own
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
geruidan
mini_own
Commits
4a58a1ab
Commit
4a58a1ab
authored
Apr 16, 2023
by
geruidan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
首页注册
parent
4e2f16d3
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
26 additions
and
26 deletions
+26
-26
pages.json
pages.json
+10
-10
pages/h5/bindPh.vue
pages/h5/bindPh.vue
+2
-1
pages/index/defalutScreen.vue
pages/index/defalutScreen.vue
+14
-15
No files found.
pages.json
View file @
4a58a1ab
...
@@ -4,15 +4,6 @@
...
@@ -4,15 +4,6 @@
"^mpShop-(.*)"
:
"@/components/mpShop-$1/mpShop-$1.vue"
"^mpShop-(.*)"
:
"@/components/mpShop-$1/mpShop-$1.vue"
},
},
"pages"
:
[
//pages数组中第一项表示应用启动页,参考:https://uniapp.dcloud.io/collocation/pages
"pages"
:
[
//pages数组中第一项表示应用启动页,参考:https://uniapp.dcloud.io/collocation/pages
{
"path"
:
"pages/h5/bindPh"
,
"style"
:
{
"navigationBarTitleText"
:
"立即绑定"
,
"enablePullDownRefresh"
:
false
}
},
{
{
"path"
:
"pages/index/defalutScreen"
,
"path"
:
"pages/index/defalutScreen"
,
"style"
:
"style"
:
...
@@ -89,6 +80,15 @@
...
@@ -89,6 +80,15 @@
"enablePullDownRefresh"
:
false
"enablePullDownRefresh"
:
false
}
}
},
{
"path"
:
"pages/h5/bindPh"
,
"style"
:
{
"navigationBarTitleText"
:
"立即绑定"
,
"enablePullDownRefresh"
:
false
}
}
}
...
@@ -133,7 +133,7 @@
...
@@ -133,7 +133,7 @@
"list"
:
[
"list"
:
[
{
{
"name"
:
"pay"
,
//模式名称
"name"
:
"pay"
,
//模式名称
"path"
:
"/pages/
h5/pay
"
//启动页面,必选
"path"
:
"/pages/
index/defalutScreen
"
//启动页面,必选
}
}
]
]
},
},
...
...
pages/h5/bindPh.vue
View file @
4a58a1ab
...
@@ -16,6 +16,7 @@
...
@@ -16,6 +16,7 @@
mapGetters
mapGetters
}
from
'
vuex
'
}
from
'
vuex
'
import
http
from
'
@/shopro/request/index
'
;
import
http
from
'
@/shopro/request/index
'
;
import
qs
from
'
qs
'
;
export
default
{
export
default
{
data
()
{
data
()
{
return
{
return
{
...
@@ -76,7 +77,7 @@
...
@@ -76,7 +77,7 @@
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
.bindPh
{
.bindPh
{
margin
:
0
auto
;
margin
:
0
auto
;
padding
:
1
00rpx
0
;
padding
:
3
00rpx
0
;
width
:
90%
;
width
:
90%
;
margin
:
0
auto
;
margin
:
0
auto
;
// text-align: center;
// text-align: center;
...
...
pages/index/defalutScreen.vue
View file @
4a58a1ab
<
template
>
<
template
>
<view
class=
"screen-container"
>
<view
class=
"screen-container"
>
<image
class=
"bg"
src=
"../../static/img/screen/screen-bg.png"
mode=
"scaleToFill"
/>
<image
class=
"bg"
src=
"../../static/img/screen/screen-bg.png"
mode=
"scaleToFill"
/>
<button
v-if=
"unregistered"
@
click=
"changeTabBa
r"
class=
"btn"
>
<button
@
click=
"ente
r"
class=
"btn"
>
马上进入
马上进入
</button>
</button>
<!-- open-type="getPhoneNumber" @getphonenumber="getInfoPhoneNumber" -->
<!-- open-type="getPhoneNumber" @getphonenumber="getInfoPhoneNumber" -->
<button
v-else
class=
"btn"
@
click=
"getInfoPhoneNumber"
>
<
!--
<
button
v-else
class=
"btn"
@
click=
"getInfoPhoneNumber"
>
微信授权登录
微信授权登录
</button>
</button>
-->
</view>
</view>
</
template
>
</
template
>
<
script
>
<
script
>
...
@@ -29,28 +29,27 @@
...
@@ -29,28 +29,27 @@
},
},
methods
:
{
methods
:
{
...
mapActions
([
'
getPhoneNumber
'
,
'
registerInfoFn
'
,
'
authCheck
'
,
'
getUserInfo
'
]),
...
mapActions
([
'
getPhoneNumber
'
,
'
registerInfoFn
'
,
'
authCheck
'
,
'
getUserInfo
'
]),
//
切换底部tab;
//
马上进入
changeTabBa
r
()
{
ente
r
()
{
if
(
this
.
unregistered
)
{
if
(
this
.
unregistered
)
{
uni
.
navigateTo
({
uni
.
navigateTo
({
url
:
'
/pages/h5/index
'
,
url
:
'
/pages/h5/index
'
,
})
})
}
}
else
{
},
this
.
getInfoPhoneNumber
()
}},
// 获取手机号
// 获取手机号
async
getInfoPhoneNumber
(
e
)
{
async
getInfoPhoneNumber
(
e
)
{
// let number = await this.getPhoneNumber(e);
// let number = await this.getPhoneNumber(e);
let
register
=
await
this
.
registerInfoFn
();
let
register
=
await
this
.
registerInfoFn
();
if
(
register
)
{
//注册成功
if
(
register
)
{
//注册成功
this
.
unregistered
=
true
;
this
.
unregistered
=
true
;
uni
.
showToast
({
uni
.
navigateTo
({
title
:
"
授权成功,点击马上进入
"
,
url
:
'
/pages/h5/index
'
,
duration
:
2000
,
})
icon
:
'
none
'
});
}
}
},
},
async
auth
AndWeRun
()
{
async
auth
()
{
let
auth
=
await
this
.
authCheck
();
let
auth
=
await
this
.
authCheck
();
console
.
log
(
"
调用authcheck的值
"
+
auth
)
console
.
log
(
"
调用authcheck的值
"
+
auth
)
let
that
=
this
;
let
that
=
this
;
...
@@ -78,7 +77,7 @@
...
@@ -78,7 +77,7 @@
if
(
this
.
checkSessionStatus
&&
token
)
{
if
(
this
.
checkSessionStatus
&&
token
)
{
let
token
=
uni
.
getStorageSync
(
'
token
'
);
let
token
=
uni
.
getStorageSync
(
'
token
'
);
console
.
log
(
"
token的值====================
"
+
token
)
console
.
log
(
"
token的值====================
"
+
token
)
this
.
auth
AndWeRun
();
this
.
auth
();
}
else
{
}
else
{
console
.
log
(
"
走吗1
"
)
console
.
log
(
"
走吗1
"
)
// session 不存在,调用login。userInfo 。更新session
// session 不存在,调用login。userInfo 。更新session
...
...
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