- SplitSkuName don't use comment as name
- add DownloadFileByURL - refactor UploadWeimobImg4SkuName - ignore RefreshMissingDadaStores error - add BuildSkuFromEbaiStore
This commit is contained in:
@@ -1,8 +1,6 @@
|
||||
package cms
|
||||
|
||||
import (
|
||||
"crypto/md5"
|
||||
"fmt"
|
||||
"strconv"
|
||||
"time"
|
||||
|
||||
@@ -80,7 +78,7 @@ func GetQiniuUploadToken(ctx *jxcontext.Context, suffix, hashCode string) (upTok
|
||||
upTokenInfo = map[string]interface{}{
|
||||
"token": putPolicy.UploadToken(api.QiniuAPI),
|
||||
"expires": putPolicy.Expires,
|
||||
"fileName": genPicFileName(suffix),
|
||||
"fileName": jxutils.GenPicFileName(suffix),
|
||||
"hit": imgURL != "",
|
||||
"img": imgURL,
|
||||
}
|
||||
@@ -145,8 +143,3 @@ func UpdatePlace(ctx *jxcontext.Context, placeCode int, payload map[string]inter
|
||||
func GetCoordinateDistrictCode(ctx *jxcontext.Context, lng, lat float64) (code int, err error) {
|
||||
return api.AutonaviAPI.GetCoordinateDistrictCode(lng, lat), nil
|
||||
}
|
||||
|
||||
/////
|
||||
func genPicFileName(suffix string) string {
|
||||
return fmt.Sprintf("%x%s", md5.Sum([]byte(utils.GetUUID()+suffix)), suffix)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user