Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mayi-mp-shop
Overview
Overview
Details
Activity
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
程默
mayi-mp-shop
Commits
e677db30
Commit
e677db30
authored
Mar 03, 2021
by
程默
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix 跳转
parent
548132d0
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
16 additions
and
11 deletions
+16
-11
src/pages/index/index.vue
+3
-3
src/pages/tabBar1/index.vue
+1
-1
src/pages/tabBar2/index.vue
+1
-1
src/pages/tabBar3/index.vue
+1
-1
src/pages/tabBar4/index.vue
+1
-1
src/utils/mayi.js
+9
-4
No files found.
src/pages/index/index.vue
View file @
e677db30
<
template
>
<
template
>
<div>
<div>
<!--
<div>
{{
withoutScene
?
"初始化完成"
:
"初始化中"
}}
</div>
-->
<div
style=
"width:100%;height:90vh;display:flex;justify-content: center;align-items: center;"
>
<div
style=
"width:100%;height:90vh;display:flex;justify-content: center;align-items: center;"
>
<van-loading
size=
"40px"
type=
"spinner"
></van-loading>
<van-loading
size=
"40px"
type=
"spinner"
></van-loading>
</div>
</div>
...
@@ -24,7 +23,8 @@ export default {
...
@@ -24,7 +23,8 @@ export default {
baseUrl
:
process
.
env
.
BASE_URL
,
baseUrl
:
process
.
env
.
BASE_URL
,
link
:
this
.
baseUrl
,
link
:
this
.
baseUrl
,
page
:
"/"
,
page
:
"/"
,
params
:
"?mixid="
+
this
.
shopId
+
'&native=1'
,
location_obj
:
wx
.
getStorageSync
(
"location"
),
params
:
"?mixid="
+
this
.
shopId
+
`&location_obj=
${
this
.
location_obj
}
`
,
userInfo
:
{
userInfo
:
{
nickName
:
"mpvue"
,
nickName
:
"mpvue"
,
...
@@ -134,7 +134,7 @@ export default {
...
@@ -134,7 +134,7 @@ export default {
//来自直播详情
//来自直播详情
this
.
page
=
decodeURIComponent
(
options
.
backpath
);
this
.
page
=
decodeURIComponent
(
options
.
backpath
);
if
(
this
.
page
.
includes
(
"?"
)){
if
(
this
.
page
.
includes
(
"?"
)){
this
.
params
=
"&mixid="
+
this
.
shopId
+
'&native=1'
;
this
.
params
=
"&mixid="
+
this
.
shopId
+
`&location_obj=
${
this
.
location_obj
}
`
;
}
}
options
.
params
&&
(
this
.
params
+=
"&"
+
serialize
(
decodeURIComponent
(
options
.
params
)));
options
.
params
&&
(
this
.
params
+=
"&"
+
serialize
(
decodeURIComponent
(
options
.
params
)));
console
.
log
(
this
.
page
,
this
.
params
)
console
.
log
(
this
.
page
,
this
.
params
)
...
...
src/pages/tabBar1/index.vue
View file @
e677db30
...
@@ -22,7 +22,7 @@ export default {
...
@@ -22,7 +22,7 @@ export default {
return
{
return
{
link
:
process
.
env
.
BASE_URL
,
link
:
process
.
env
.
BASE_URL
,
page
:
"/"
,
page
:
"/"
,
params
:
"?mixid="
+
this
.
$store
.
state
.
mixid
+
"&tabbar=1&native=1"
,
params
:
"?mixid="
+
this
.
$store
.
state
.
mixid
+
`&tabbar=1&location_obj=
${
wx
.
getStorageSync
(
"location"
)}
`
,
index
:
1
,
index
:
1
,
ss
:
""
,
ss
:
""
,
};
};
...
...
src/pages/tabBar2/index.vue
View file @
e677db30
...
@@ -21,7 +21,7 @@ export default {
...
@@ -21,7 +21,7 @@ export default {
return
{
return
{
link
:
process
.
env
.
BASE_URL
,
link
:
process
.
env
.
BASE_URL
,
page
:
"/"
,
page
:
"/"
,
params
:
"?mixid="
+
this
.
$store
.
state
.
mixid
+
"&tabbar=2&native=1"
,
params
:
"?mixid="
+
this
.
$store
.
state
.
mixid
+
`&tabbar=2&location_obj=
${
wx
.
getStorageSync
(
"location"
)}
`
,
index
:
2
,
index
:
2
,
ss
:
""
,
ss
:
""
,
};
};
...
...
src/pages/tabBar3/index.vue
View file @
e677db30
...
@@ -21,7 +21,7 @@ export default {
...
@@ -21,7 +21,7 @@ export default {
return
{
return
{
link
:
process
.
env
.
BASE_URL
,
link
:
process
.
env
.
BASE_URL
,
page
:
"/"
,
page
:
"/"
,
params
:
"?mixid="
+
this
.
$store
.
state
.
mixid
+
"&tabbar=3&native=1"
,
params
:
"?mixid="
+
this
.
$store
.
state
.
mixid
+
`&tabbar=3&location_obj=
${
wx
.
getStorageSync
(
"location"
)}
`
,
index
:
3
,
index
:
3
,
ss
:
""
,
ss
:
""
,
};
};
...
...
src/pages/tabBar4/index.vue
View file @
e677db30
...
@@ -21,7 +21,7 @@ export default {
...
@@ -21,7 +21,7 @@ export default {
return
{
return
{
link
:
process
.
env
.
BASE_URL
,
link
:
process
.
env
.
BASE_URL
,
page
:
"/"
,
page
:
"/"
,
params
:
"?mixid="
+
this
.
$store
.
state
.
mixid
+
"&tabbar=4&native=1"
,
params
:
"?mixid="
+
this
.
$store
.
state
.
mixid
+
`&tabbar=4&location_obj=
${
wx
.
getStorageSync
(
"location"
)}
`
,
index
:
4
,
index
:
4
,
ss
:
""
,
ss
:
""
,
};
};
...
...
src/utils/mayi.js
View file @
e677db30
...
@@ -27,8 +27,9 @@ export function $themeToLink(data, option) {
...
@@ -27,8 +27,9 @@ export function $themeToLink(data, option) {
let
app
=
getApp
();
let
app
=
getApp
();
let
type
=
data
.
type
;
let
type
=
data
.
type
;
// 点击底部栏
// 点击底部栏--
if
(
option
)
{
// if (option) {
// 登录拦截
let
parseLink
=
getUrlofLink
(
data
);
let
parseLink
=
getUrlofLink
(
data
);
let
aa
=
noLoginListPath
.
includes
(
parseLink
)
||
parseLink
.
substr
(
0
,
7
)
==
"/goods/"
let
aa
=
noLoginListPath
.
includes
(
parseLink
)
||
parseLink
.
substr
(
0
,
7
)
==
"/goods/"
console
.
log
(
parseLink
,
aa
,
'parseLinkparseLinkparseLink'
,
parseLink
,
noLoginListPath
)
console
.
log
(
parseLink
,
aa
,
'parseLinkparseLinkparseLink'
,
parseLink
,
noLoginListPath
)
...
@@ -38,15 +39,19 @@ export function $themeToLink(data, option) {
...
@@ -38,15 +39,19 @@ export function $themeToLink(data, option) {
return
return
}
}
//
替换首页位置
//
判断是否市跳转到tabbar页面 替换首页位置
let
isTabbarIndex
=
checkTabbarPage
(
parseLink
);
let
isTabbarIndex
=
checkTabbarPage
(
parseLink
);
console
.
log
(
'44'
,
isTabbarIndex
)
if
(
isTabbarIndex
>=
0
)
{
isTabbarIndex
=
isTabbarIndex
==
0
?
checkTabbarPage
(
'/'
)
:
isTabbarIndex
isTabbarIndex
=
isTabbarIndex
==
0
?
checkTabbarPage
(
'/'
)
:
isTabbarIndex
wx
.
switchTab
({
wx
.
switchTab
({
url
:
parseLink
==
'/'
?
'/pages/home/main'
:
`/pages/tabBar
${
isTabbarIndex
}
/main`
,
url
:
parseLink
==
'/'
?
'/pages/home/main'
:
`/pages/tabBar
${
isTabbarIndex
}
/main`
,
})
})
console
.
log
(
option
,
data
,
'---'
,
parseLink
==
'/'
?
'/pages/home/main'
:
`/pages/tabBar
${
isTabbarIndex
}
/main`
)
return
return
}
}
// console.log(option, data,'---',parseLink == '/' ? '/pages/home/main' : `/pages/tabBar${isTabbarIndex}/main`)
// return
// }
// 历史数据
// 历史数据
...
...
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