同步京东门店
This commit is contained in:
@@ -2762,8 +2762,14 @@ type tJdStoreInfo struct {
|
||||
}
|
||||
|
||||
func UpdateJdStoreNameAll(ctx *jxcontext.Context) (err error) {
|
||||
storeMap := map[int]int{
|
||||
100653: 100653,
|
||||
100037: 100037,
|
||||
100968: 100968,
|
||||
}
|
||||
db := dao.GetDB()
|
||||
userName := ctx.GetUserName()
|
||||
for _, v := range storeMap {
|
||||
var stores []*tJdStoreInfo
|
||||
sql := `
|
||||
SELECT
|
||||
@@ -2778,7 +2784,7 @@ func UpdateJdStoreNameAll(ctx *jxcontext.Context) (err error) {
|
||||
WHERE t1.id = ?
|
||||
ORDER BY t2.updated_at
|
||||
`
|
||||
if err = dao.GetRows(db, &stores, sql, model.VendorIDJD, 102108); err == nil {
|
||||
if err = dao.GetRows(db, &stores, sql, model.VendorIDJD, v); err == nil {
|
||||
for _, store := range stores {
|
||||
a := jd.GetAPI(store.VendorOrgCode)
|
||||
storeParams := &jdapi.OpStoreParams{
|
||||
@@ -2831,5 +2837,6 @@ func UpdateJdStoreNameAll(ctx *jxcontext.Context) (err error) {
|
||||
err = errList.GetErrListAsOne()
|
||||
}
|
||||
}
|
||||
}
|
||||
return err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user