|
|
@@ -4,25 +4,37 @@
|
|
|
}
|
|
|
|
|
|
.left {
|
|
|
- width: 70%;
|
|
|
- font-size: 10px;
|
|
|
+ width: 60%;
|
|
|
+ font-size: 12px;
|
|
|
min-height:5px;
|
|
|
}
|
|
|
|
|
|
.right {
|
|
|
- width: 30%;
|
|
|
- font-size: 12px;
|
|
|
+ width: 40%;
|
|
|
+ font-size: 14px;
|
|
|
font-weight: bold;
|
|
|
}
|
|
|
</style>
|
|
|
<div class='pdf-body'>
|
|
|
<% @products.each do |obj| %>
|
|
|
<% (1..obj['print']).each do |i| %>
|
|
|
- <div class="text-center"><%= wicked_pdf_barcode_image("#{obj['product'].barcode}.png", options = { width: 150, height: 50 }) %></div>
|
|
|
- <p style="margin:0px"><%= obj['product'].name %></p>
|
|
|
+ <div class="text-center" style="padding-top:5px;margin-bottom:5px">
|
|
|
+ <%= wicked_pdf_barcode_image("#{obj['product'].barcode}.png", options = { width: 150, height: 50 }) %>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <p style="margin-left:0px;margin-right:0px;margin-top:0px;margin-bottom:10px"><%= obj['product'].name %></p>
|
|
|
+
|
|
|
<div class="row">
|
|
|
- <div class="column left"><%= obj['product'].display_attributes %></div>
|
|
|
- <div class="column right"><%= number_to_currency(obj['price'], precision: 2) %></div>
|
|
|
+ <div class="column left">
|
|
|
+ <ul style="list-style: none; margin:0px; padding:0px">
|
|
|
+ <% obj['product'].attrs_array.each do |attribute| %>
|
|
|
+ <li><%= attribute %></li>
|
|
|
+ <% end %>
|
|
|
+ </ul>
|
|
|
+ </div>
|
|
|
+ <div class="column right">
|
|
|
+ <span style="margin:auto"><%= number_to_currency(obj['price'], precision: 2) %></span>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
<br>
|
|
|
<br>
|