Commit cd78befe42f7f5ce10330ebafaa659527d9764d9

Authored by Eric Fernandez
1 parent b364166962
Exists in master

avances

src/js/controller.js
... ... @@ -40,6 +40,7 @@ angular.module('focaHojaRuta')
40 40 if (res.data) {
41 41 var hojaRuta = res.data;
42 42 $scope.hojaRuta = hojaRuta;
  43 + $scope.hojaRuta.abierta = true;
43 44 $scope.puntoVenta = hojaRuta.sucursal;
44 45 $scope.comprobante = hojaRuta.numeroHojaRuta;
45 46 addCabecera('Transportista:', hojaRuta.transportista.NOM);
... ... @@ -146,6 +147,21 @@ angular.module('focaHojaRuta')
146 147 modalInstance.result.then(terminar);
147 148 };
148 149  
  150 + $scope.modalDescargas = function() {
  151 +
  152 + var modalInstance = $uibModal.open(
  153 + {
  154 + templateUrl: 'foca-modal-descarga.html',
  155 + controller: 'focaModalDescargaCtrl'
  156 + }
  157 + );
  158 +
  159 + modalInstance.result.then(function(data) {
  160 +
  161 + console.log(data);
  162 + });
  163 + };
  164 +
149 165 $rootScope.$on('estadoRed', function(event, value) {
150 166 $scope.esatadoRed = value;
151 167 });
src/views/lista-hoja-ruta.html
... ... @@ -61,7 +61,7 @@
61 61 </div>
62 62 <div class="col-12 col-md-10 col-lg-8 offset-md-1 offset-lg-2">
63 63 <div class="row grilla-articulo">
64   - <table class="table table-responsive table-striped table-sm table-dark">
  64 + <table ng-hide="hojaRuta.abierta" class="table table-responsive table-striped table-sm table-dark">
65 65 <thead>
66 66 <tr>
67 67 <th>#</th>
... ... @@ -92,7 +92,45 @@
92 92 </tr>
93 93 </tbody>
94 94 </table>
95   -
  95 + </div>
  96 + <div ng-show="hojaRuta.abierta" class="row grilla-articulo">
  97 + <table class="table table-striped table-sm table-dark">
  98 + <thead>
  99 + <tr>
  100 + <th colspan="3" class="text-center">Remito abierto Nº
  101 + {{[hojaRuta.remitos[0].sucursal, hojaRuta.remitos[0].numeroRemito] | comprobante}}
  102 + </th>
  103 + </tr>
  104 + <tr>
  105 + <th>Cisterna</th>
  106 + <th>Producto</th>
  107 + <th>Disponibles</th>
  108 + </tr>
  109 + </thead>
  110 + <tbody>
  111 + <tr ng-repeat="cisterna in hojaRuta.remitos[0].cisternas">
  112 + <td ng-bind="cisterna.codigo"></td>
  113 + <td ng-bind="cisterna.cisternaCarga.articulo.DetArt"></td>
  114 + <td ng-bind="cisterna.cisternaCarga.cantidad"></td>
  115 + </tr>
  116 + </tbody>
  117 + </table>
  118 + <table class="table table-striped table-sm table-dark">
  119 + <thead>
  120 + <tr>
  121 + <th>Descarga en cliente</th>
  122 + <th>
  123 + <button class="btn btn-outline-debo" ng-click="modalDescargas()">
  124 + <i class="fa fa-plus"></i>
  125 + </button>
  126 + </th>
  127 + </tr>
  128 + <tr></tr>
  129 + </thead>
  130 + <tbody>
  131 + <tr ng-repeat="remito in remitos"></tr>
  132 + </tbody>
  133 + </table>
96 134 </div>
97 135 </div>
98 136 <div class="row d-md-none fixed-bottom">