Commit 084b2e4ec8f0cdbf987909ecc4dcd6bf5d2be568

Authored by Eric Fernandez
Exists in master and in 1 other branch develop

Merge branch 'master' into 'develop'

Master(efernandez)

See merge request !25
src/views/foca-modal-factura.html
1 <div class="modal-header py-1"> 1 <div class="modal-header py-1">
2 <div class="row w-100"> 2 <div class="row w-100">
3 <div class="col-lg-6"> 3 <div class="col-lg-6">
4 <h5 class="modal-title">Búsqueda de Comprobantes</h5> 4 <h5 class="modal-title">Búsqueda de Comprobantes</h5>
5 </div> 5 </div>
6 </div> 6 </div>
7 </div> 7 </div>
8 <div class="modal-body d-flex" 8 <div class="modal-body d-flex" id="modal-body">
9 id="modal-body">
10 <div 9 <div
11 ladda="!primerBusqueda" 10 ladda="!primerBusqueda"
12 data-spinner-color="#000000" 11 data-spinner-color="#000000"
13 data-spinner-size="30" 12 data-spinner-size="30"
14 class="w-100 ladda-w-100"> 13 class="w-100 ladda-w-100 overflow-auto">
15 <table ng-show="primerBusqueda" class="table table-striped table-sm"> 14 <table ng-show="primerBusqueda" class="table table-striped table-sm">
16 <thead> 15 <thead>
17 <tr> 16 <tr>
18 <th>Comprobante</th> 17 <th>Comprobante</th>
19 <th>Vencimiento</th> 18 <th>Vencimiento</th>
20 <th class="text-right">Importe</th> 19 <th class="text-right">Importe</th>
21 <th class="text-right">Saldo</th> 20 <th class="text-right">Saldo</th>
22 <th class="text-right"></th> 21 <th class="text-right"></th>
23 <th class="text-right"></th> 22 <th class="text-right"></th>
24 <th class="text-right"></th> 23 <th class="text-right"></th>
25 </tr> 24 </tr>
26 </thead> 25 </thead>
27 <tbody> 26 <tbody>
28 <tr ng-show="currentPageFacturas.length == 0 && primerBusqueda"> 27 <tr ng-show="currentPageFacturas.length == 0 && primerBusqueda">
29 <td colspan="5"> 28 <td colspan="5">
30 No se encontraron resultados. 29 No se encontraron resultados.
31 </td> 30 </td>
32 </tr> 31 </tr>
33 <tr class="selectable" 32 <tr class="selectable"
34 ng-repeat="(key, factura) in currentPageFacturas"> 33 ng-repeat="(key, factura) in currentPageFacturas">
35 <td ng-click="factura.checked = !factura.checked">{{factura.numeroFactura}} {{factura.FECHA_COMPROBANTE | date : 'dd/MM/yyyy' : 'GMT'}}</td> 34 <td ng-click="factura.checked = !factura.checked">{{factura.numeroFactura}} {{factura.FECHA_COMPROBANTE | date : 'dd/MM/yyyy' : 'GMT'}}</td>
36 <td ng-click="factura.checked = !factura.checked">{{(factura.TCO == 'FT') ? factura.NCU + ' - ' : ''}}{{factura.FEV | date : 'dd/MM/yyyy' : 'GMT'}}</td> 35 <td ng-click="factura.checked = !factura.checked">{{(factura.TCO == 'FT') ? factura.NCU + ' - ' : ''}}{{factura.FEV | date : 'dd/MM/yyyy' : 'GMT'}}</td>
37 <td class="text-right" 36 <td class="text-right"
38 ng-click="factura.checked = !factura.checked"> 37 ng-click="factura.checked = !factura.checked">
39 {{ (factura.IPA_SHOW / parametrosFactura.cotizacion.cotizacion.VENDEDOR) | number:2 }} 38 {{ (factura.IPA_SHOW / parametrosFactura.cotizacion.cotizacion.VENDEDOR) | number:2 }}
40 <span ng-class="{'invisible': factura.IPA >= 0}">-</span> 39 <span ng-class="{'invisible': factura.IPA >= 0}">-</span>
41 </td> 40 </td>
42 <td class="text-right" 41 <td class="text-right"
43 ng-click="factura.checked = !factura.checked"> 42 ng-click="factura.checked = !factura.checked">
44 {{ factura.saldo_show | number:2 }} 43 {{ factura.saldo_show | number:2 }}
45 <span ng-class="{'invisible': factura.saldo >= 0}">-</span> 44 <span ng-class="{'invisible': factura.saldo >= 0}">-</span>
46 </td> 45 </td>
47 <td class="text-right"> 46 <td class="text-right">
48 <input 47 <input
49 ng-class="{ 48 ng-class="{
50 'btn-secondary': selectedFactura != key, 49 'btn-secondary': selectedFactura != key,
51 'btn-primary': selectedFactura == key}" 50 'btn-primary': selectedFactura == key}"
52 ng-keydown="itemFactura($event.keyCode)" 51 ng-keydown="itemFactura($event.keyCode)"
53 foca-focus="selectedFactura == {{key}}" 52 foca-focus="selectedFactura == {{key}}"
54 type="checkbox" 53 type="checkbox"
55 ng-model="factura.checked" 54 ng-model="factura.checked"
56 /> 55 />
57 </td> 56 </td>
58 <td> 57 <td>
59 <button 58 <button
60 class="btn p-1" 59 class="btn p-1"
61 ng-click="verFactura(factura)" 60 ng-click="verFactura(factura)"
62 title="Ver comprobante" 61 title="Ver comprobante"
63 > 62 >
64 <i class="fa fa-eye" aria-hidden="true"></i> 63 <i class="fa fa-eye" aria-hidden="true"></i>
65 </button> 64 </button>
66 </td> 65 </td>
67 <td> 66 <td>
68 <button 67 <button
69 class="btn p-1" 68 class="btn p-1"
70 ng-click="enviarMail(factura)" 69 ng-click="enviarMail(factura)"
71 title="Enviar comprobante por mail" 70 title="Enviar comprobante por mail"
72 > 71 >
73 <i class="fa fa-envelope-o" aria-hidden="true"></i> 72 <i class="fa fa-envelope-o" aria-hidden="true"></i>
74 </button> 73 </button>
75 </td> 74 </td>
76 </tr> 75 </tr>
77 </tbody> 76 </tbody>
78 </table> 77 </table>
79 </div> 78 </div>
80 </div> 79 </div>
81 <div class="modal-footer py-1"> 80 <div class="modal-footer py-1">
82 <nav ng-show="currentPageFacturas.length > 0 && primerBusqueda" class="mr-auto"> 81 <nav ng-show="currentPageFacturas.length > 0 && primerBusqueda" class="mr-auto">
83 <ul class="pagination pagination-sm justify-content mb-0"> 82 <ul class="pagination pagination-sm justify-content mb-0">
84 <li class="page-item" ng-class="{'disabled': currentPage == 1}"> 83 <li class="page-item" ng-class="{'disabled': currentPage == 1}">
85 <a class="page-link" href="javascript:void();" ng-click="selectPage(currentPage - 1)"> 84 <a class="page-link" href="javascript:void();" ng-click="selectPage(currentPage - 1)">
86 <span aria-hidden="true">&laquo;</span> 85 <span aria-hidden="true">&laquo;</span>
87 <span class="sr-only">Anterior</span> 86 <span class="sr-only">Anterior</span>
88 </a> 87 </a>
89 </li> 88 </li>
90 <li 89 <li
91 class="page-item" 90 class="page-item"
92 ng-repeat="pagina in paginas" 91 ng-repeat="pagina in paginas"
93 ng-class="{'active': pagina == currentPage}" 92 ng-class="{'active': pagina == currentPage}"
94 > 93 >
95 <a 94 <a
96 class="page-link" 95 class="page-link"
97 href="javascript:void();" 96 href="javascript:void();"
98 ng-click="selectPage(pagina)" 97 ng-click="selectPage(pagina)"
99 ng-bind="pagina" 98 ng-bind="pagina"
100 ></a> 99 ></a>
101 </li> 100 </li>
102 <li class="page-item" ng-class="{'disabled': currentPage == lastPage}"> 101 <li class="page-item" ng-class="{'disabled': currentPage == lastPage}">
103 <a class="page-link" href="javascript:void();" ng-click="selectPage(currentPage + 1)"> 102 <a class="page-link" href="javascript:void();" ng-click="selectPage(currentPage + 1)">
104 <span aria-hidden="true">&raquo;</span> 103 <span aria-hidden="true">&raquo;</span>
105 <span class="sr-only">Siguiente</span> 104 <span class="sr-only">Siguiente</span>
106 </a> 105 </a>
107 </li> 106 </li>
108 </ul> 107 </ul>
109 </nav> 108 </nav>
110 <button class="btn btn-sm btn-secondary" type="button" ng-click="cancel()">Cancelar</button> 109 <button class="btn btn-sm btn-secondary" type="button" ng-click="cancel()">Cancelar</button>
111 <button 110 <button
112 class="btn btn-sm btn-primary" 111 class="btn btn-sm btn-primary"
113 type="button" 112 type="button"
114 ng-click="aceptar()" 113 ng-click="aceptar()"
115 ng-disabled="tieneAlMenosUno()" 114 ng-disabled="tieneAlMenosUno()"
116 >Aceptar</button> 115 >Aceptar</button>
117 </div> 116 </div>
118 117