|
@@ -40,17 +40,19 @@ func GetMyChartIsCollect(token string, uniqueCode string) (isCollect bool, err e
|
|
|
return
|
|
|
}
|
|
|
|
|
|
-func MyChartCollect(token, uniqueCode, chartName, ChartImage string) (resp *models.BaseResponse, err error) {
|
|
|
+func MyChartCollect(token, uniqueCode, chartName, chartImage string, chartInfoId int) (resp *models.BaseResponse, err error) {
|
|
|
url := utils.ETA_MINI_URL + "mychart/collect"
|
|
|
type MyChartCollectReq struct {
|
|
|
- UniqueCode string
|
|
|
- ChartName string
|
|
|
- ChartImage string
|
|
|
+ UniqueCode string
|
|
|
+ ChartName string
|
|
|
+ ChartImage string
|
|
|
+ ChartInfoId int
|
|
|
}
|
|
|
req := MyChartCollectReq{
|
|
|
- UniqueCode: uniqueCode,
|
|
|
- ChartName: chartName,
|
|
|
- ChartImage: ChartImage,
|
|
|
+ UniqueCode: uniqueCode,
|
|
|
+ ChartName: chartName,
|
|
|
+ ChartImage: chartImage,
|
|
|
+ ChartInfoId: chartInfoId,
|
|
|
}
|
|
|
reqBody, _ := json.Marshal(req)
|
|
|
result, err := HttpPost(url, string(reqBody), token)
|