- fix GenFakeID
This commit is contained in:
@@ -88,6 +88,7 @@ func (p *MultiStoreHandlerWrapper) UpdateCategory(db *dao.DaoDB, cat *model.SkuC
|
||||
}
|
||||
|
||||
func (p *MultiStoreHandlerWrapper) DeleteSku(db *dao.DaoDB, sku *model.Sku, userName string) (err error) {
|
||||
globals.SugarLogger.Debugf("wrapper DeleteSku, sku:%s", utils.Format4Output(sku, false))
|
||||
if jxutils.IsFakeID(sku.JdID) {
|
||||
return nil
|
||||
}
|
||||
|
||||
@@ -146,7 +146,7 @@ func genFakeID1() int64 {
|
||||
}
|
||||
|
||||
func GenFakeID() int64 {
|
||||
return genFakeID1() * 2
|
||||
return genFakeID1() * 3
|
||||
}
|
||||
|
||||
func IsFakeID(id int64) bool {
|
||||
@@ -154,7 +154,7 @@ func IsFakeID(id int64) bool {
|
||||
return true
|
||||
}
|
||||
multiple := id / genFakeID1()
|
||||
return multiple == 2 || multiple == 3
|
||||
return multiple == 2 || multiple == 3 || multiple == 4
|
||||
}
|
||||
|
||||
func FormalizePageSize(pageSize int) int {
|
||||
|
||||
Reference in New Issue
Block a user