Move code to coupon model