Update sales tax report

This commit is contained in:
Matt-Yorkley
2021-02-14 16:26:50 +00:00
parent f956aca82f
commit 55db911334
2 changed files with 2 additions and 2 deletions

View File

@@ -96,8 +96,7 @@ module OpenFoodNetwork
end
def shipping_cost_for(order)
shipping_cost = order.adjustments.find_by(label: "Shipping").andand.amount
shipping_cost.nil? ? 0.0 : shipping_cost
order.shipments.first&.cost || 0.0
end
def tax_included_in(line_item)

View File

@@ -1,5 +1,6 @@
# frozen_string_literal: true
require 'spec_helper'
require 'open_food_network/sales_tax_report'
module OpenFoodNetwork