Initial commit

This commit is contained in:
Donny
2019-04-22 20:46:32 +08:00
commit 49ab8aadd1
25441 changed files with 4055000 additions and 0 deletions

View File

@@ -0,0 +1,26 @@
package medal
import (
"context"
"fmt"
"net/url"
"time"
"go-common/app/job/main/usersuit/model"
"go-common/library/log"
)
// UpInfoData .
func (d *Dao) UpInfoData(c context.Context) (res *model.UpInfo, err error) {
params := url.Values{}
yesterday := time.Now().AddDate(0, 0, -1).Format("2006-01-02")
if err = d.client.Get(c, fmt.Sprintf(d.updateInfo, yesterday), "", params, &res); err != nil {
log.Error("GetWearedfansMedal(%s) error(%v)", d.updateInfo+"?"+params.Encode(), err)
return
}
if res.Code != 0 {
log.Error("GetWearedfansMedal(%s) res(%d)", d.updateInfo+"?"+params.Encode(), res.Code)
}
log.Info("GetWearedfansMedal(%s) res(%+v)", d.updateInfo+"?"+params.Encode(), res)
return
}