Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
phsl
/
admin
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
40fe63a3
authored
Sep 05, 2024
by
卢越
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
【代码优化】拼团活动和SPU详情分开查询
parent
03356576
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 additions
and
3 deletions
+1
-3
src/components/DiyEditor/components/mobile/PromotionCombination/index.vue
+1
-3
No files found.
src/components/DiyEditor/components/mobile/PromotionCombination/index.vue
View file @
40fe63a3
...
...
@@ -123,7 +123,6 @@ import {fenToYuan} from "@/utils";
/** 拼团卡片 */
defineOptions
({
name
:
'PromotionCombination'
})
// 定义属性
// 定义属性
const
props
=
defineProps
<
{
property
:
PromotionCombinationProperty
}
>
();
// 商品列表
const
spuList
=
ref
<
ProductSpuApi
.
Spu
[]
>
([]);
...
...
@@ -150,13 +149,12 @@ watch(
.
map
(
activity
=>
activity
.
spuId
)
.
filter
((
spuId
):
spuId
is
number
=>
typeof
spuId
===
'number'
);
// 如果
有
有效的 spuId,调用 API 获取详细信息
// 如果
存在
有效的 spuId,调用 API 获取详细信息
if
(
spuIdList
.
value
.
length
>
0
)
{
spuList
.
value
=
await
ProductSpuApi
.
getSpuDetailList
(
spuIdList
.
value
);
}
else
{
console
.
warn
(
'没有用于获取详细信息的有效 spuId。'
);
}
// 更新 SPU 的最低价格
combinationActivityList
.
value
.
forEach
(
activity
=>
{
activity
.
products
.
forEach
(
product
=>
{
...
...
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