Files
old-ribica/front-api/views/cart_trello.erb
2016-03-16 12:12:26 +01:00

61 lines
1.2 KiB
Plaintext

<%
dd = @cart.delivery_destination
c = @cart
%>
**Ime:** <%= dd.name %>
**Adresa:**
<%= dd.address %>
<%= dd.place.to_s.strip %> <%= Place.name_from_code(dd.place.to_s) %>
Bosna i Hercegovina
**Email: **<%= dd.email %>
**Telefon: ** +387 <%= dd.phone %>
**Plaćanje: ** <%= dd.get_payment_string %>
**Napomena: **
<%= dd.note %>
<% if dd.gift %>
**Poklon **
**Name: **<%= dd.recipient_name %>
**Postal code: **<%= dd.recipient_postal_code %>
**Place: **<%= dd.recipient_place %>
**Address: **<%= dd.recipient_address %>
**Phone: **<%= dd.recipient_phone %>
**Email: **<%= dd.recipient_email %>
<% end %>
<% if dd.instant_delivery %>
**Naručeno:** <%= @cart.updated_at.in_time_zone("Europe/Sarajevo").strftime("%A %d.%m.%Y. %H:%M") %>
<% end %>
<% if dd.instant_delivery %>
** OVO JE NARUDŽBA ZA INSTANT DOSTAVU **
<% end %>
<% @cart.item_in_carts.each do |iic| %>
**<%= iic.item.code %> <%= iic.item.name %>**
**<%= iic.count %>** x <%= Helper.money(iic.price) %> = <%= Helper.money(iic.count * iic.price) %>
<% end %>
Dostava
1 x <%= Helper.money(c.delivery_cost) %> = <%= Helper.money(c.delivery_cost) %>
**UKUPNO:** <%= Helper.money(c.total) %>
[Pogledati OVAJ LINK](https://www.ribica.ba/backoffice/carts/<%= @cart.id %>)
<% end %>