aa
This commit is contained in:
@@ -33,6 +33,7 @@ type tJdStoreInfo struct {
|
||||
RealLastOperator string
|
||||
SyncStatus int
|
||||
VendorStoreName string
|
||||
BrandName string
|
||||
}
|
||||
|
||||
var (
|
||||
@@ -127,9 +128,11 @@ func (p *PurchaseHandler) UpdateStore(db *dao.DaoDB, storeID int, userName strin
|
||||
t1.*, city.jd_code jd_city_code, district.jd_code jd_district_code,
|
||||
t2.status jd_store_status, t2.vendor_store_id, IF(t1.updated_at > t2.updated_at, t1.last_operator,
|
||||
t2.last_operator) real_last_operator,
|
||||
t2.sync_status, t2.freight_deduction_pack, t2.vendor_org_code, t2.vendor_store_name
|
||||
t2.sync_status, t2.freight_deduction_pack, t2.vendor_org_code, t2.vendor_store_name,
|
||||
t3.name brand_name
|
||||
FROM store t1
|
||||
JOIN store_map t2 ON t1.id = t2.store_id AND t2.vendor_id = ? AND (t2.deleted_at = ?)
|
||||
LEFT JOIN brand t3 ON t3.id = t1.brand_id
|
||||
LEFT JOIN place city ON t1.city_code = city.code
|
||||
LEFT JOIN place district ON t1.district_code = district.code
|
||||
WHERE t1.id = ?
|
||||
@@ -159,7 +162,11 @@ func (p *PurchaseHandler) UpdateStore(db *dao.DaoDB, storeID int, userName strin
|
||||
if store.VendorStoreName != "" {
|
||||
storeParams.StationName = store.VendorStoreName
|
||||
} else {
|
||||
storeParams.StationName = jxutils.ComposeStoreName(store.Name, model.VendorIDJD)
|
||||
if store.BrandID != 1 {
|
||||
storeParams.StationName = store.Name
|
||||
} else {
|
||||
storeParams.StationName = jxutils.ComposeStoreName(store.Name, model.VendorIDJD)
|
||||
}
|
||||
}
|
||||
storeParams.StationName = utils.LimitUTF8StringLen(storeParams.StationName, jdapi.MaxStoreNameLen)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user