Commit 30ece7f93bf707032f9c4919d73cf941f079c844
Exists in
master
Merge branch 'master' into 'master'
Master (pmarco) See merge request modulos-npm/foca-modal-vehiculo!1
Showing
1 changed file
Show diff stats
src/views/modal-vehiculo.html
| 1 | <div class="modal-header py-1"> | 1 | <div class="modal-header py-1"> |
| 2 | <h5 class="modal-title">Busqueda de Vehiculo</h5> | 2 | <h5 class="modal-title">Busqueda de Vehiculo</h5> |
| 3 | </div> | 3 | </div> |
| 4 | <div class="modal-body" id="modal-body"> | 4 | <div class="modal-body" id="modal-body"> |
| 5 | <div class="input-group"> | 5 | <div class="input-group"> |
| 6 | <input | 6 | <input |
| 7 | ladda="searchLoading" | 7 | ladda="searchLoading" |
| 8 | type="text" | 8 | type="text" |
| 9 | class="form-control" | 9 | class="form-control" |
| 10 | placeholder="Busqueda" | 10 | placeholder="Busqueda" |
| 11 | ng-model="filters" | 11 | ng-model="filters" |
| 12 | ng-change="search()" | 12 | ng-change="search()" |
| 13 | ng-keydown="busquedaDown($event.keyCode)" | 13 | ng-keydown="busquedaDown($event.keyCode)" |
| 14 | ng-keypress="busquedaPress($event.keyCode)" | 14 | ng-keypress="busquedaPress($event.keyCode)" |
| 15 | foca-focus="selectedVehiculo == -1" | 15 | foca-focus="selectedVehiculo == -1" |
| 16 | ng-focus="selectedVehiculo = -1" | 16 | ng-focus="selectedVehiculo = -1" |
| 17 | > | 17 | > |
| 18 | <div class="input-group-append"> | 18 | <div class="input-group-append"> |
| 19 | <button | 19 | <button |
| 20 | ladda="searchLoading" | 20 | ladda="searchLoading" |
| 21 | class="btn btn-outline-secondary" | 21 | class="btn btn-outline-secondary" |
| 22 | type="button" | 22 | type="button" |
| 23 | ng-click="busquedaPress(13)" | 23 | ng-click="busquedaPress(13)" |
| 24 | > | 24 | > |
| 25 | <i class="fa fa-search" aria-hidden="true"></i> | 25 | <i class="fa fa-search" aria-hidden="true"></i> |
| 26 | </button> | 26 | </button> |
| 27 | </div> | 27 | </div> |
| 28 | </div> | 28 | </div> |
| 29 | <table ng-show="primerBusqueda" class="table table-striped table-sm"> | 29 | <table ng-show="primerBusqueda" class="table table-striped table-sm"> |
| 30 | <thead> | 30 | <thead> |
| 31 | <tr> | 31 | <tr> |
| 32 | <th>Tractor</th> | 32 | <th>Tractor</th> |
| 33 | <th>Semi</th> | 33 | <th>Semi</th> |
| 34 | <th>Capacidad</th> | 34 | <th>Capacidad</th> |
| 35 | <th>Cisternado</th> | 35 | <th>Cisternado</th> |
| 36 | </tr> | 36 | </tr> |
| 37 | </thead> | 37 | </thead> |
| 38 | <tbody> | 38 | <tbody> |
| 39 | <tr ng-show="currentPageVehiculos.length == 0 && primerBusqueda"> | 39 | <tr ng-show="currentPageVehiculos.length == 0 && primerBusqueda"> |
| 40 | <td colspan="5"> | 40 | <td colspan="5"> |
| 41 | No se encontraron resultados. | 41 | No se encontraron resultados. |
| 42 | </td> | 42 | </td> |
| 43 | </tr> | 43 | </tr> |
| 44 | <tr class="selectable" | 44 | <tr class="selectable" |
| 45 | ng-repeat="(key,vehiculo) in currentPageVehiculos" | 45 | ng-repeat="(key,vehiculo) in currentPageVehiculos" |
| 46 | ng-click="select(vehiculo)"> | 46 | ng-click="select(vehiculo)"> |
| 47 | <td ng-bind="vehiculo.tractor"></td> | 47 | <td ng-bind="vehiculo.tractor"></td> |
| 48 | <td ng-bind="vehiculo.semi"></td> | 48 | <td ng-bind="vehiculo.semi"></td> |
| 49 | <td ng-bind="vehiculo.capacidad"></td> | 49 | <td ng-bind="vehiculo.capacidad"></td> |
| 50 | <td ng-bind="vehiculo.cisternado"></td> | 50 | <td ng-bind="vehiculo.cisternado"></td> |
| 51 | <td> | 51 | <td> |
| 52 | <button | 52 | <button |
| 53 | type="button" | 53 | type="button" |
| 54 | class="btn btn-xs p-1 float-right" | 54 | class="btn btn-xs p-1 float-right" |
| 55 | ng-class="{ | 55 | ng-class="{ |
| 56 | 'btn-secondary': selectedVehiculo != key, | 56 | 'btn-secondary': selectedVehiculo != key, |
| 57 | 'btn-primary': selectedVehiculo == key | 57 | 'btn-primary': selectedVehiculo == key |
| 58 | }" | 58 | }" |
| 59 | foca-focus="selectedVehiculo == {{key}}" | 59 | foca-focus="selectedVehiculo == {{key}}" |
| 60 | ng-keydown="itemVehiculo($event.keyCode)" | 60 | ng-keydown="itemVehiculo($event.keyCode)" |
| 61 | > | 61 | > |
| 62 | <i class="fa fa-arrow-right" aria-hidden="true"></i> | 62 | <i class="fa fa-arrow-right" aria-hidden="true"></i> |
| 63 | </button> | 63 | </button> |
| 64 | </td> | 64 | </td> |
| 65 | </tr> | 65 | </tr> |
| 66 | </tbody> | 66 | </tbody> |
| 67 | </table> | 67 | </table> |
| 68 | <nav ng-show="currentPageVehiculos.length > 0 && primerBusqueda"> | 68 | <nav ng-show="currentPageVehiculos.length > 0 && primerBusqueda"> |
| 69 | <ul class="pagination pagination-sm justify-content mb-0"> | 69 | <ul class="pagination pagination-sm justify-content mb-0"> |
| 70 | <li class="page-item" ng-class="{'disabled': currentPage == 1}"> | 70 | <li class="page-item" ng-class="{'disabled': currentPage == 1}"> |
| 71 | <a class="page-link" href="#" ng-click="selectPage(currentPage - 1)"> | 71 | <a class="page-link" href="javascript:void();" ng-click="selectPage(currentPage - 1)"> |
| 72 | <span aria-hidden="true">«</span> | 72 | <span aria-hidden="true">«</span> |
| 73 | <span class="sr-only">Anterior</span> | 73 | <span class="sr-only">Anterior</span> |
| 74 | </a> | 74 | </a> |
| 75 | </li> | 75 | </li> |
| 76 | <li | 76 | <li |
| 77 | class="page-item" | 77 | class="page-item" |
| 78 | ng-repeat="pagina in paginas" | 78 | ng-repeat="pagina in paginas" |
| 79 | ng-class="{'active': pagina == currentPage}" | 79 | ng-class="{'active': pagina == currentPage}" |
| 80 | > | 80 | > |
| 81 | <a | 81 | <a |
| 82 | class="page-link" | 82 | class="page-link" |
| 83 | href="#" | 83 | href="javascript:void();" |
| 84 | ng-click="selectPage(pagina)" | 84 | ng-click="selectPage(pagina)" |
| 85 | ng-bind="pagina" | 85 | ng-bind="pagina" |
| 86 | ></a> | 86 | ></a> |
| 87 | </li> | 87 | </li> |
| 88 | <li class="page-item" ng-class="{'disabled': currentPage == lastPage}"> | 88 | <li class="page-item" ng-class="{'disabled': currentPage == lastPage}"> |
| 89 | <a class="page-link" href="#" ng-click="selectPage(currentPage + 1)"> | 89 | <a class="page-link" href="javascript:void();" ng-click="selectPage(currentPage + 1)"> |
| 90 | <span aria-hidden="true">»</span> | 90 | <span aria-hidden="true">»</span> |
| 91 | <span class="sr-only">Siguiente</span> | 91 | <span class="sr-only">Siguiente</span> |
| 92 | </a> | 92 | </a> |
| 93 | </li> | 93 | </li> |
| 94 | </ul> | 94 | </ul> |
| 95 | </nav> | 95 | </nav> |
| 96 | </div> | 96 | </div> |
| 97 | <div class="modal-footer py-1"> | 97 | <div class="modal-footer py-1"> |
| 98 | <button class="btn btn-sm btn-secondary" type="button" ng-click="cancel()">Cancelar</button> | 98 | <button class="btn btn-sm btn-secondary" type="button" ng-click="cancel()">Cancelar</button> |
| 99 | </div> | 99 | </div> |
| 100 | 100 |