diff --git a/business/jxstore/cms/store.go b/business/jxstore/cms/store.go index e508cadf2..15ebdccca 100644 --- a/business/jxstore/cms/store.go +++ b/business/jxstore/cms/store.go @@ -1231,7 +1231,7 @@ func UpdateOrCreateCourierStores(ctx *jxcontext.Context, storeID int, isForceUpd } func formalizeStore4Courier(storeDetail *dao.StoreDetail2) *dao.StoreDetail2 { - storeDetail.Name = storeDetail.Name + "-" + storeDetail.VendorStoreID + storeDetail.Name = fmt.Sprintf("%s-%s-%s", model.ShopChineseNames[model.VendorIDJD], storeDetail.CityName, storeDetail.Name) if storeDetail.PayeeName == "" { storeDetail.PayeeName = "店主" } @@ -1521,60 +1521,6 @@ func SendAlarmVendorSnapshot(ctx *jxcontext.Context, parentTask tasksch.ITask, p } } - ////// - // curSnapshotMap := make(map[string]*model.VendorStoreSnapshot) - // curSnapshotGroupMap := make(map[int][]*model.VendorStoreSnapshot) - // for _, v := range curSnapshotList { - // curSnapshotMap[v.GenMapKey()] = v - // curSnapshotGroupMap[v.StoreID] = append(curSnapshotGroupMap[v.StoreID], v) - // } - - // storeDetailMap := make(map[int]*dao.StoreDetail) - // userMap := make(map[string]map[int]int) - // alarmMapHandler := func(alarmMap map[int]map[int]*model.VendorStoreSnapshot, v *model.VendorStoreSnapshot) { - // if alarmMap[v.StoreID] == nil { - // alarmMap[v.StoreID] = make(map[int]*model.VendorStoreSnapshot) - // if storeDetailMap[v.StoreID] == nil { - // storeDetail, _ := dao.GetStoreDetail(db, v.StoreID, v.VendorID) - // if storeDetail != nil { - // storeDetailMap[v.StoreID] = storeDetail - // for _, mobile := range []string{storeDetail.Tel1, storeDetail.MarketManPhone, storeDetail.OperatorPhone} { - // if mobile != "" { - // if userMap[mobile] == nil { - // userMap[mobile] = make(map[int]int) - // } - // userMap[mobile][v.StoreID] = 1 - // } - // } - // } - // } - // } - // alarmMap[v.StoreID][v.VendorID] = v - // } - - // alarmMap := make(map[int]map[int]*model.VendorStoreSnapshot) - // for _, v := range prevSnapshotList { - // curSnapshot := curSnapshotMap[v.GenMapKey()] - // if (curSnapshot == nil) || ((v.Status == model.StoreStatusOpened && curSnapshot.Status != model.StoreStatusOpened) || - // curSnapshot.CompareOperationTime(v) < 0) { - // alarmMapHandler(alarmMap, v) - // } - // } - // alarmMap4StatusNotSame := make(map[int]map[int]*model.VendorStoreSnapshot) - // for _, list := range curSnapshotGroupMap { - // if isVendorStoresStatusNotOk(list) { - // for _, v := range list { - // alarmMapHandler(alarmMap4StatusNotSame, v) - // } - // } - // } - - // var mobileList []string - // for mobile := range userMap { - // if mobile != "" && !shouldSkipMobile4SendStoreStatusInfo(mobile) { - // mobileList = append(mobileList, mobile) - // } - // } if len(mobileList) > 0 { const fixTitle = "门店状态变化" title := fmt.Sprintf("%s:%s-->%s", fixTitle, utils.Time2Str(prevSnapshotList[0].SnapshotAt), utils.Time2Str(curSnapshotList[0].SnapshotAt))