diff --git a/modules/items/modelitems.go b/modules/items/modelitems.go index 12d825b06..d2d9a2ee1 100644 --- a/modules/items/modelitems.go +++ b/modules/items/modelitems.go @@ -323,6 +323,9 @@ func (this *ModelItemsComp) addItemToUserPack(uid string, items []*pb.DB_UserIte CTime: time.Now().Unix(), IsNewItem: isNew, } + if conf.Time > 0 { + grid.ETime = time.Now().Add(time.Minute * time.Duration(conf.Time)).Unix() + } items = append(items, grid) add = append(add, grid) leftnum = 0 @@ -337,6 +340,9 @@ func (this *ModelItemsComp) addItemToUserPack(uid string, items []*pb.DB_UserIte CTime: time.Now().Unix(), IsNewItem: isNew, } + if conf.Time > 0 { + grid.ETime = time.Now().Add(time.Minute * time.Duration(conf.Time)).Unix() + } items = append(items, grid) add = append(add, grid) index++