Commit 089d75c0cbd1d8989ff14bb3813246a1f0848b4e
1 parent
9d4e32a7dc
Exists in
master
and in
1 other branch
resolve de desarrollo para llamar al modal
Showing
1 changed file
with
2 additions
and
1 deletions
Show diff stats
index.html
1 | <html ng-app="focaBusquedaProductos"> | 1 | <html ng-app="focaBusquedaProductos"> |
2 | <head> | 2 | <head> |
3 | <meta charset="UTF-8"/> | 3 | <meta charset="UTF-8"/> |
4 | <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"> | 4 | <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"> |
5 | 5 | ||
6 | <!--CSS--> | 6 | <!--CSS--> |
7 | <link href="node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet"/> | 7 | <link href="node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet"/> |
8 | <link href="node_modules/font-awesome/css/font-awesome.min.css" rel="stylesheet"/> | 8 | <link href="node_modules/font-awesome/css/font-awesome.min.css" rel="stylesheet"/> |
9 | 9 | ||
10 | <!--VENDOR JS--> | 10 | <!--VENDOR JS--> |
11 | <script src="node_modules/jquery/dist/jquery.min.js"></script> | 11 | <script src="node_modules/jquery/dist/jquery.min.js"></script> |
12 | <script src="node_modules/bootstrap/dist/js/bootstrap.min.js"></script> | 12 | <script src="node_modules/bootstrap/dist/js/bootstrap.min.js"></script> |
13 | <script src="node_modules/angular/angular.min.js"></script> | 13 | <script src="node_modules/angular/angular.min.js"></script> |
14 | <script src="node_modules/ui-bootstrap4/dist/ui-bootstrap-tpls.js"></script> | 14 | <script src="node_modules/ui-bootstrap4/dist/ui-bootstrap-tpls.js"></script> |
15 | <script src="node_modules/foca-directivas/dist/foca-directivas.min.js"></script> | 15 | <script src="node_modules/foca-directivas/dist/foca-directivas.min.js"></script> |
16 | 16 | ||
17 | <!-- BUILD --> | 17 | <!-- BUILD --> |
18 | <script src="src/js/app.js"></script> | 18 | <script src="src/js/app.js"></script> |
19 | <script src="src/js/controller.js"></script> | 19 | <script src="src/js/controller.js"></script> |
20 | <script src="src/js/service.js"></script> | 20 | <script src="src/js/service.js"></script> |
21 | 21 | ||
22 | <!-- /BUILD --> | 22 | <!-- /BUILD --> |
23 | 23 | ||
24 | <!-- CONFIG PARA DEVELOP --> | 24 | <!-- CONFIG PARA DEVELOP --> |
25 | <script src="src/etc/develop.js"></script> | 25 | <script src="src/etc/develop.js"></script> |
26 | <script type="text/javascript"> | 26 | <script type="text/javascript"> |
27 | angular.module('focaBusquedaProductos') | 27 | angular.module('focaBusquedaProductos') |
28 | .controller('controller', [ | 28 | .controller('controller', [ |
29 | '$scope', | 29 | '$scope', |
30 | '$uibModal', | 30 | '$uibModal', |
31 | '$timeout', | 31 | '$timeout', |
32 | function($scope, $uibModal, $timeout) { | 32 | function($scope, $uibModal, $timeout) { |
33 | openModal(); | 33 | openModal(); |
34 | 34 | ||
35 | function openModal() { | 35 | function openModal() { |
36 | var modalInstance = $uibModal.open( | 36 | var modalInstance = $uibModal.open( |
37 | { | 37 | { |
38 | ariaLabelledBy: 'Busqueda de Productos', | 38 | ariaLabelledBy: 'Busqueda de Productos', |
39 | templateUrl: 'src/views/modal-busqueda-productos.html', | 39 | templateUrl: 'src/views/modal-busqueda-productos.html', |
40 | controller: 'modalBusquedaProductosCtrl', | 40 | controller: 'modalBusquedaProductosCtrl', |
41 | size: 'lg' | 41 | size: 'lg', |
42 | resolve: {idLista : function() { return null }} | ||
42 | } | 43 | } |
43 | ); | 44 | ); |
44 | 45 | ||
45 | modalInstance.result.then( | 46 | modalInstance.result.then( |
46 | function (selectedItem) { | 47 | function (selectedItem) { |
47 | console.info(selectedItem); | 48 | console.info(selectedItem); |
48 | $timeout(openModal, 500); | 49 | $timeout(openModal, 500); |
49 | }, function () { | 50 | }, function () { |
50 | console.info('modal-component dismissed at: ' + new Date()); | 51 | console.info('modal-component dismissed at: ' + new Date()); |
51 | $timeout(openModal, 500); | 52 | $timeout(openModal, 500); |
52 | } | 53 | } |
53 | ); | 54 | ); |
54 | } | 55 | } |
55 | } | 56 | } |
56 | ]); | 57 | ]); |
57 | </script> | 58 | </script> |
58 | </head> | 59 | </head> |
59 | <body ng-controller="controller"> | 60 | <body ng-controller="controller"> |
60 | </body> | 61 | </body> |
61 | </html> | 62 | </html> |
62 | 63 |