Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas
/
mini-program
/
zhwy
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 05271e03
authored
Nov 07, 2023
by
杨北旺
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
优化
1 parent
4b8a930a
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
14 additions
and
7 deletions
packageMine/pages/move/index/index.js
pages/tab/index/index.js
utils/constants.js
packageMine/pages/move/index/index.js
View file @
05271e0
...
@@ -99,8 +99,9 @@ Page({
...
@@ -99,8 +99,9 @@ Page({
onShow
()
{
async
onShow
()
{
if
(
this
.
data
.
codeId
)
this
.
checkMovecode
(
this
.
data
.
codeId
)
const
res
=
await
wx
.
p
.
router
.
intercept
()
if
(
!
res
&&
this
.
data
.
codeId
)
this
.
checkMovecode
(
this
.
data
.
codeId
)
},
},
onShareAppMessage
()
{
onShareAppMessage
()
{
...
...
pages/tab/index/index.js
View file @
05271e0
...
@@ -129,10 +129,6 @@ Page({
...
@@ -129,10 +129,6 @@ Page({
// 获取门店列表
// 获取门店列表
async
getMerchantList
()
{
async
getMerchantList
()
{
const
HAVE_ENTER
=
wx
.
p
.
storage
.
get
(
'first_enter_miniprograme'
)
if
(
HAVE_ENTER
&&
!
this
.
fresh
)
{
this
.
defaultMerchant
=
wx
.
p
.
storage
.
get
(
'first_enter_merchantId'
)
}
// 获取mock配置门店
// 获取mock配置门店
const
MOCKDATA
=
wx
.
p
.
storage
.
get
(
"mock_data"
);
const
MOCKDATA
=
wx
.
p
.
storage
.
get
(
"mock_data"
);
let
MerchantList
=
MERCHANT_STATIC_LIST
[
env
]
let
MerchantList
=
MERCHANT_STATIC_LIST
[
env
]
...
@@ -142,6 +138,16 @@ Page({
...
@@ -142,6 +138,16 @@ Page({
MerchantList
=
[...
MerchantList
,
...
ADD_MERCHANT_LIST
]
MerchantList
=
[...
MerchantList
,
...
ADD_MERCHANT_LIST
]
}
}
}
}
const
HAVE_ENTER
=
wx
.
p
.
storage
.
get
(
'first_enter_miniprograme'
)
// 获取扫码链接带入的门店
if
(
HAVE_ENTER
&&
!
this
.
fresh
)
{
const
merchant
=
wx
.
p
.
storage
.
get
(
'first_enter_merchantId'
)
const
ISNEWMERCHANT
=
MerchantList
.
includes
(
merchant
)
if
(
!
ISNEWMERCHANT
){
MerchantList
.
push
(
merchant
)
}
}
let
storeList
=
[],
index
=
0
let
storeList
=
[],
index
=
0
storeList
=
await
this
.
getMerchantListData
(
MerchantList
)
||
[]
storeList
=
await
this
.
getMerchantListData
(
MerchantList
)
||
[]
storeList
.
forEach
((
ele
,
i
)
=>
{
storeList
.
forEach
((
ele
,
i
)
=>
{
...
...
utils/constants.js
View file @
05271e0
...
@@ -26,7 +26,7 @@ export const STORAGE_OBJECTkEY = {
...
@@ -26,7 +26,7 @@ export const STORAGE_OBJECTkEY = {
// 设置默认门店信息
// 设置默认门店信息
export
const
MERCHANT_STATIC_LIST
=
{
export
const
MERCHANT_STATIC_LIST
=
{
'develop'
:
[
44211227
,
44209845
],
'develop'
:
[
44211227
,
44209845
],
'test'
:
[
44212577
,
4421
0895
,
4421
2578
,
44210956
],
'test'
:
[
44212577
,
44212578
,
44210956
],
'beta'
:
[
44211427
,
44211428
],
'beta'
:
[
44211427
,
44211428
],
'production'
:
[
44209566
,
44209565
],
'production'
:
[
44209566
,
44209565
],
}
}
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment