module PurchasesHelper
  def purchase_status(purchase)
    case purchase.status
    when "paid"
      content_tag(:span, "Pagada", class: "label label-sm label-success")
    when "cancelled"
      content_tag(:span, "Cancelada", class: "label label-sm label-danger")
    when "parcial"
      content_tag(:span, "Abonada", class: "label label-sm label-warning")
    when "notpaid"
      content_tag(:span, "Pte. de pago", class: "label label-sm label-default")
    end
  end
end
