func (this *Promotion) CreateCoupon(val *promotion.ValueCoupon) promotion.ICoupon { val.PartnerId = this.GetAggregateRootId() val.CreateTime = time.Now().Unix() val.Amount = val.TotalAmount return newCoupon(val, this.promRep, this.memberRep) }