商品
商品
获取商品
GET /goods/{id}
权限
- 不认证用户
响应
成功响应GoodsInfo结构体
字段 | 描述 |
---|---|
id int string |
商品ID |
title string |
标题 |
subtitle string |
副标题 |
type enum{normal,live,liveOpen,open} |
商品类型 course:课程 classroom:班级 |
creator SimpleUser |
创建者 |
showable bool |
是否开放商品页展示 |
buyable bool |
是否开放商品购买 |
summary string |
商品介绍 |
maxPrice float string |
已发布商品的最高价格 |
minPrice float string |
已发布商品的最低价格 |
discountId int string |
打折活动ID |
images Picture |
商品图片 |
ratingNum int string |
评价人数 |
rating float string |
评价平均分 |
hitNum int string |
点击量 |
hotSeq int string |
商品热度 |
minDisplayPrice float string |
已发布商品的最高展示价格 |
maxDisplayPrice float string |
已发布商品的最低展示价格 |
canManage bool |
是否能管理商品对象 |
peopleShowNum int string |
显示加入人数 |
isMember bool |
是否是学员 |
status string |
商品状态:created, published, unpublished |
orgId int string |
组织机构ID |
orgCode string |
组织机构编码 |
recommendedWeight int string |
推荐序号 |
recommendedTime datetime |
推荐时间 |
createdTime datetime |
创建时间 |
updatedTime datetime |
最后更新时间 |
product Product |
产品信息 |
specs GoodsSpecs |
商品规格信息 |
字段 | 描述 |
---|---|
id int string |
用户ID |
nickname int string |
昵称 |
title string |
头衔 |
uuid string |
uuid |
destroyed bool |
是否注销 |
avatar Picture |
头像 |
字段 | 描述 |
---|---|
id int string |
产品ID |
title string |
产品名称 |
targetType string |
产品类型 course:课程 classroom:班级 open_course:公开课 ... |
owner int string |
拥有者 |
createdTime datetime |
创建时间 |
updatedTime datetime |
最后更新时间 |
target Target |
产品对象 |
字段 | 描述 |
---|---|
id int string |
id |
type enum{normal,live,liveOpen,open} |
课程类型 normal:普通课程 live:直播课程 liveOpen:直播公开课 open:公开课 |
title string |
标题 |
subtitle string |
副标题 |
status enum{draft,published,closed} |
状态 |
cover Picture |
课程封面图片地址 |
summary string |
课程摘要 |
studentNum int string |
学员数量 |
discountType string |
打折类型 |
discount string |
折扣量 |
maxCoursePrice float string |
已发布教学计划的最高价格 |
minCoursePrice float string |
已发布教学计划的最低价格 |
defaultCourseId int string |
默认计划id |
productId int string |
产品id |
goodsId int string |
商品id |
字段 | 描述 |
---|---|
id int string |
id |
goodsId int string |
商品id |
targetId int string |
目标内容Id,如教学计划id |
title string |
规格名称 |
seq int string |
序号 |
status string |
状态 draft,published,closed |
price float string |
价格 |
coinPrice float string |
虚拟币价格 |
usageMode string |
学习有效期模式 |
usageDays int string |
学习有效天数 |
usageStartTime datetime |
学习有效期开始日期 |
usageEndTime datetime |
学习有效期结束日期 |
buyableStartTime datetime |
开放购买开始日期 |
buyableEndTime datetime |
开放购买结束日期 |
buyableMode string |
购买模式 |
buyable bool |
是否开放购买 |
maxJoinNum int string |
最大加入数 |
displayPrice float string |
展示价格 |
isMember bool |
是否是学员 |
access Access |
是否可以继续学习 success:可以 course.unpublished:课程未发布 course.expired:学习有效期已过 course.not_arrive:未到授课时间 member.expired:学员有效期已到 vip.member_expired:vip过期 vip.level_not_exist:vip等级不存在 vip.level_low:等级过低 |
services list<Service> |
承诺服务 |
hasCertificate bool |
是否有证书 |
learnUrl string |
学习页面url |
vipLevelInfo string |
VIP等级信息 |
vipUser bool |
VIP用户 |
canVipJoin bool |
VIP是否可加入 |
teachers list<SimpleUser> |
教师 |
字段 | 描述 |
---|---|
small string |
小图 |
middle string |
中图 |
large string |
大图 |
字段 | 描述 |
---|---|
code string |
编码 |
msg string |
信息 |
字段 | 描述 |
---|---|
code string |
服务编码 |
shortName string |
短名称 |
fullName string |
长名称 |
summary string |
描述信息 |
获取商品推荐内容
GET /goods/{id}/components/{component}
权限
- 不认证用户
响应
成功响应Component结构体
字段 | 描述 |
---|---|
teachers list<SimpleUser> |
教师 |