Commit cf8a87c861c06a3b95494eda12d8a927e07b2928
1 parent
abf50a674a
Exists in
master
and in
1 other branch
Agregada nueva columna en la vista.
Showing
1 changed file
with
2 additions
and
0 deletions
 
Show diff stats
src/views/modal-busqueda-productos.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 my-1">Búsqueda de Productos</h5> | 4 | <h5 class="modal-title my-1">Búsqueda de Productos</h5> | 
| 5 | </div> | 5 | </div> | 
| 6 | <div class="input-group col-lg-6 pr-0 my-2"> | 6 | <div class="input-group col-lg-6 pr-0 my-2"> | 
| 7 | <input | 7 | <input | 
| 8 | ladda="searchLoading" | 8 | ladda="searchLoading" | 
| 9 | type="text" | 9 | type="text" | 
| 10 | class="form-control form-control-sm" | 10 | class="form-control form-control-sm" | 
| 11 | id="search" | 11 | id="search" | 
| 12 | placeholder="Busqueda" | 12 | placeholder="Busqueda" | 
| 13 | ng-model="filters" | 13 | ng-model="filters" | 
| 14 | ng-change="search()" | 14 | ng-change="search()" | 
| 15 | ng-keydown="busquedaDown($event.keyCode)" | 15 | ng-keydown="busquedaDown($event.keyCode)" | 
| 16 | ng-keypress="busquedaPress($event.keyCode)" | 16 | ng-keypress="busquedaPress($event.keyCode)" | 
| 17 | foca-focus="selectedProducto == -1" | 17 | foca-focus="selectedProducto == -1" | 
| 18 | ng-focus="selectedProducto = -1" | 18 | ng-focus="selectedProducto = -1" | 
| 19 | teclado-virtual | 19 | teclado-virtual | 
| 20 | > | 20 | > | 
| 21 | <div class="input-group-append"> | 21 | <div class="input-group-append"> | 
| 22 | <button | 22 | <button | 
| 23 | ladda="searchLoading" | 23 | ladda="searchLoading" | 
| 24 | data-spinner-color="#FF0000" | 24 | data-spinner-color="#FF0000" | 
| 25 | class="btn btn-outline-secondary" | 25 | class="btn btn-outline-secondary" | 
| 26 | type="button" | 26 | type="button" | 
| 27 | title="Buscar" | 27 | title="Buscar" | 
| 28 | ng-click="busquedaPress(13)" | 28 | ng-click="busquedaPress(13)" | 
| 29 | > | 29 | > | 
| 30 | <i class="fa fa-search" aria-hidden="true"></i> | 30 | <i class="fa fa-search" aria-hidden="true"></i> | 
| 31 | </button> | 31 | </button> | 
| 32 | </div> | 32 | </div> | 
| 33 | </div> | 33 | </div> | 
| 34 | </div> | 34 | </div> | 
| 35 | </div> | 35 | </div> | 
| 36 | <div class="modal-body" id="modal-body"> | 36 | <div class="modal-body" id="modal-body"> | 
| 37 | 37 | ||
| 38 | <div ng-show="!primerBusqueda"> | 38 | <div ng-show="!primerBusqueda"> | 
| 39 | Debe realizar una primer búsqueda. | 39 | Debe realizar una primer búsqueda. | 
| 40 | </div> | 40 | </div> | 
| 41 | 41 | ||
| 42 | <table ng-show="primerBusqueda" class="table table-striped table-sm"> | 42 | <table ng-show="primerBusqueda" class="table table-striped table-sm"> | 
| 43 | <thead> | 43 | <thead> | 
| 44 | <tr> | 44 | <tr> | 
| 45 | <th ng-hide="soloMostrar">Código</th> | 45 | <th ng-hide="soloMostrar">Código</th> | 
| 46 | <th>Descripción</th> | 46 | <th>Descripción</th> | 
| 47 | <th class="text-right">P. Lista</th> | ||
| 47 | <th class="text-right">P. Base</th> | 48 | <th class="text-right">P. Base</th> | 
| 48 | <th ng-hide="soloMostrar"></th> | 49 | <th ng-hide="soloMostrar"></th> | 
| 49 | </tr> | 50 | </tr> | 
| 50 | </thead> | 51 | </thead> | 
| 51 | <tbody> | 52 | <tbody> | 
| 52 | <tr ng-show="currentPageProductos.length == 0 && primerBusqueda"> | 53 | <tr ng-show="currentPageProductos.length == 0 && primerBusqueda"> | 
| 53 | <td colspan="5"> | 54 | <td colspan="5"> | 
| 54 | No se encontraron resultados. | 55 | No se encontraron resultados. | 
| 55 | </td> | 56 | </td> | 
| 56 | </tr> | 57 | </tr> | 
| 57 | <tr class="selectable" | 58 | <tr class="selectable" | 
| 58 | ng-repeat="(key,producto) in currentPageProductos" | 59 | ng-repeat="(key,producto) in currentPageProductos" | 
| 59 | ng-click="select(producto)"> | 60 | ng-click="select(producto)"> | 
| 60 | <td ng-bind="producto.sector + '-' + producto.codigo" | 61 | <td ng-bind="producto.sector + '-' + producto.codigo" | 
| 61 | ng-hide="soloMostrar"></td> | 62 | ng-hide="soloMostrar"></td> | 
| 62 | <td ng-bind="producto.descripcion"></td> | 63 | <td ng-bind="producto.descripcion"></td> | 
| 63 | <td class="text-right" ng-bind="producto.precio | number: 2"></td> | 64 | <td class="text-right" ng-bind="producto.precio | number: 2"></td> | 
| 65 | <td class="text-right" ng-bind="producto.precioBase | number: 2"></td> | ||
| 64 | <td class="d-md-none text-primary"> | 66 | <td class="d-md-none text-primary"> | 
| 65 | <i class="fa fa-circle-thin" aria-hidden="true"></i> | 67 | <i class="fa fa-circle-thin" aria-hidden="true"></i> | 
| 66 | </td> | 68 | </td> | 
| 67 | <td class="d-none d-md-table-cell"> | 69 | <td class="d-none d-md-table-cell"> | 
| 68 | <button | 70 | <button | 
| 69 | type="button" | 71 | type="button" | 
| 70 | class="btn btn-xs p-1 float-right" | 72 | class="btn btn-xs p-1 float-right" | 
| 71 | title="Seleccionar" | 73 | title="Seleccionar" | 
| 72 | ng-class="{ | 74 | ng-class="{ | 
| 73 | 'btn-secondary': selectedProducto != key, | 75 | 'btn-secondary': selectedProducto != key, | 
| 74 | 'btn-primary': selectedProducto == key | 76 | 'btn-primary': selectedProducto == key | 
| 75 | }" | 77 | }" | 
| 76 | foca-focus="selectedProducto == {{key}}" | 78 | foca-focus="selectedProducto == {{key}}" | 
| 77 | ng-keydown="itemProducto($event.keyCode)" | 79 | ng-keydown="itemProducto($event.keyCode)" | 
| 78 | ng-hide="soloMostrar"> | 80 | ng-hide="soloMostrar"> | 
| 79 | <i class="fa fa-circle-thin" aria-hidden="true"></i> | 81 | <i class="fa fa-circle-thin" aria-hidden="true"></i> | 
| 80 | </button> | 82 | </button> | 
| 81 | </td> | 83 | </td> | 
| 82 | </tr> | 84 | </tr> | 
| 83 | </tbody> | 85 | </tbody> | 
| 84 | </table> | 86 | </table> | 
| 85 | 87 | ||
| 86 | </div> | 88 | </div> | 
| 87 | <div class="modal-footer py-1"> | 89 | <div class="modal-footer py-1"> | 
| 88 | <nav ng-show="currentPageProductos.length > 0 && primerBusqueda" class="mr-auto"> | 90 | <nav ng-show="currentPageProductos.length > 0 && primerBusqueda" class="mr-auto"> | 
| 89 | <ul class="pagination pagination-sm justify-content mb-0"> | 91 | <ul class="pagination pagination-sm justify-content mb-0"> | 
| 90 | <li class="page-item" ng-class="{'disabled': currentPage == 1}"> | 92 | <li class="page-item" ng-class="{'disabled': currentPage == 1}"> | 
| 91 | <a class="page-link" href="javascript:void();" ng-click="selectPage(currentPage - 1)"> | 93 | <a class="page-link" href="javascript:void();" ng-click="selectPage(currentPage - 1)"> | 
| 92 | <span aria-hidden="true">«</span> | 94 | <span aria-hidden="true">«</span> | 
| 93 | <span class="sr-only">Anterior</span> | 95 | <span class="sr-only">Anterior</span> | 
| 94 | </a> | 96 | </a> | 
| 95 | </li> | 97 | </li> | 
| 96 | <li | 98 | <li | 
| 97 | class="page-item" | 99 | class="page-item" | 
| 98 | ng-repeat="pagina in paginas" | 100 | ng-repeat="pagina in paginas" | 
| 99 | ng-class="{'active': pagina == currentPage}" | 101 | ng-class="{'active': pagina == currentPage}" | 
| 100 | > | 102 | > | 
| 101 | <a | 103 | <a | 
| 102 | class="page-link" | 104 | class="page-link" | 
| 103 | href="javascript:void();" | 105 | href="javascript:void();" | 
| 104 | ng-click="selectPage(pagina)" | 106 | ng-click="selectPage(pagina)" | 
| 105 | ng-bind="pagina" | 107 | ng-bind="pagina" | 
| 106 | ></a> | 108 | ></a> | 
| 107 | </li> | 109 | </li> | 
| 108 | <li class="page-item" ng-class="{'disabled': currentPage == lastPage}"> | 110 | <li class="page-item" ng-class="{'disabled': currentPage == lastPage}"> | 
| 109 | <a class="page-link" href="javascript:void();" ng-click="selectPage(currentPage + 1)"> | 111 | <a class="page-link" href="javascript:void();" ng-click="selectPage(currentPage + 1)"> | 
| 110 | <span aria-hidden="true">»</span> | 112 | <span aria-hidden="true">»</span> | 
| 111 | <span class="sr-only">Siguiente</span> | 113 | <span class="sr-only">Siguiente</span> | 
| 112 | </a> | 114 | </a> | 
| 113 | </li> | 115 | </li> | 
| 114 | </ul> | 116 | </ul> | 
| 115 | </nav> | 117 | </nav> | 
| 116 | <button class="btn btn-sm btn-secondary my-1" type="button" ng-click="cancel()">Volver</button> | 118 | <button class="btn btn-sm btn-secondary my-1" type="button" ng-click="cancel()">Volver</button> | 
| 117 | </div> | 119 | </div> | 
| 118 | 120 |