Skip to content

Commit

Permalink
Merge pull request #1197 from internetee/invalid-vat-label-in-pdf
Browse files Browse the repository at this point in the history
fixed invalid vat label in pdf
  • Loading branch information
vohmar authored Jan 4, 2024
2 parents 37f1707 + 95c31b5 commit 9cb78c5
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 6 deletions.
1 change: 0 additions & 1 deletion app/models/invoice.rb
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,6 @@ def tax_fresh_rate
end
end


def filename
return unless title

Expand Down
6 changes: 1 addition & 5 deletions app/views/common/pdf.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -269,11 +269,7 @@
<td scope="col"></td>
<td scope="col"><%= t('invoices.vat_amount') %></td>
<td>
<%# if @invoice.billing_profile.present? %>
<%#= number_to_percentage(@invoice.billing_profile.vat_rate * 100, precision: 0) %>
<%# else %>
<%= number_to_percentage(@invoice.billing_vat_rate * 100, precision: 0) %>
<%# end %>
<%= number_to_percentage(@invoice.vat_rate * 100, precision: 0) %>
</td>
<td scope="col"><%= t('offers.price_in_currency', price: @invoice.vat) %></td>
</tr>
Expand Down

0 comments on commit 9cb78c5

Please sign in to comment.