Commit e1717de7791f010c95001df3a558559bffc5d5ab
1 parent
b3272ce018
Exists in
master
agrego boton guardar al editar un articulo
Showing
1 changed file
with
7 additions
and
0 deletions
Show diff stats
src/views/nota-pedido.html
1 | <div class="crear-nota-pedido"> | 1 | <div class="crear-nota-pedido"> |
2 | <form name="formCrearNota" ng-submit="crearNotaPedido()" class="mb-0"> | 2 | <form name="formCrearNota" ng-submit="crearNotaPedido()" class="mb-0"> |
3 | <div class="row"> | 3 | <div class="row"> |
4 | <div class="col-md-10 offset-md-1 col-lg-8 offset-lg-2"> | 4 | <div class="col-md-10 offset-md-1 col-lg-8 offset-lg-2"> |
5 | <div class="row p-1 panel-informativo"> | 5 | <div class="row p-1 panel-informativo"> |
6 | <div class="col-12"> | 6 | <div class="col-12"> |
7 | <div class="row"> | 7 | <div class="row"> |
8 | <div class="col-12 col-sm-4 nota-pedido"> | 8 | <div class="col-12 col-sm-4 nota-pedido"> |
9 | <h5>NOTA DE PEDIDO</h5> | 9 | <h5>NOTA DE PEDIDO</h5> |
10 | </div> | 10 | </div> |
11 | <div class="col-5 col-sm-4 numero-pedido" | 11 | <div class="col-5 col-sm-4 numero-pedido" |
12 | >Nº {{puntoVenta}}-{{comprobante}} | 12 | >Nº {{puntoVenta}}-{{comprobante}} |
13 | </div> | 13 | </div> |
14 | <div class="col-7 col-sm-4 text-right"> | 14 | <div class="col-7 col-sm-4 text-right"> |
15 | Fecha: | 15 | Fecha: |
16 | <span | 16 | <span |
17 | ng-show="!datepickerAbierto" | 17 | ng-show="!datepickerAbierto" |
18 | ng-bind="now | date:'dd/MM/yyyy HH:mm'" | 18 | ng-bind="now | date:'dd/MM/yyyy HH:mm'" |
19 | ng-click="datepickerAbierto = true" | 19 | ng-click="datepickerAbierto = true" |
20 | > | 20 | > |
21 | </span> | 21 | </span> |
22 | <input | 22 | <input |
23 | ng-show="datepickerAbierto" | 23 | ng-show="datepickerAbierto" |
24 | type="date" | 24 | type="date" |
25 | ng-model="now" | 25 | ng-model="now" |
26 | ng-change="datepickerAbierto = false" | 26 | ng-change="datepickerAbierto = false" |
27 | ng-blur="datepickerAbierto = false" | 27 | ng-blur="datepickerAbierto = false" |
28 | class="form-control form-control-sm col-8 float-right" | 28 | class="form-control form-control-sm col-8 float-right" |
29 | foca-focus="datepickerAbierto" | 29 | foca-focus="datepickerAbierto" |
30 | hasta-hoy | 30 | hasta-hoy |
31 | /> | 31 | /> |
32 | </div> | 32 | </div> |
33 | </div> | 33 | </div> |
34 | <div class="row"> | 34 | <div class="row"> |
35 | <div class="col-auto" ng-repeat="cab in cabecera" ng-show="showCabecera"> | 35 | <div class="col-auto" ng-repeat="cab in cabecera" ng-show="showCabecera"> |
36 | <span class="label" ng-bind="cab.label"></span> | 36 | <span class="label" ng-bind="cab.label"></span> |
37 | <span class="valor" ng-bind="cab.valor"></span> | 37 | <span class="valor" ng-bind="cab.valor"></span> |
38 | </div> | 38 | </div> |
39 | <a | 39 | <a |
40 | class="btn col-12 btn-secondary d-sm-none" | 40 | class="btn col-12 btn-secondary d-sm-none" |
41 | ng-show="cabecera.length > 0" | 41 | ng-show="cabecera.length > 0" |
42 | ng-click="showCabecera = !showCabecera" | 42 | ng-click="showCabecera = !showCabecera" |
43 | > | 43 | > |
44 | <i | 44 | <i |
45 | class="fa fa-chevron-down" | 45 | class="fa fa-chevron-down" |
46 | ng-hide="showCabecera" | 46 | ng-hide="showCabecera" |
47 | aria-hidden="true" | 47 | aria-hidden="true" |
48 | > | 48 | > |
49 | </i> | 49 | </i> |
50 | <i | 50 | <i |
51 | class="fa fa-chevron-up" | 51 | class="fa fa-chevron-up" |
52 | ng-show="showCabecera" | 52 | ng-show="showCabecera" |
53 | aria-hidden="true"> | 53 | aria-hidden="true"> |
54 | </i> | 54 | </i> |
55 | </a> | 55 | </a> |
56 | </div> | 56 | </div> |
57 | </div> | 57 | </div> |
58 | </div> | 58 | </div> |
59 | <div class="row p-1 botonera-secundaria"> | 59 | <div class="row p-1 botonera-secundaria"> |
60 | <div class="col-12"> | 60 | <div class="col-12"> |
61 | <div class="row"> | 61 | <div class="row"> |
62 | <div class="col-6 col-sm-3 px-0 py-0" ng-repeat="boton in botonera"> | 62 | <div class="col-6 col-sm-3 px-0 py-0" ng-repeat="boton in botonera"> |
63 | <button | 63 | <button |
64 | type="button" | 64 | type="button" |
65 | class="btn btn-default btn-block btn-xs text-left py-2" | 65 | class="btn btn-default btn-block btn-xs text-left py-2" |
66 | ng-click="boton.accion()" | 66 | ng-click="boton.accion()" |
67 | ng-class="{'d-none d-sm-block': boton.texto == ''}" | 67 | ng-class="{'d-none d-sm-block': boton.texto == ''}" |
68 | > | 68 | > |
69 | <i | 69 | <i |
70 | class="fa fa-arrow-circle-right" | 70 | class="fa fa-arrow-circle-right" |
71 | ng-show="boton.texto != ''" | 71 | ng-show="boton.texto != ''" |
72 | ></i> | 72 | ></i> |
73 | | 73 | |
74 | {{boton.texto}} | 74 | {{boton.texto}} |
75 | </button> | 75 | </button> |
76 | </div> | 76 | </div> |
77 | </div> | 77 | </div> |
78 | </div> | 78 | </div> |
79 | </div> | 79 | </div> |
80 | </div> | 80 | </div> |
81 | </div> | 81 | </div> |
82 | </form> | 82 | </form> |
83 | <div class="row"> | 83 | <div class="row"> |
84 | <div class="col-12 col-md-10 col-lg-8 offset-md-1 offset-lg-2"> | 84 | <div class="col-12 col-md-10 col-lg-8 offset-md-1 offset-lg-2"> |
85 | <!-- PC --> | 85 | <!-- PC --> |
86 | <div class="row grilla-articulo align-items-end d-none d-sm-flex"> | 86 | <div class="row grilla-articulo align-items-end d-none d-sm-flex"> |
87 | <table class="table tabla-articulo table-striped table-sm table-dark"> | 87 | <table class="table tabla-articulo table-striped table-sm table-dark"> |
88 | <thead> | 88 | <thead> |
89 | <tr class="d-flex"> | 89 | <tr class="d-flex"> |
90 | <th class="">#</th> | 90 | <th class="">#</th> |
91 | <th class="col">Código</th> | 91 | <th class="col">Código</th> |
92 | <th class="col-4">Descripción</th> | 92 | <th class="col-4">Descripción</th> |
93 | <th class="col text-right">Cantidad</th> | 93 | <th class="col text-right">Cantidad</th> |
94 | <th class="col text-right">Precio Unitario</th> | 94 | <th class="col text-right">Precio Unitario</th> |
95 | <th class="col text-right">SubTotal</th> | 95 | <th class="col text-right">SubTotal</th> |
96 | <th class="text-right"> | 96 | <th class="text-right"> |
97 | <button | 97 | <button |
98 | class="btn btn-outline-secondary selectable" | 98 | class="btn btn-outline-secondary selectable" |
99 | ng-click="show = !show; masMenos()" | 99 | ng-click="show = !show; masMenos()" |
100 | > | 100 | > |
101 | <i | 101 | <i |
102 | class="fa fa-chevron-down" | 102 | class="fa fa-chevron-down" |
103 | ng-show="show" | 103 | ng-show="show" |
104 | aria-hidden="true" | 104 | aria-hidden="true" |
105 | > | 105 | > |
106 | </i> | 106 | </i> |
107 | <i | 107 | <i |
108 | class="fa fa-chevron-up" | 108 | class="fa fa-chevron-up" |
109 | ng-hide="show" | 109 | ng-hide="show" |
110 | aria-hidden="true"> | 110 | aria-hidden="true"> |
111 | </i> | 111 | </i> |
112 | </button> | 112 | </button> |
113 | </th> | 113 | </th> |
114 | </tr> | 114 | </tr> |
115 | </thead> | 115 | </thead> |
116 | <tbody class="tabla-articulo-body"> | 116 | <tbody class="tabla-articulo-body"> |
117 | <tr | 117 | <tr |
118 | ng-repeat="(key, articulo) in articulosTabla" | 118 | ng-repeat="(key, articulo) in articulosTabla" |
119 | ng-show="show || key == (articulosTabla.length - 1)" | 119 | ng-show="show || key == (articulosTabla.length - 1)" |
120 | class="d-flex" | 120 | class="d-flex" |
121 | > | 121 | > |
122 | <td ng-bind="key + 1"></td> | 122 | <td ng-bind="key + 1"></td> |
123 | <td | 123 | <td |
124 | class="col" | 124 | class="col" |
125 | ng-bind="articulo.sector + '-' + articulo.codigo" | 125 | ng-bind="articulo.sector + '-' + articulo.codigo" |
126 | ></td> | 126 | ></td> |
127 | <td | 127 | <td |
128 | class="col-4" | 128 | class="col-4" |
129 | ng-bind="articulo.descripcion" | 129 | ng-bind="articulo.descripcion" |
130 | ></td> | 130 | ></td> |
131 | <td class="col text-right"> | 131 | <td class="col text-right"> |
132 | <input | 132 | <input |
133 | ng-show="articulo.editCantidad" | 133 | ng-show="articulo.editCantidad" |
134 | ng-model="articulo.cantidad" | 134 | ng-model="articulo.cantidad" |
135 | class="form-control" | 135 | class="form-control" |
136 | type="number" | 136 | type="number" |
137 | min="1" | 137 | min="1" |
138 | foca-focus="articulo.editCantidad" | 138 | foca-focus="articulo.editCantidad" |
139 | ng-keypress="editarArticulo($event.keyCode, articulo)" | 139 | ng-keypress="editarArticulo($event.keyCode, articulo)" |
140 | ng-focus="selectFocus($event)" | 140 | ng-focus="selectFocus($event)" |
141 | teclado-virtual | 141 | teclado-virtual |
142 | > | 142 | > |
143 | <i | 143 | <i |
144 | class="selectable" | 144 | class="selectable" |
145 | ng-click="cambioEdit(articulo, 'cantidad')" | 145 | ng-click="cambioEdit(articulo, 'cantidad')" |
146 | ng-hide="articulo.editCantidad" | 146 | ng-hide="articulo.editCantidad" |
147 | ng-bind="articulo.cantidad"> | 147 | ng-bind="articulo.cantidad"> |
148 | </i> | 148 | </i> |
149 | </td> | 149 | </td> |
150 | <td class="col text-right"> | 150 | <td class="col text-right"> |
151 | <input | 151 | <input |
152 | ng-show="articulo.editPrecio" | 152 | ng-show="articulo.editPrecio" |
153 | ng-model="articulo.precio" | 153 | ng-model="articulo.precio" |
154 | class="form-control" | 154 | class="form-control" |
155 | type="number" | 155 | type="number" |
156 | min="0" | 156 | min="0" |
157 | step="0.0001" | 157 | step="0.0001" |
158 | foca-focus="articulo.editPrecio" | 158 | foca-focus="articulo.editPrecio" |
159 | ng-keypress="editarArticulo($event.keyCode, articulo)" | 159 | ng-keypress="editarArticulo($event.keyCode, articulo)" |
160 | ng-focus="selectFocus($event)" | 160 | ng-focus="selectFocus($event)" |
161 | teclado-virtual | 161 | teclado-virtual |
162 | > | 162 | > |
163 | <i | 163 | <i |
164 | class="selectable" | 164 | class="selectable" |
165 | ng-click="idLista == -1 && cambioEdit(articulo, 'precio')" | 165 | ng-click="idLista == -1 && cambioEdit(articulo, 'precio')" |
166 | ng-hide="articulo.editPrecio" | 166 | ng-hide="articulo.editPrecio" |
167 | ng-bind="articulo.precio | currency: notaPedido.moneda.simbolo : 4"> | 167 | ng-bind="articulo.precio | currency: notaPedido.moneda.simbolo : 4"> |
168 | </i> | 168 | </i> |
169 | </td> | 169 | </td> |
170 | <td | 170 | <td |
171 | class="col text-right" | 171 | class="col text-right" |
172 | ng-bind="(articulo.precio * articulo.cantidad) | currency: notaPedido.moneda.simbolo"> | 172 | ng-bind="(articulo.precio * articulo.cantidad) | currency: notaPedido.moneda.simbolo"> |
173 | </td> | 173 | </td> |
174 | <td class="text-center"> | 174 | <td class="text-center"> |
175 | <button | 175 | <button |
176 | ng-show="articulo.editCantidad || articulo.editPrecio" | ||
177 | class="btn btn-outline-secondary" | ||
178 | ng-click="editarArticulo(13, articulo)" | ||
179 | > | ||
180 | <i class="fa fa-save"></i> | ||
181 | </button> | ||
182 | <button | ||
176 | class="btn btn-outline-secondary" | 183 | class="btn btn-outline-secondary" |
177 | ng-click="quitarArticulo(key)" | 184 | ng-click="quitarArticulo(key)" |
178 | > | 185 | > |
179 | <i class="fa fa-trash"></i> | 186 | <i class="fa fa-trash"></i> |
180 | </button> | 187 | </button> |
181 | </td> | 188 | </td> |
182 | </tr> | 189 | </tr> |
183 | </tbody> | 190 | </tbody> |
184 | <tfoot> | 191 | <tfoot> |
185 | <tr ng-show="!cargando" class="d-flex"> | 192 | <tr ng-show="!cargando" class="d-flex"> |
186 | <td | 193 | <td |
187 | class="align-middle" | 194 | class="align-middle" |
188 | ng-bind="articulosTabla.length + 1" | 195 | ng-bind="articulosTabla.length + 1" |
189 | ></td> | 196 | ></td> |
190 | <td class="col"> | 197 | <td class="col"> |
191 | <input | 198 | <input |
192 | class="form-control" | 199 | class="form-control" |
193 | ng-model="articuloACargar.sectorCodigo" | 200 | ng-model="articuloACargar.sectorCodigo" |
194 | readonly | 201 | readonly |
195 | > | 202 | > |
196 | </td> | 203 | </td> |
197 | <td class="col-4 tabla-articulo-descripcion"> | 204 | <td class="col-4 tabla-articulo-descripcion"> |
198 | <input | 205 | <input |
199 | class="form-control" | 206 | class="form-control" |
200 | ng-model="articuloACargar.descripcion" | 207 | ng-model="articuloACargar.descripcion" |
201 | readonly | 208 | readonly |
202 | > | 209 | > |
203 | </td> | 210 | </td> |
204 | <td class="col text-right"> | 211 | <td class="col text-right"> |
205 | <input | 212 | <input |
206 | class="form-control" | 213 | class="form-control" |
207 | type="number" | 214 | type="number" |
208 | min="1" | 215 | min="1" |
209 | ng-model="articuloACargar.cantidad" | 216 | ng-model="articuloACargar.cantidad" |
210 | foca-focus="!cargando" | 217 | foca-focus="!cargando" |
211 | esc-key="resetFilter()" | 218 | esc-key="resetFilter()" |
212 | ng-keypress="agregarATabla($event.keyCode)" | 219 | ng-keypress="agregarATabla($event.keyCode)" |
213 | ng-blur="parsearATexto(articuloACargar)" | 220 | ng-blur="parsearATexto(articuloACargar)" |
214 | teclado-virtual | 221 | teclado-virtual |
215 | > | 222 | > |
216 | </td> | 223 | </td> |
217 | <td class="col text-right"> | 224 | <td class="col text-right"> |
218 | <input | 225 | <input |
219 | class="form-control" | 226 | class="form-control" |
220 | ng-value="articuloACargar.precio | currency: notaPedido.moneda.simbolo : 4" | 227 | ng-value="articuloACargar.precio | currency: notaPedido.moneda.simbolo : 4" |
221 | ng-show="idLista != -1" | 228 | ng-show="idLista != -1" |
222 | readonly | 229 | readonly |
223 | > | 230 | > |
224 | <input | 231 | <input |
225 | class="form-control" | 232 | class="form-control" |
226 | type="number" | 233 | type="number" |
227 | min="0" | 234 | min="0" |
228 | step="0.0001" | 235 | step="0.0001" |
229 | ng-model="articuloACargar.precio" | 236 | ng-model="articuloACargar.precio" |
230 | esc-key="resetFilter()" | 237 | esc-key="resetFilter()" |
231 | ng-keypress="agregarATabla($event.keyCode)" | 238 | ng-keypress="agregarATabla($event.keyCode)" |
232 | ng-show="idLista == -1" | 239 | ng-show="idLista == -1" |
233 | teclado-virtual | 240 | teclado-virtual |
234 | > | 241 | > |
235 | </td> | 242 | </td> |
236 | <td class="col text-right"> | 243 | <td class="col text-right"> |
237 | <input | 244 | <input |
238 | class="form-control" | 245 | class="form-control" |
239 | ng-value="getSubTotal() | currency: notaPedido.moneda.simbolo" | 246 | ng-value="getSubTotal() | currency: notaPedido.moneda.simbolo" |
240 | readonly | 247 | readonly |
241 | ></td> | 248 | ></td> |
242 | <td class="text-center align-middle"> | 249 | <td class="text-center align-middle"> |
243 | <button | 250 | <button |
244 | class="btn btn-outline-secondary" | 251 | class="btn btn-outline-secondary" |
245 | ng-click="agregarATabla(13)" | 252 | ng-click="agregarATabla(13)" |
246 | > | 253 | > |
247 | <i class="fa fa-save"></i> | 254 | <i class="fa fa-save"></i> |
248 | </button> | 255 | </button> |
249 | </td> | 256 | </td> |
250 | </tr> | 257 | </tr> |
251 | <tr ng-show="cargando" class="d-flex"> | 258 | <tr ng-show="cargando" class="d-flex"> |
252 | <td colspan="7" class="col-12"> | 259 | <td colspan="7" class="col-12"> |
253 | <input | 260 | <input |
254 | placeholder="Seleccione Articulo" | 261 | placeholder="Seleccione Articulo" |
255 | class="form-control form-control-sm" | 262 | class="form-control form-control-sm" |
256 | readonly | 263 | readonly |
257 | ng-click="seleccionarArticulo()" | 264 | ng-click="seleccionarArticulo()" |
258 | /> | 265 | /> |
259 | </td> | 266 | </td> |
260 | </tr> | 267 | </tr> |
261 | <tr class="d-flex"> | 268 | <tr class="d-flex"> |
262 | <td colspan="4" class="no-border-top"> | 269 | <td colspan="4" class="no-border-top"> |
263 | <strong>Items:</strong> | 270 | <strong>Items:</strong> |
264 | <a ng-bind="articulosTabla.length"></a> | 271 | <a ng-bind="articulosTabla.length"></a> |
265 | </td> | 272 | </td> |
266 | <td class="text-right ml-auto table-celda-total no-border-top"> | 273 | <td class="text-right ml-auto table-celda-total no-border-top"> |
267 | <h3>Total:</h3> | 274 | <h3>Total:</h3> |
268 | </td> | 275 | </td> |
269 | <td class="table-celda-total text-right no-border-top" colspan="1"> | 276 | <td class="table-celda-total text-right no-border-top" colspan="1"> |
270 | <h3>{{getTotal() | currency: notaPedido.moneda.simbolo}}</h3> | 277 | <h3>{{getTotal() | currency: notaPedido.moneda.simbolo}}</h3> |
271 | </td> | 278 | </td> |
272 | <td class="text-right no-border-top"> | 279 | <td class="text-right no-border-top"> |
273 | <button | 280 | <button |
274 | type="button" | 281 | type="button" |
275 | class="btn btn-default btn-sm" | 282 | class="btn btn-default btn-sm" |
276 | > | 283 | > |
277 | Totales | 284 | Totales |
278 | </button> | 285 | </button> |
279 | </td> | 286 | </td> |
280 | </tr> | 287 | </tr> |
281 | </tfoot> | 288 | </tfoot> |
282 | </table> | 289 | </table> |
283 | </div> | 290 | </div> |
284 | 291 | ||
285 | <!-- MOBILE --> | 292 | <!-- MOBILE --> |
286 | <div class="row d-sm-none"> | 293 | <div class="row d-sm-none"> |
287 | <table class="table table-sm table-striped table-dark margin-bottom-mobile"> | 294 | <table class="table table-sm table-striped table-dark margin-bottom-mobile"> |
288 | <thead> | 295 | <thead> |
289 | <tr class="d-flex"> | 296 | <tr class="d-flex"> |
290 | <th class="">#</th> | 297 | <th class="">#</th> |
291 | <th class="col px-0"> | 298 | <th class="col px-0"> |
292 | <div class="d-flex"> | 299 | <div class="d-flex"> |
293 | <div class="col-4 px-1">Código</div> | 300 | <div class="col-4 px-1">Código</div> |
294 | <div class="col-8 px-1">Descripción</div> | 301 | <div class="col-8 px-1">Descripción</div> |
295 | </div> | 302 | </div> |
296 | <div class="d-flex"> | 303 | <div class="d-flex"> |
297 | <div class="col-3 px-1">Cantidad</div> | 304 | <div class="col-3 px-1">Cantidad</div> |
298 | <div class="col px-1 text-right">P. Uni.</div> | 305 | <div class="col px-1 text-right">P. Uni.</div> |
299 | <div class="col px-1 text-right">Subtotal</div> | 306 | <div class="col px-1 text-right">Subtotal</div> |
300 | </div> | 307 | </div> |
301 | </th> | 308 | </th> |
302 | <th class="text-center tamaño-boton"> | 309 | <th class="text-center tamaño-boton"> |
303 | | 310 | |
304 | </th> | 311 | </th> |
305 | </tr> | 312 | </tr> |
306 | </thead> | 313 | </thead> |
307 | <tbody> | 314 | <tbody> |
308 | <tr | 315 | <tr |
309 | ng-repeat="(key, articulo) in articulosTabla" | 316 | ng-repeat="(key, articulo) in articulosTabla" |
310 | ng-show="show || key == articulosTabla.length - 1" | 317 | ng-show="show || key == articulosTabla.length - 1" |
311 | > | 318 | > |
312 | <td class="w-100 align-middle d-flex p-0"> | 319 | <td class="w-100 align-middle d-flex p-0"> |
313 | <div class="align-middle p-1"> | 320 | <div class="align-middle p-1"> |
314 | <span ng-bind="key+1" class="align-middle"></span> | 321 | <span ng-bind="key+1" class="align-middle"></span> |
315 | </div> | 322 | </div> |
316 | <div class="col px-0"> | 323 | <div class="col px-0"> |
317 | <div class="d-flex"> | 324 | <div class="d-flex"> |
318 | <div class="col-4 px-1"> | 325 | <div class="col-4 px-1"> |
319 | <span | 326 | <span |
320 | ng-bind="articulo.sector + '-' + articulo.codigo" | 327 | ng-bind="articulo.sector + '-' + articulo.codigo" |
321 | ></span> | 328 | ></span> |
322 | </div> | 329 | </div> |
323 | <div class="col-8 px-1"> | 330 | <div class="col-8 px-1"> |
324 | <span ng-bind="articulo.descripcion"></span> | 331 | <span ng-bind="articulo.descripcion"></span> |
325 | </div> | 332 | </div> |
326 | </div> | 333 | </div> |
327 | <div class="d-flex"> | 334 | <div class="d-flex"> |
328 | <div class="col-3 px-1"> | 335 | <div class="col-3 px-1"> |
329 | <span ng-bind="'x' + articulo.cantidad"></span> | 336 | <span ng-bind="'x' + articulo.cantidad"></span> |
330 | </div> | 337 | </div> |
331 | <div class="col-3 px-1 text-right"> | 338 | <div class="col-3 px-1 text-right"> |
332 | <span ng-bind="articulo.precio | currency: notaPedido.moneda.simbolo : 4"></span> | 339 | <span ng-bind="articulo.precio | currency: notaPedido.moneda.simbolo : 4"></span> |
333 | </div> | 340 | </div> |
334 | <div class="col px-1 text-right"> | 341 | <div class="col px-1 text-right"> |
335 | <span | 342 | <span |
336 | ng-bind="(articulo.precio * articulo.cantidad) | currency: notaPedido.moneda.simbolo" | 343 | ng-bind="(articulo.precio * articulo.cantidad) | currency: notaPedido.moneda.simbolo" |
337 | > | 344 | > |
338 | </span> | 345 | </span> |
339 | </div> | 346 | </div> |
340 | </div> | 347 | </div> |
341 | </div> | 348 | </div> |
342 | <div class="align-middle p-1"> | 349 | <div class="align-middle p-1"> |
343 | <button | 350 | <button |
344 | class="btn btn-outline-secondary" | 351 | class="btn btn-outline-secondary" |
345 | ng-click="quitarArticulo(key)" | 352 | ng-click="quitarArticulo(key)" |
346 | > | 353 | > |
347 | <i class="fa fa-trash"></i> | 354 | <i class="fa fa-trash"></i> |
348 | </button> | 355 | </button> |
349 | </div> | 356 | </div> |
350 | </td> | 357 | </td> |
351 | </tr> | 358 | </tr> |
352 | </tbody> | 359 | </tbody> |
353 | <tfoot> | 360 | <tfoot> |
354 | <!-- CARGANDO ITEM --> | 361 | <!-- CARGANDO ITEM --> |
355 | <tr ng-show="!cargando" class="d-flex"> | 362 | <tr ng-show="!cargando" class="d-flex"> |
356 | <td | 363 | <td |
357 | class="align-middle p-1" | 364 | class="align-middle p-1" |
358 | ng-bind="articulosTabla.length + 1" | 365 | ng-bind="articulosTabla.length + 1" |
359 | ></td> | 366 | ></td> |
360 | <td class="col p-0"> | 367 | <td class="col p-0"> |
361 | <div class="d-flex"> | 368 | <div class="d-flex"> |
362 | <div class="col-4 px-1"> | 369 | <div class="col-4 px-1"> |
363 | <span | 370 | <span |
364 | ng-bind="articuloACargar.sectorCodigo" | 371 | ng-bind="articuloACargar.sectorCodigo" |
365 | ></span> | 372 | ></span> |
366 | </div> | 373 | </div> |
367 | <div class="col-8 px-1"> | 374 | <div class="col-8 px-1"> |
368 | <span ng-bind="articuloACargar.descripcion"></span> | 375 | <span ng-bind="articuloACargar.descripcion"></span> |
369 | </div> | 376 | </div> |
370 | </div> | 377 | </div> |
371 | <div class="d-flex"> | 378 | <div class="d-flex"> |
372 | <div class="col-3 px-1 m-1"> | 379 | <div class="col-3 px-1 m-1"> |
373 | <input | 380 | <input |
374 | class="form-control p-1" | 381 | class="form-control p-1" |
375 | type="number" | 382 | type="number" |
376 | min="1" | 383 | min="1" |
377 | ng-model="articuloACargar.cantidad" | 384 | ng-model="articuloACargar.cantidad" |
378 | foca-focus="!cargando" | 385 | foca-focus="!cargando" |
379 | ng-keypress="agregarATabla($event.keyCode)" | 386 | ng-keypress="agregarATabla($event.keyCode)" |
380 | style="height: auto; line-height: 1.1em" | 387 | style="height: auto; line-height: 1.1em" |
381 | > | 388 | > |
382 | </div> | 389 | </div> |
383 | <div class="col-3 px-1 text-right"> | 390 | <div class="col-3 px-1 text-right"> |
384 | <span ng-bind="articuloACargar.precio | currency: notaPedido.moneda.simbolo : 4"></span> | 391 | <span ng-bind="articuloACargar.precio | currency: notaPedido.moneda.simbolo : 4"></span> |
385 | </div> | 392 | </div> |
386 | <div class="col px-1 text-right"> | 393 | <div class="col px-1 text-right"> |
387 | <span | 394 | <span |
388 | ng-bind="getSubTotal() | currency: notaPedido.moneda.simbolo" | 395 | ng-bind="getSubTotal() | currency: notaPedido.moneda.simbolo" |
389 | > | 396 | > |
390 | </span> | 397 | </span> |
391 | </div> | 398 | </div> |
392 | </div> | 399 | </div> |
393 | </td> | 400 | </td> |
394 | <td class="text-center align-middle"> | 401 | <td class="text-center align-middle"> |
395 | <button | 402 | <button |
396 | class="btn btn-outline-secondary" | 403 | class="btn btn-outline-secondary" |
397 | ng-click="agregarATabla(13)" | 404 | ng-click="agregarATabla(13)" |
398 | > | 405 | > |
399 | <i class="fa fa-save"></i> | 406 | <i class="fa fa-save"></i> |
400 | </button> | 407 | </button> |
401 | </td> | 408 | </td> |
402 | </tr> | 409 | </tr> |
403 | <!-- SELECCIONAR PRODUCTO --> | 410 | <!-- SELECCIONAR PRODUCTO --> |
404 | <tr ng-show="cargando" class="d-flex"> | 411 | <tr ng-show="cargando" class="d-flex"> |
405 | <td class="col-12"> | 412 | <td class="col-12"> |
406 | <input | 413 | <input |
407 | placeholder="Seleccione Articulo" | 414 | placeholder="Seleccione Articulo" |
408 | class="form-control form-control-sm" | 415 | class="form-control form-control-sm" |
409 | readonly | 416 | readonly |
410 | ng-click="seleccionarArticulo()" | 417 | ng-click="seleccionarArticulo()" |
411 | /> | 418 | /> |
412 | </td> | 419 | </td> |
413 | </tr> | 420 | </tr> |
414 | <!-- TOOGLE EXPANDIR --> | 421 | <!-- TOOGLE EXPANDIR --> |
415 | <tr> | 422 | <tr> |
416 | <td class="col"> | 423 | <td class="col"> |
417 | <button | 424 | <button |
418 | class="btn btn-outline-secondary selectable w-100" | 425 | class="btn btn-outline-secondary selectable w-100" |
419 | ng-click="show = !show; masMenos()" | 426 | ng-click="show = !show; masMenos()" |
420 | ng-show="articulosTabla.length > 0" | 427 | ng-show="articulosTabla.length > 0" |
421 | > | 428 | > |
422 | <i | 429 | <i |
423 | class="fa fa-chevron-down" | 430 | class="fa fa-chevron-down" |
424 | ng-hide="show" | 431 | ng-hide="show" |
425 | aria-hidden="true" | 432 | aria-hidden="true" |
426 | > | 433 | > |
427 | </i> | 434 | </i> |
428 | <i | 435 | <i |
429 | class="fa fa-chevron-up" | 436 | class="fa fa-chevron-up" |
430 | ng-show="show" | 437 | ng-show="show" |
431 | aria-hidden="true"> | 438 | aria-hidden="true"> |
432 | </i> | 439 | </i> |
433 | </button> | 440 | </button> |
434 | </td> | 441 | </td> |
435 | </tr> | 442 | </tr> |
436 | <!-- FOOTER --> | 443 | <!-- FOOTER --> |
437 | <tr class="d-flex"> | 444 | <tr class="d-flex"> |
438 | <td class="align-middle no-border-top" colspan="2"> | 445 | <td class="align-middle no-border-top" colspan="2"> |
439 | <strong>Cantidad Items:</strong> | 446 | <strong>Cantidad Items:</strong> |
440 | <a ng-bind="articulosTabla.length"></a> | 447 | <a ng-bind="articulosTabla.length"></a> |
441 | </td> | 448 | </td> |
442 | <td class="text-right ml-auto table-celda-total no-border-top"> | 449 | <td class="text-right ml-auto table-celda-total no-border-top"> |
443 | <h3>Total:</h3> | 450 | <h3>Total:</h3> |
444 | </td> | 451 | </td> |
445 | <td class="table-celda-total text-right no-border-top"> | 452 | <td class="table-celda-total text-right no-border-top"> |
446 | <h3>{{getTotal() | currency: notaPedido.moneda.simbolo}}</h3> | 453 | <h3>{{getTotal() | currency: notaPedido.moneda.simbolo}}</h3> |
447 | </td> | 454 | </td> |
448 | </tr> | 455 | </tr> |
449 | </tfoot> | 456 | </tfoot> |
450 | </table> | 457 | </table> |
451 | </div> | 458 | </div> |
452 | </div> | 459 | </div> |
453 | <div class="col-auto my-2 col-lg-2 botonera-lateral d-none d-md-block"> | 460 | <div class="col-auto my-2 col-lg-2 botonera-lateral d-none d-md-block"> |
454 | <div class="row align-items-end"> | 461 | <div class="row align-items-end"> |
455 | <div class="col-12"> | 462 | <div class="col-12"> |
456 | <button | 463 | <button |
457 | ng-click="crearNotaPedido()" | 464 | ng-click="crearNotaPedido()" |
458 | type="submit" | 465 | type="submit" |
459 | title="Crear nota pedido" | 466 | title="Crear nota pedido" |
460 | class="btn btn-default btn-block mb-2"> | 467 | class="btn btn-default btn-block mb-2"> |
461 | Guardar | 468 | Guardar |
462 | </button> | 469 | </button> |
463 | <button | 470 | <button |
464 | ng-click="salir()" | 471 | ng-click="salir()" |
465 | type="button" | 472 | type="button" |
466 | title="Salir" | 473 | title="Salir" |
467 | class="btn btn-default btn-block"> | 474 | class="btn btn-default btn-block"> |
468 | Salir | 475 | Salir |
469 | </button> | 476 | </button> |
470 | </div> | 477 | </div> |
471 | </div> | 478 | </div> |
472 | </div> | 479 | </div> |
473 | </div> | 480 | </div> |
474 | <div class="row d-md-none fixed-bottom"> | 481 | <div class="row d-md-none fixed-bottom"> |
475 | <div class="w-100 bg-dark d-flex px-3 acciones-mobile"> | 482 | <div class="w-100 bg-dark d-flex px-3 acciones-mobile"> |
476 | <span class="ml-3 text-muted" ng-click="salir()">Salir</span> | 483 | <span class="ml-3 text-muted" ng-click="salir()">Salir</span> |
477 | <span class="mr-3 ml-auto" ng-click="crearNotaPedido()">Guardar</span> | 484 | <span class="mr-3 ml-auto" ng-click="crearNotaPedido()">Guardar</span> |
478 | </div> | 485 | </div> |
479 | </div> | 486 | </div> |
480 | </div> | 487 | </div> |
481 | 488 |