Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
YOHOBUYPC
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
2
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
梁志锋
9 years ago
Commit
7dc2c12a9c7ddd6e325c62ac515660ca2636d85e
1 parent
a8539ade
修改颜色和尺码的数据结构
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
68 additions
and
11 deletions
docs/data-structure.md
docs/data-structure.md
View file @
7dc2c12
...
...
@@ -819,26 +819,83 @@
name: '',
price: '',
salePrice: '',
colors: [
/**
colors: [
{
id: 1,
chosed: true,
name: '黄色',
colorNum:10,
shortUrl:'',
sizes: [
{
},
...
],**/
colors: [
{
color:[//说明:第一行,其colorNum的值为其下所有尺码数量之和,不需要sizeNumStr的值.
{
id: 1,
name: '黄色',
colorNum:10,
shortUrl:'',
},
{
id: 2,
name: '红色',
colorNum:20,
shortUrl:'',
}
]
},
{
color:[//说明:第二行至最后一行,其colorNum的值为其对应尺码的数量,不需要sizeNumStr的值.
{
id: 1,
name: '黄色',
colorNum:10,
shortUrl:'',
},
{
id: 2,
name: '红色',
colorNum:20,
shortUrl:'',
}
]
}
],
sizes: [
{
size:[//说明:第一行,显示所有的尺寸,即为下面的defaultSizes,不需要numStr的值
{
id: 1,
name: 'M',
sizeNum: 2
},
{
id: 2,
chosed: true,
name: 'X',
sizeNum: 2
},
...
]
}
]
},
...
],
defaultSizes: [
{
size:[//说明:第一行至最后一行,不需要numStr的值
{
id: 3,
name: 'M',
sizeNum: 2
},
{
id: 4,
name: 'X',
sizeNum: 2
}
]
}
]
/**defaultSizes: [
{
numZero: true,
name: 'X',
...
...
@@ -847,7 +904,7 @@
...
]
totalNum: 20
totalNum: 20
**/
}
### 购物车商品
...
...
Please
register
or
login
to post a comment