Created
June 5, 2019 03:06
-
-
Save hernandezalek/d778750cc8952ad35383cdcc06045c56 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<table id="ejemplo"> | |
<thead> | |
<tr> | |
<th>N° Factura</th> | |
<th>Tipo Factura</th> | |
<th>Cliente</th> | |
<th>Efectivo</th> | |
<th>Credito</th> | |
<th>Ejecutivo/a de venta</th> | |
</tr> | |
</thead> | |
<tbody> | |
<% if @outputs.any? %> | |
<% @outputs.each do |output| %> | |
<tr> | |
<td><%= output.invoice_number %></td> | |
<td><%= output.invoice_type.name %></td> | |
<td><%= output.customer.name %></td> | |
<td><% if output.payment_type.id == 1 %><%= output.total.to_i %><% else %>0<% end %></td> <td><% if output.payment_type.id == 2 %><%= output.total.to_i %><% else %>0<% end %></td> | |
<td><%= output.employee.name %></td> | |
</tr> | |
<% end %> | |
<% else %> | |
<tr> | |
<td>No se ha encontrado ningun registro</td> | |
</tr> | |
<% end %> | |
</tbody> | |
<tfoot> | |
<tr> | |
<th></th> | |
<th></th> | |
<th></th> | |
<th>Total: <span id="totalEfectivo"></span></th> | |
<th>Total: <span id="totalCredito"></span></th> | |
<th ><span id="total"></span></th> | |
</tr> | |
</tfoot> | |
</table> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment