Commit 56667a0858e054849f5981aa4243c342632998f2

Authored by Eric
1 parent eff4abcb61
Exists in master

cambio claro

Showing 2 changed files with 8 additions and 185 deletions   Show diff stats
src/js/controller.js
... ... @@ -325,7 +325,7 @@ angular.module('focaCrearRemito') .controller('remitoController',
325 325 $scope.remito.numeroRemito = data.data.numero;
326 326  
327 327 remitoBusinessService.addArticulos($scope.remito.articulosRemito,
328   - $scope.remito.id, $scope.remito.cotizacion.COTIZACION);
  328 + $scope.remito.id, $scope.remito.cotizacion.VENDEDOR);
329 329  
330 330 var plazos = $scope.remito.remitoPlazo;
331 331  
... ... @@ -371,8 +371,8 @@ angular.module('focaCrearRemito') .controller('remitoController',
371 371 resolve: {
372 372 parametroProducto: {
373 373 idLista: $scope.idLista,
374   - cotizacion: $scope.remito.cotizacion.COTIZACION,
375   - simbolo: $scope.remito.cotizacion.moneda.simbolo
  374 + cotizacion: $scope.remito.cotizacion.VENDEDOR,
  375 + simbolo: $scope.remito.cotizacion.moneda.SIMBOLO
376 376 }
377 377 },
378 378 size: 'lg'
... ... @@ -811,13 +811,13 @@ angular.module('focaCrearRemito') .controller('remitoController',
811 811 var articulosTablaTemp = $scope.remito.articulosRemito;
812 812 for(var i = 0; i < articulosTablaTemp.length; i++) {
813 813 articulosTablaTemp[i].precio = articulosTablaTemp[i].precio *
814   - $scope.remito.cotizacion.COTIZACION;
  814 + $scope.remito.cotizacion.VENDEDOR;
815 815 articulosTablaTemp[i].precio = articulosTablaTemp[i].precio /
816   - cotizacion.COTIZACION;
  816 + cotizacion.VENDEDOR;
817 817 }
818 818 $scope.remito.articulosRemito = articulosTablaTemp;
819   - $scope.remito.cotizacion.moneda = moneda;
820 819 $scope.remito.cotizacion = cotizacion;
  820 + $scope.remito.cotizacion.moneda = moneda;
821 821 if (moneda.DETALLE === 'PESOS ARGENTINOS') {
822 822 $scope.$broadcast('removeCabecera', 'Moneda:');
823 823 $scope.$broadcast('removeCabecera', 'Fecha cotizacion:');
... ... @@ -833,7 +833,7 @@ angular.module(&#39;focaCrearRemito&#39;) .controller(&#39;remitoController&#39;,
833 833 });
834 834 $scope.$broadcast('addCabecera',{
835 835 label: 'Cotizacion:',
836   - valor: $filter('number')(cotizacion.COTIZACION, '2')
  836 + valor: $filter('number')(cotizacion.VENDEDOR, '2')
837 837 });
838 838 }
839 839 }, function() {
src/views/remito.html
... ... @@ -195,7 +195,7 @@
195 195 <h3>Total:</h3>
196 196 </td>
197 197 <td class="table-celda-total text-right no-border-top" colspan="1">
198   - <h3>{{getTotal() | currency: remito.moneda.SIMBOLO}}</h3>
  198 + <h3>{{getTotal() | currency: remito.cotizacion.moneda.SIMBOLO}}</h3>
199 199 </td>
200 200 <td class="text-right no-border-top">
201 201 <button
... ... @@ -209,183 +209,6 @@
209 209 </tfoot>
210 210 </table>
211 211 </div>
212   -
213   - <!-- MOBILE -->
214   - <div class="row d-sm-none">
215   - <table class="table table-sm table-striped tabla-articulo margin-bottom-mobile">
216   - <thead>
217   - <tr class="d-flex">
218   - <th class="">#</th>
219   - <th class="col px-0">
220   - <div class="d-flex">
221   - <div class="col-4 px-1">Cรณdigo</div>
222   - <div class="col-8 px-1">Descripciรณn</div>
223   - </div>
224   - <div class="d-flex">
225   - <div class="col-3 px-1">Cantidad</div>
226   - <div class="col px-1 text-right">P. Uni.</div>
227   - <div class="col px-1 text-right">Subtotal</div>
228   - </div>
229   - </th>
230   - <th class="text-center tamaรฑo-boton">
231   - &nbsp;
232   - </th>
233   - </tr>
234   - </thead>
235   - <tbody>
236   - <tr
237   - ng-repeat="(key, articulo) in remito.articulosRemito"
238   - ng-show="show || key == remito.articulosRemito.length - 1"
239   - >
240   - <td class="w-100 align-middle d-flex p-0">
241   - <div class="align-middle p-1">
242   - <span ng-bind="key+1" class="align-middle"></span>
243   - </div>
244   - <div class="col px-0">
245   - <div class="d-flex">
246   - <div class="col-4 px-1">
247   - <span
248   - ng-bind="articulo.sector + '-' + articulo.codigo"
249   - ></span>
250   - </div>
251   - <div class="col-8 px-1">
252   - <span
253   - ng-bind="'x' + articulo.cantidad"
254   - ng-hide="articulo.editCantidad"
255   - ></span>
256   - <i
257   - class="fa fa-pencil text-white-50"
258   - aria-hidden="true"
259   - ng-hide="articulo.editCantidad"
260   - ng-click="articulo.editCantidad = true"
261   - ></i>
262   - <input
263   - ng-show="articulo.editCantidad"
264   - ng-model="articulo.cantidad"
265   - class="form-control"
266   - foca-tipo-input
267   - min="1"
268   - step="0.001"
269   - foca-focus="articulo.editCantidad"
270   - ng-keypress="editarArticulo($event.keyCode, articulo)"
271   - ng-focus="selectFocus($event)"
272   - >
273   - </div>
274   - </div>
275   - <div class="d-flex">
276   - <div class="col-3 px-1">
277   - <span ng-bind="'x' + articulo.cantidad"></span>
278   - </div>
279   - <div class="col px-1 text-right">
280   - <span ng-bind="articulo.precio | currency: remito.moneda.SIMBOLO : 4"></span>
281   - </div>
282   - <div class="col px-1 text-right">
283   - <span
284   - ng-bind="(articulo.precio * articulo.cantidad) | currency: remito.moneda.SIMBOLO"
285   - >
286   - </span>
287   - </div>
288   - </div>
289   - </div>
290   - <div class="align-middle p-1">
291   - <button
292   - class="btn btn-outline-light"
293   - ng-click="quitarArticulo(key)"
294   - >
295   - <i class="fa fa-trash"></i>
296   - </button>
297   - </div>
298   - </td>
299   - </tr>
300   - </tbody>
301   - <tfoot>
302   - <!-- CARGANDO ITEM -->
303   - <tr ng-show="!cargando" class="d-flex">
304   - <td
305   - class="align-middle p-1"
306   - ng-bind="remito.articulosRemito.length + 1"
307   - ></td>
308   - <td class="col p-0">
309   - <div class="d-flex">
310   - <div class="col-4 px-1">
311   - <span
312   - ng-bind="articuloACargar.sectorCodigo"
313   - ></span>
314   - </div>
315   - <div class="col-8 px-1">
316   - <span ng-bind="articuloACargar.descripcion"></span>
317   - </div>
318   - </div>
319   - <div class="d-flex">
320   - <div class="col-3 px-1 m-1">
321   - <input
322   - class="form-control p-1"
323   - foca-tipo-input
324   - min="1"
325   - ng-model="articuloACargar.cantidad"
326   - foca-focus="!cargando"
327   - ng-keypress="agregarATabla($event.keyCode)"
328   - style="height: auto; line-height: 1.1em"
329   - >
330   - </div>
331   - <div class="col px-1 text-right">
332   - <span ng-bind="articuloACargar.precio | currency: remito.moneda.SIMBOLO : 4"></span>
333   - </div>
334   - <div class="col px-1 text-right">
335   - <span
336   - ng-bind="getSubTotal() | currency: remito.moneda.SIMBOLO"
337   - >
338   - </span>
339   - </div>
340   - </div>
341   - </td>
342   - <td class="text-center align-middle">
343   - <button
344   - class="btn btn-outline-light"
345   - ng-click="agregarATabla(13)"
346   - >
347   - <i class="fa fa-save"></i>
348   - </button>
349   - </td>
350   - </tr>
351   - <!-- TOOGLE EXPANDIR -->
352   - <tr>
353   - <td class="col">
354   - <button
355   - class="btn btn-outline-light selectable w-100"
356   - ng-click="show = !show; masMenos()"
357   - ng-show="remito.articulosRemito.length > 0"
358   - >
359   - <i
360   - class="fa fa-chevron-down"
361   - ng-hide="show"
362   - aria-hidden="true"
363   - >
364   - </i>
365   - <i
366   - class="fa fa-chevron-up"
367   - ng-show="show"
368   - aria-hidden="true">
369   - </i>
370   - </button>
371   - </td>
372   - </tr>
373   - <!-- FOOTER -->
374   - <tr class="d-flex">
375   - <td class="align-middle no-border-top" colspan="2">
376   - <strong>Cantidad Items:</strong>
377   - <a ng-bind="remito.articulosRemito.length"></a>
378   - </td>
379   - <td class="text-right ml-auto table-celda-total no-border-top">
380   - <h3>Total:</h3>
381   - </td>
382   - <td class="table-celda-total text-right no-border-top">
383   - <h3>{{getTotal() | currency: remito.moneda.SIMBOLO}}</h3>
384   - </td>
385   - </tr>
386   - </tfoot>
387   - </table>
388   - </div>
389 212 </div>
390 213 </div>
391 214 </div>