Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas_plus
/
dj-car-boutique-work-wechat
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
1
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 213ecffc
authored
Dec 08, 2025
by
张立顺
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
feat 功能修复
1 parent
f8d38454
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
38 deletions
config.js
pages/tabMine/components/StoreSelectPopup/StoreSelectPopup.js
config.js
View file @
213ecff
...
@@ -18,7 +18,7 @@ export const appId = 'wx570d9331f9ace0bd'
...
@@ -18,7 +18,7 @@ export const appId = 'wx570d9331f9ace0bd'
* 4预发布
* 4预发布
* 5cdptest
* 5cdptest
*/
*/
let
index
=
1
let
index
=
2
const
accountInfo
=
wx
.
getAccountInfoSync
()
const
accountInfo
=
wx
.
getAccountInfoSync
()
const
systemInfo
=
wx
.
getSystemInfoSync
()
const
systemInfo
=
wx
.
getSystemInfoSync
()
const
envName
=
accountInfo
.
miniProgram
.
envVersion
const
envName
=
accountInfo
.
miniProgram
.
envVersion
...
...
pages/tabMine/components/StoreSelectPopup/StoreSelectPopup.js
View file @
213ecff
...
@@ -183,49 +183,23 @@ Component({
...
@@ -183,49 +183,23 @@ Component({
this
.
getList
(
true
)
this
.
getList
(
true
)
},
},
choose
(
e
)
{
choose
(
e
)
{
let
{
item
,
index
}
=
e
.
currentTarget
.
dataset
let
{
index
}
=
e
.
currentTarget
.
dataset
let
{
active
}
=
item
let
{
storeRangeList
}
=
this
.
data
let
{
storeRangeList
}
=
this
.
data
if
(
index
>
0
)
{
storeRangeList
=
(
storeRangeList
||
[]).
map
((
val
,
i
)
=>
{
let
target
=
`storeRangeList[
${
index
}
].active`
val
.
active
=
i
===
index
this
.
setData
(
return
val
{
})
[
target
]:
!
active
,
this
.
setData
({
storeRangeList
},
()
=>
{
'storeRangeList[0].active'
:
false
this
.
setSelectedData
()
},
})
()
=>
{
this
.
setSelectedData
()
}
)
}
else
{
if
(
!
active
)
{
storeRangeList
.
map
(
val
=>
{
return
(
val
.
active
=
false
)
})
storeRangeList
[
0
].
active
=
true
}
this
.
setData
({
storeRangeList
},
()
=>
{
this
.
setSelectedData
()
})
}
},
},
setSelectedData
()
{
setSelectedData
()
{
let
{
storeRangeList
,
selectedData
}
=
this
.
data
let
{
storeRangeList
}
=
this
.
data
let
arr
=
[]
let
selected
=
(
storeRangeList
||
[]).
find
(
v
=>
v
.
active
&&
v
.
merchantId
)
// 已选的未分页加载出的数据置为选中状态
let
selectedArr
=
wx
.
$util
.
arrayUnique
(
selectedData
.
concat
(
storeRangeList
),
'merchantId'
)
selectedArr
.
forEach
(
val
=>
{
if
(
val
.
active
&&
val
.
merchantId
)
arr
.
push
(
val
)
})
// if (!arr?.length) storeRangeList[0].active = true
this
.
setData
({
this
.
setData
({
selectedData
:
arr
,
// 选择全部清除已选的门店数据
selectedData
:
selected
?
[
selected
]
:
[],
storeRangeList
storeRangeList
})
})
console
.
log
(
selectedData
,
'selectedData'
)
},
},
hidePopup
()
{
hidePopup
()
{
this
.
triggerEvent
(
'cancel'
)
this
.
triggerEvent
(
'cancel'
)
...
...
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