if sale
  json.sale_id sale.id
  json.cashier_name sale.cashier_name
  json.receipt_no sale.receipt_no
  json.receipt_date sale.receipt_date.try(:utc)

  json.customer_id  sale.customer_id
  json.customer_name sale.try(:customer).try(:name)

  json.sale_status  sale.sale_status

  json.total_amount sale.total_amount

  json.discount_type  sale.discount_type.capitalize
  json.total_discount sale.total_discount

  json.tax_type       sale.tax_type
  json.total_tax      sale.total_tax

  json.grand_total    sale.grand_total

  json.rounding_adjustment  sale.rounding_adjustment

  json.amount_received  sale.amount_received
  json.amount_changed   sale.amount_changed

  json.shift_sale_id  sale.shift_sale_id

  json.sale_items sale.sale_items.includes(:discount_item).where(status: nil), partial: "api/sale_items/sale_item", as: :sale_item

  json.sale_taxes sale.sale_taxes, partial: "api/sale_taxes/sale_tax", as: :sale_tax
end
