'add coupon info into coupon_redemption model'

@classmethod
def add_coupon_redemption(cls, coupon, order, cart_items):

    is_redemption_applied = False
    coupon_redemptions = cls.objects.filter(order=order, user=order.user)
    for coupon_redemption in coupon_redemptions:
        if ((coupon_redemption.coupon.code != coupon.code) or (coupon_redemption.coupon.id == coupon.id)):
            log.exception(u"Coupon    redemption    already    exist    for    user    '%s'    against    order    id    '%s'", order.user.username, order.id)
            raise MultipleCouponsNotAllowedException
    for item in cart_items:
        if item.course_id:
            if (item.course_id == coupon.course_id):
                coupon_redemption = cls(order=order, user=order.user, coupon=coupon)
                coupon_redemption.save()
                discount_price = cls.get_discount_price(coupon.percentage_discount, item.unit_cost)
                item.list_price = item.unit_cost
                item.unit_cost = discount_price
                item.save()
                log.info(u"Discount    generated    for    user    %s    against    order    id    '%s'", order.user.username, order.id)
                is_redemption_applied = True
                return is_redemption_applied
    return is_redemption_applied
