Commit ba5693e55950309bc6a804c828c80df24f5e4630
1 parent
51c4e039ec
Exists in
master
progreso logistica
Showing
4 changed files
with
117 additions
and
19 deletions
Show diff stats
src/js/controllerDetalleVehiculo.js
1 | angular.module('focaLogisticaPedidoRuta') | 1 | angular.module('focaLogisticaPedidoRuta') |
2 | .controller('focaDetalleVehiculo', ['$scope', '$uibModalInstance', 'vehiculo', 'marcador', | 2 | .controller('focaDetalleVehiculo', |
3 | ['$scope', | ||
4 | '$uibModalInstance', | ||
5 | 'vehiculo', | ||
6 | 'marcador', | ||
3 | function($scope, $uibModalInstance, vehiculo, marcador) { | 7 | function($scope, $uibModalInstance, vehiculo, marcador) { |
4 | $scope.articulos = marcador.notaPedido.articulosNotaPedido; | 8 | $scope.articulos = marcador.notaPedido.articulosNotaPedido; |
9 | $scope.articuloSeleccionado = {}; | ||
5 | $scope.vehiculo = vehiculo; | 10 | $scope.vehiculo = vehiculo; |
6 | $scope.aceptar = function() { | 11 | $scope.aceptar = function() { |
7 | $uibModalInstance.close(); | 12 | $uibModalInstance.close(); |
8 | }; | 13 | }; |
14 | |||
15 | $scope.cargarACisterna = function(cisterna) { | ||
16 | if(!$scope.articuloSeleccionado.id) { | ||
17 | //TODO: usar modal de foca | ||
18 | alert('Debe seleccionar un articulo'); | ||
19 | return; | ||
20 | } | ||
21 | if(cisterna.cisternaCarga.cantidad) { | ||
22 | cisterna.cisternaCarga.cantidad += parseFloat(cisterna.aCargar); | ||
23 | }else { | ||
24 | cisterna.cisternaCarga.cantidad = parseFloat(cisterna.aCargar); | ||
25 | cisterna.cisternaCarga.idProducto = $scope.articuloSeleccionado.id; | ||
26 | } | ||
27 | cisterna.disponible = cisterna.capacidad - cisterna.cisternaCarga.cantidad; | ||
28 | cisterna.aCargar = ''; | ||
29 | }; | ||
30 | $scope.calcularPorcentaje = function(cisterna) { | ||
31 | if(!cisterna.cisternaCarga.cantidad) { | ||
32 | cisterna.cisternaCarga.cantidad = 0; | ||
33 | } | ||
34 | var porcentaje = (cisterna.cisternaCarga.cantidad * 100 / | ||
35 | cisterna.capacidad) + '%'; | ||
36 | document.getElementById(cisterna.id).style.width = porcentaje; | ||
37 | }; | ||
38 | $scope.cambioArticulo = function(articulo) { | ||
39 | $scope.articuloSeleccionado = articulo; | ||
40 | }; | ||
9 | }]); | 41 | }]); |
10 | 42 |
src/js/osm-directive.js
1 | angular.module('focaLogisticaPedidoRuta').directive('foca', function() { | 1 | angular.module('focaLogisticaPedidoRuta').directive('foca', function() { |
2 | return { | 2 | return { |
3 | restrict: 'E', | 3 | restrict: 'E', |
4 | link: function(scope, el, attrs) { | 4 | link: function(scope, el, attrs) { |
5 | var contenedor = document.createElement('div'); | 5 | var contenedor = document.createElement('div'); |
6 | el.append(contenedor); | 6 | el.append(contenedor); |
7 | scope.map = L.map(contenedor).setView([attrs.latitud, attrs.longitud], attrs.zoom); | 7 | scope.map = L.map(contenedor).setView([attrs.latitud, attrs.longitud], attrs.zoom); |
8 | L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png').addTo(scope.map); | 8 | L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png').addTo(scope.map); |
9 | }, | 9 | }, |
10 | controller: ['$scope', function($scope) { | 10 | controller: ['$scope', '$filter', function($scope, $filter) { |
11 | $scope.markers = []; | 11 | $scope.markers = []; |
12 | $scope.$watch('marcadores', function() { | 12 | $scope.$watch('marcadores', function() { |
13 | for(var i in $scope.markers) { | 13 | for(var i in $scope.markers) { |
14 | $scope.map.removeLayer($scope.markers[i]); | 14 | $scope.map.removeLayer($scope.markers[i]); |
15 | } | 15 | } |
16 | $scope.markers = []; | 16 | $scope.markers = []; |
17 | 17 | ||
18 | angular.forEach($scope.marcadores, function(marcador) { | 18 | angular.forEach($scope.marcadores, function(marcador) { |
19 | var observacion = '<i class="fa fa-map-marker fa-5x" aria-hidden="true"'+ | 19 | var observacion = |
20 | 'Vendedor: ' + marcador.notaPedido.idVendedor + ' - ' + | ||
21 | ( | ||
22 | marcador.notaPedido.vendedor ? | ||
23 | marcador.notaPedido.vendedor.NomVen : | ||
24 | '' | ||
25 | ) + '<br/>'; | ||
26 | observacion += 'Fecha: ' + | ||
27 | $filter('date')(marcador.fecha.slice(0,10), 'dd/MM/yyyy') + ' ' + | ||
28 | marcador.fecha.slice(11,19) + '<br/>'; | ||
29 | observacion += 'Nº: ' + $filter('comprobante')([ | ||
30 | marcador.notaPedido.sucursal, | ||
31 | marcador.notaPedido.numeroNotaPedido | ||
32 | ]) + '<br/>'; | ||
33 | observacion += 'Cliente: ' + | ||
34 | marcador.notaPedido.cliente.NOM + '<br/>'; | ||
35 | |||
36 | if ($scope.parametros.individual) { | ||
37 | observacion += | ||
38 | 'Total: ' + $filter('currency')(marcador.notaPedido.total, '$'); | ||
39 | observacion = 'Orden: ' + marcador.orden + '<br/>' + observacion; | ||
40 | |||
41 | if (marcador.distancia) { | ||
42 | observacion += '<br/>Distancia a casa central: ' + | ||
43 | marcador.distancia + 'km'; | ||
44 | } | ||
45 | } else { | ||
46 | observacion += 'Cantidad de nota de pedido: ' + | ||
47 | marcador.cantidad + '<br/>'; | ||
48 | observacion += 'Total Vendido: ' + | ||
49 | $filter('currency')(marcador.total, '$'); | ||
50 | } | ||
51 | observacion += '<br/>'; | ||
52 | observacion += '<i class="fa fa-map-marker fa-3x" aria-hidden="true"'+ | ||
20 | 'class="form-control" ondragend="dropEnd()" ondragstart=\'drag(event, '+ | 53 | 'class="form-control" ondragend="dropEnd()" ondragstart=\'drag(event, '+ |
21 | JSON.stringify(marcador)+')\' draggable="true"></i>'; | 54 | JSON.stringify(marcador)+')\' draggable="true"></i>'; |
22 | $scope.markers.push( | 55 | $scope.markers.push( |
23 | L.marker([marcador.latitud, marcador.longitud]).addTo($scope.map) | 56 | L.marker([marcador.latitud, marcador.longitud]).addTo($scope.map) |
24 | .bindPopup(observacion) | 57 | .bindPopup(observacion) |
25 | ); | 58 | ); |
26 | 59 | ||
27 | $scope.markers[0].openPopup(); | 60 | $scope.markers[0].openPopup(); |
28 | }); | 61 | }); |
29 | }); | 62 | }); |
30 | }], | 63 | }], |
31 | scope: { | 64 | scope: { |
32 | latitud: '=', | 65 | latitud: '=', |
33 | longitud: '=', | 66 | longitud: '=', |
34 | zoom: '=', | 67 | zoom: '=', |
35 | marcadores: '=', | 68 | marcadores: '=', |
36 | parametros: '=' | 69 | parametros: '=' |
37 | } | 70 | } |
38 | }; | 71 | }; |
39 | }); | 72 | }); |
40 | 73 |
src/views/foca-detalle-vehiculo.html
1 | <div class="modal-header"> | 1 | <div class="modal-header"> |
2 | <h4>Detalle de carga</h4> | 2 | <h4>Detalle de carga</h4> |
3 | <h3>-EN DESARROLLO</h3> | ||
3 | </div> | 4 | </div> |
4 | <div class="modal-body"> | 5 | <div class="modal-body"> |
5 | <div class="row"> | 6 | <div> |
6 | <div class="col-12" ng-repeat="articulo in articulos"> | 7 | <div class="col-12" ng-repeat="articulo in articulos"> |
7 | <input | 8 | <input |
8 | type="checkbox" | 9 | type="radio" |
9 | ng-model="articulo.chequed" | 10 | name="articuloRadio" |
11 | id="{{articulo.id}}" | ||
12 | ng-click="cambioArticulo(articulo)" | ||
10 | > | 13 | > |
11 | <span>Articulo: {{articulo.descripcion}},</span> | 14 | <span>Articulo: {{articulo.descripcion}},</span> |
12 | <span>Cantidad: {{articulo.cantidad}}</span> | 15 | <span>Cantidad Cargada: {{articulo.cantidad}}</span> |
16 | <span>Cantidad a Cargar: </span> | ||
13 | </div> | 17 | </div> |
14 | <strong class="col-12" ng-bind="vehiculo.tractor"></strong> | 18 | <strong class="col-12" ng-bind="vehiculo.tractor"></strong> |
15 | <strong class="col-12">Cisternas:</strong> | 19 | <strong class="col-12">Cisternas:</strong> |
16 | <!-- <div class="text-center"> | 20 | <div class="form-group row input-group" ng-repeat="cisterna in vehiculo.cisternas"> |
17 | <div class="progress" ng-repeat="cisterna in vehiculo.cisternas"> | 21 | <div class="col-1 mt-2"> |
18 | <div class="progress-bar" role="progressbar" aria-valuenow="30" aria-valuemin="0" aria-valuemax="100" style="height: 30%;"> | 22 | <strong>{{cisterna.codigo}}</strong> |
19 | <span class="sr-only">30% Complete</span> | 23 | </div> |
24 | <input | ||
25 | class="form-control col-2" | ||
26 | foca-tipo-input | ||
27 | foca-teclado | ||
28 | placeholder="A cargar..." | ||
29 | ng-model="cisterna.aCargar" | ||
30 | ng-disabled="articuloSeleccionado.cantidad > cisterna.disponible" | ||
31 | > | ||
32 | <div class="input-group-append"> | ||
33 | <button | ||
34 | class="form-control btn btn-outline-secondary" | ||
35 | ng-disabled="articuloSeleccionado.cantidad > cisterna.disponible"> | ||
36 | <i | ||
37 | class="fa fa-save" | ||
38 | ng-click="cargarACisterna(cisterna)" | ||
39 | aria-hidden="true"></i> | ||
40 | </button> | ||
41 | </div> | ||
42 | <div class="progress foca-alto col-8 pl-0 pr-0 mt-1"> | ||
43 | <strong class="col-12 mt-1 text-center position-absolute" | ||
44 | >{{cisterna.cisternaCarga.cantidad || 0}} / {{cisterna.capacidad}}</strong> | ||
45 | <div | ||
46 | id="{{cisterna.id}}" | ||
47 | class="progress-bar" | ||
48 | role="progressbar" | ||
49 | aria-valuemin="0" | ||
50 | aria-valuemax="{{cisterna.capacidad}}" | ||
51 | ng-style="{'width':'{{calcularPorcentaje(cisterna)}}'}"> | ||
20 | </div> | 52 | </div> |
21 | </div> | 53 | </div> |
22 | </div> --> | 54 | <div class="col-1 mt-1"> |
23 | <div class="progress col-12" ng-repeat="cisterna in vehiculo.cisternas"> | 55 | <i class="fa fa-info" data-toggle="tooltip" title="asd"></i> |
24 | <div class="progress-bar" role="progressbar" aria-valuenow="70" | ||
25 | aria-valuemin="0" aria-valuemax="100" style="width:70%"> | ||
26 | <span class="sr-only">70% Complete</span> | ||
27 | </div> | 56 | </div> |
28 | </div> | 57 | </div> |
29 | </div> | 58 | </div> |
30 | </div> | 59 | </div> |
31 | <div class="modal-footer py-1"> | 60 | <div class="modal-footer py-1"> |
32 | <button class="btn btn-sm btn-secondary" type="button" ng-click="aceptar()">Aceptar</button> | 61 | <button class="btn btn-sm btn-secondary" type="button" ng-click="aceptar()">Aceptar</button> |
33 | </div> | 62 | </div> |
34 | <style> | 63 | <style> |
35 | .progress-bar-vertical { | 64 | .progress-bar-vertical { |
36 | width: 20px; | 65 | width: 20px; |
37 | min-height: 100px; | 66 | min-height: 100px; |
38 | display: flex; | 67 | display: flex; |
39 | align-items: flex-end; | 68 | align-items: flex-end; |
40 | margin-right: 20px; | 69 | margin-right: 20px; |
41 | float: left; | 70 | float: left; |
42 | } | 71 | } |
43 | 72 | ||
44 | .progress-bar-vertical .progress-bar { | 73 | .progress-bar-vertical .progress-bar { |
45 | width: 100%; | 74 | width: 100%; |
46 | height: 0; | 75 | height: 0; |
47 | -webkit-transition: height 0.6s ease; | 76 | -webkit-transition: height 0.6s ease; |
48 | -o-transition: height 0.6s ease; | 77 | -o-transition: height 0.6s ease; |
49 | transition: height 0.6s ease; | 78 | transition: height 0.6s ease; |
50 | } | 79 | } |
80 | .foca-alto{ |
src/views/foca-logistica-pedido-ruta.html
1 | <script> | 1 | <script> |
2 | function allowDrop(ev) { | 2 | function allowDrop(ev) { |
3 | ev.preventDefault(); | 3 | ev.preventDefault(); |
4 | } | 4 | } |
5 | function drag(ev, marcador) { | 5 | function drag(ev, marcador) { |
6 | marcador = JSON.stringify(marcador); | 6 | marcador = JSON.stringify(marcador); |
7 | ev.dataTransfer.setData("marcador", marcador); | 7 | ev.dataTransfer.setData("marcador", marcador); |
8 | var dom_el = document.getElementById('test'); | 8 | var dom_el = document.getElementById('test'); |
9 | var scope = angular.element(dom_el).scope(); | 9 | var scope = angular.element(dom_el).scope(); |
10 | scope.arrastra(); | 10 | scope.arrastra(); |
11 | } | 11 | } |
12 | function drop(ev) { | 12 | function drop(ev) { |
13 | ev.preventDefault(); | 13 | ev.preventDefault(); |
14 | var data = ev.dataTransfer.getData("marcador"); | 14 | var data = ev.dataTransfer.getData("marcador"); |
15 | var dom_el = document.getElementById(ev.target.id); | 15 | var dom_el = document.getElementById(ev.target.id); |
16 | var ng_el = angular.element(dom_el); | 16 | var ng_el = angular.element(dom_el); |
17 | var ng_el_scope = ng_el.scope(); | 17 | var ng_el_scope = ng_el.scope(); |
18 | ng_el_scope.cargar(ev.target.id, data); | 18 | ng_el_scope.cargar(ev.target.id, data); |
19 | ng_el_scope.$digest(); | 19 | ng_el_scope.$digest(); |
20 | } | 20 | } |
21 | function dropEnd() { | 21 | function dropEnd() { |
22 | console.log('drop'); | 22 | console.log('drop'); |
23 | var dom_el = document.getElementById('test'); | 23 | var dom_el = document.getElementById('test'); |
24 | var scope = angular.element(dom_el).scope(); | 24 | var scope = angular.element(dom_el).scope(); |
25 | scope.noArrastra(); | 25 | scope.noArrastra(); |
26 | } | 26 | } |
27 | </script> | 27 | </script> |
28 | <div class="foca-logistica-pedido-ruta" id="test"> | 28 | <div class="foca-logistica-pedido-ruta" id="test"> |
29 | <h3>-EN DESARROLLO</h3> | ||
29 | <div class="row"> | 30 | <div class="row"> |
30 | <div class="offset-1 col-9"> | 31 | <div class="offset-1 col-9"> |
31 | <foca | 32 | <foca |
32 | latitud="-32.89214159952345" | 33 | latitud="-32.89214159952345" |
33 | longitud="-68.84572999101856" | 34 | longitud="-68.84572999101856" |
34 | zoom="14" | 35 | zoom="14" |
35 | marcadores="marcadores" | 36 | marcadores="marcadores" |
36 | parametros= "datosBuscados" | 37 | parametros= "datosBuscados" |
37 | /> | 38 | /> |
38 | </div> | 39 | </div> |
39 | <div class="col-2 pl-0"> | 40 | <div class="col-2 pl-0"> |
40 | <input | 41 | <input |
41 | type="date" | 42 | type="date" |
42 | ng-model="now" | 43 | ng-model="now" |
43 | class="btn col-12 my-1" | 44 | class="btn col-12 my-1" |
44 | foca-focus="true" | 45 | foca-focus="true" |
45 | ng-blur="fecha()" | 46 | ng-blur="fecha()" |
46 | hasta-hoy | 47 | hasta-hoy |
47 | /> | 48 | /> |
48 | <button | 49 | <button |
49 | type="button" | 50 | type="button" |
50 | ng-class="{'active': idUsuario == 0}" | 51 | ng-class="{'active': idUsuario == 0}" |
51 | class="btn col-12 my-1" | 52 | class="btn col-12 my-1" |
52 | ng-click="general()" | 53 | ng-click="general()" |
53 | >General</button> | 54 | >General</button> |
54 | <button | 55 | <button |
55 | type="button" | 56 | type="button" |
56 | ng-class="{'active': idUsuario != 0}" | 57 | ng-class="{'active': idUsuario != 0}" |
57 | class="btn col-12 my-1" | 58 | class="btn col-12 my-1" |
58 | ng-click="individual()" | 59 | ng-click="individual()" |
59 | ng-show="actividad != 'Cobranza'" | 60 | ng-show="actividad != 'Cobranza'" |
60 | >Individual</button> | 61 | >Individual</button> |
61 | <div class="form-group" ng-show="idUsuario == -1"> | 62 | <div class="form-group" ng-show="idUsuario == -1"> |
62 | <input | 63 | <input |
63 | type="text" | 64 | type="text" |
64 | placeholder="Vendedor" | 65 | placeholder="Vendedor" |
65 | class="form-control" | 66 | class="form-control" |
66 | ng-model="idUsuarioInput" | 67 | ng-model="idUsuarioInput" |
67 | ng-keypress="search($event.keyCode)" | 68 | ng-keypress="search($event.keyCode)" |
68 | foca-focus="idUsuario == -1" | 69 | foca-focus="idUsuario == -1" |
69 | ng-show="actividad == 'Nota de pedido'" | 70 | ng-show="actividad == 'Nota de pedido'" |
70 | > | 71 | > |
71 | <input | 72 | <input |
72 | type="text" | 73 | type="text" |
73 | placeholder="Vehiculo" | 74 | placeholder="Vehiculo" |
74 | class="form-control" | 75 | class="form-control" |
75 | ng-model="idUsuarioInput" | 76 | ng-model="idUsuarioInput" |
76 | ng-keypress="search($event.keyCode)" | 77 | ng-keypress="search($event.keyCode)" |
77 | foca-focus="idUsuario == -1" | 78 | foca-focus="idUsuario == -1" |
78 | ng-show="actividad == 'Entrega de producto'" | 79 | ng-show="actividad == 'Entrega de producto'" |
79 | > | 80 | > |
80 | </div> | 81 | </div> |
81 | <button | 82 | <button |
82 | type="button" | 83 | type="button" |
83 | class="btn col-12 my-1 boton-salir" | 84 | class="btn col-12 my-1 boton-salir" |
84 | ng-click="salir()" | 85 | ng-click="salir()" |
85 | > | 86 | > |
86 | Salir | 87 | Salir |
87 | </button> | 88 | </button> |
88 | </div> | 89 | </div> |
89 | <input | 90 | <input |
90 | class="col-auto form-control" | 91 | class="col-auto form-control" |
91 | ng-click="seleccionarVehiculo()" | 92 | ng-click="seleccionarVehiculo()" |
92 | placeholder="Seleccionar vehiculo" | 93 | placeholder="Seleccionar vehiculo" |
93 | readonly | 94 | readonly |
94 | /> | 95 | /> |
95 | <div class="row"> | 96 | <div class="row"> |
96 | <div | 97 | <div |
97 | class="container col-auto" | 98 | class="container col-auto" |
98 | ng-repeat="vehiculo in vehiculos" | 99 | ng-repeat="vehiculo in vehiculos" |
99 | ng-click="mostrarDetalleVehiculo(vehiculo)" | 100 | ng-click="mostrarDetalleVehiculo(vehiculo)" |
100 | > | 101 | > |
101 | <div> | 102 | <div> |
102 | <div class="col-md-3 col-sm-6"> | 103 | <div class="col-md-3 col-sm-6"> |
103 | <div class="progress-circle blue" ng-class="{'arrastrando': arrastrando}"> | 104 | <div class="progress-circle blue" ng-class="{'arrastrando': arrastrando}"> |
104 | <span class="progress-left"> | 105 | <span class="progress-left"> |
105 | <span class="progress-bar"></span> | 106 | <span class="progress-bar"></span> |
106 | </span> | 107 | </span> |
107 | <span class="progress-right"> | 108 | <span class="progress-right"> |
108 | <span class="progress-bar"></span> | 109 | <span class="progress-bar"></span> |
109 | </span> | 110 | </span> |
110 | <div class="progress-value">{{vehiculo.codigo}}</div> | 111 | <div class="progress-value">{{vehiculo.codigo}}</div> |
111 | </div> | 112 | </div> |
112 | </div> | 113 | </div> |
113 | <div | 114 | <div |
114 | class="col-12 border border-dark text-center" | 115 | class="col-12 border border-dark text-center" |
115 | ng-show="arrastrando" | 116 | ng-show="arrastrando" |
116 | id="{{vehiculo.id}}" | 117 | id="{{vehiculo.id}}" |
117 | ondrop="drop(event)" | 118 | ondrop="drop(event)" |
118 | ondragover="allowDrop(event)" | 119 | ondragover="allowDrop(event)" |
119 | >Soltar acá</div> | 120 | >Soltar acá</div> |
120 | </div> | 121 | </div> |
121 | </div> | 122 | </div> |
122 | </div> | 123 | </div> |
123 | </div> | 124 | </div> |
124 | </div> | 125 | </div> |
125 | <style> | 126 | <style> |
126 | .arrastrando { | 127 | .arrastrando { |
127 | opacity: 0.5; | 128 | opacity: 0.5; |
128 | } | 129 | } |
129 | .vertical { | 130 | .vertical { |
130 | display: inline-block; | 131 | display: inline-block; |
131 | width: 20%; | 132 | width: 20%; |
132 | height: 40px; | 133 | height: 40px; |
133 | -webkit-transform: rotate(-90deg); /* Chrome, Safari, Opera */ | 134 | -webkit-transform: rotate(-90deg); /* Chrome, Safari, Opera */ |
134 | transform: rotate(-90deg); | 135 | transform: rotate(-90deg); |
135 | } | 136 | } |
136 | .progress-circle{ | 137 | .progress-circle{ |
137 | width: 150px; | 138 | width: 150px; |
138 | height: 150px; | 139 | height: 150px; |
139 | line-height: 150px; | 140 | line-height: 150px; |
140 | background: none; | 141 | background: none; |
141 | margin: 0 auto; | 142 | margin: 0 auto; |
142 | box-shadow: none; | 143 | box-shadow: none; |
143 | position: relative; | 144 | position: relative; |
144 | } | 145 | } |
145 | .progress-circle:after{ | 146 | .progress-circle:after{ |
146 | content: ""; | 147 | content: ""; |
147 | width: 100%; | 148 | width: 100%; |
148 | height: 100%; | 149 | height: 100%; |
149 | border-radius: 50%; | 150 | border-radius: 50%; |
150 | border: 12px solid #fff; | 151 | border: 12px solid #fff; |
151 | position: absolute; | 152 | position: absolute; |
152 | top: 0; | 153 | top: 0; |
153 | left: 0; | 154 | left: 0; |
154 | } | 155 | } |
155 | .progress-circle > span{ | 156 | .progress-circle > span{ |
156 | width: 50%; | 157 | width: 50%; |
157 | height: 100%; | 158 | height: 100%; |
158 | overflow: hidden; | 159 | overflow: hidden; |
159 | position: absolute; | 160 | position: absolute; |
160 | top: 0; | 161 | top: 0; |
161 | z-index: 1; | 162 | z-index: 1; |
162 | } | 163 | } |
163 | .progress-circle .progress-left{ | 164 | .progress-circle .progress-left{ |
164 | left: 0; | 165 | left: 0; |
165 | } | 166 | } |
166 | .progress-circle .progress-bar{ | 167 | .progress-circle .progress-bar{ |
167 | width: 100%; | 168 | width: 100%; |
168 | height: 100%; | 169 | height: 100%; |
169 | background: none; | 170 | background: none; |
170 | border-width: 12px; | 171 | border-width: 12px; |
171 | border-style: solid; | 172 | border-style: solid; |
172 | position: absolute; | 173 | position: absolute; |
173 | top: 0; | 174 | top: 0; |
174 | } | 175 | } |
175 | .progress-circle .progress-left .progress-bar{ | 176 | .progress-circle .progress-left .progress-bar{ |
176 | left: 100%; | 177 | left: 100%; |
177 | border-top-right-radius: 80px; | 178 | border-top-right-radius: 80px; |
178 | border-bottom-right-radius: 80px; | 179 | border-bottom-right-radius: 80px; |
179 | border-left: 0; | 180 | border-left: 0; |
180 | -webkit-transform-origin: center left; | 181 | -webkit-transform-origin: center left; |
181 | transform-origin: center left; | 182 | transform-origin: center left; |
182 | } | 183 | } |
183 | .progress-circle .progress-right{ | 184 | .progress-circle .progress-right{ |
184 | right: 0; | 185 | right: 0; |
185 | } | 186 | } |
186 | .progress-circle .progress-right .progress-bar{ | 187 | .progress-circle .progress-right .progress-bar{ |
187 | left: -100%; | 188 | left: -100%; |
188 | border-top-left-radius: 80px; | 189 | border-top-left-radius: 80px; |
189 | border-bottom-left-radius: 80px; | 190 | border-bottom-left-radius: 80px; |
190 | border-right: 0; | 191 | border-right: 0; |
191 | -webkit-transform-origin: center right; | 192 | -webkit-transform-origin: center right; |
192 | transform-origin: center right; | 193 | transform-origin: center right; |
193 | animation: loading-1 1.8s linear forwards; | 194 | animation: loading-1 1.8s linear forwards; |
194 | } | 195 | } |
195 | .progress-circle .progress-value{ | 196 | .progress-circle .progress-value{ |
196 | width: 90%; | 197 | width: 90%; |
197 | height: 90%; | 198 | height: 90%; |
198 | border-radius: 50%; | 199 | border-radius: 50%; |
199 | background: #44484b; | 200 | background: #44484b; |
200 | font-size: 24px; | 201 | font-size: 24px; |
201 | color: #fff; | 202 | color: #fff; |
202 | line-height: 135px; | 203 | line-height: 135px; |
203 | text-align: center; | 204 | text-align: center; |
204 | position: absolute; | 205 | position: absolute; |
205 | top: 5%; | 206 | top: 5%; |
206 | left: 5%; | 207 | left: 5%; |
207 | } | 208 | } |
208 | .progress-circle.blue .progress-bar{ | 209 | .progress-circle.blue .progress-bar{ |
209 | border-color: #049dff; | 210 | border-color: #049dff; |
210 | } | 211 | } |
211 | .progress-circle.blue .progress-left .progress-bar{ | 212 | .progress-circle.blue .progress-left .progress-bar{ |
212 | animation: loading-2 1.5s linear forwards 1.8s; | 213 | animation: loading-2 1.5s linear forwards 1.8s; |
213 | } | 214 | } |
214 | .progress-circle.yellow .progress-bar{ | 215 | .progress-circle.yellow .progress-bar{ |
215 | border-color: #fdba04; | 216 | border-color: #fdba04; |
216 | } | 217 | } |
217 | .progress-circle.yellow .progress-left .progress-bar{ | 218 | .progress-circle.yellow .progress-left .progress-bar{ |
218 | animation: loading-3 1s linear forwards 1.8s; | 219 | animation: loading-3 1s linear forwards 1.8s; |
219 | } | 220 | } |
220 | .progress-circle.pink .progress-bar{ | 221 | .progress-circle.pink .progress-bar{ |
221 | border-color: #ed687c; | 222 | border-color: #ed687c; |
222 | } | 223 | } |
223 | .progress-circle.pink .progress-left .progress-bar{ | 224 | .progress-circle.pink .progress-left .progress-bar{ |
224 | animation: loading-4 0.4s linear forwards 1.8s; | 225 | animation: loading-4 0.4s linear forwards 1.8s; |
225 | } | 226 | } |
226 | .progress-circle.green .progress-bar{ | 227 | .progress-circle.green .progress-bar{ |
227 | border-color: #1abc9c; | 228 | border-color: #1abc9c; |
228 | } | 229 | } |
229 | .progress-circle.green .progress-left .progress-bar{ | 230 | .progress-circle.green .progress-left .progress-bar{ |
230 | animation: loading-5 1.2s linear forwards 1.8s; | 231 | animation: loading-5 1.2s linear forwards 1.8s; |
231 | } | 232 | } |
232 | @keyframes loading-1{ | 233 | @keyframes loading-1{ |
233 | 0%{ | 234 | 0%{ |
234 | -webkit-transform: rotate(0deg); | 235 | -webkit-transform: rotate(0deg); |
235 | transform: rotate(0deg); | 236 | transform: rotate(0deg); |
236 | } | 237 | } |
237 | 100%{ | 238 | 100%{ |
238 | -webkit-transform: rotate(180deg); | 239 | -webkit-transform: rotate(180deg); |
239 | transform: rotate(180deg); | 240 | transform: rotate(180deg); |
240 | } | 241 | } |
241 | } | 242 | } |
242 | @keyframes loading-2{ | 243 | @keyframes loading-2{ |
243 | 0%{ | 244 | 0%{ |
244 | -webkit-transform: rotate(0deg); | 245 | -webkit-transform: rotate(0deg); |
245 | transform: rotate(0deg); | 246 | transform: rotate(0deg); |
246 | } | 247 | } |
247 | 100%{ | 248 | 100%{ |
248 | -webkit-transform: rotate(144deg); | 249 | -webkit-transform: rotate(180deg); |
249 | transform: rotate(144deg); | 250 | transform: rotate(180deg); |
250 | } | 251 | } |
251 | } | 252 | } |
252 | @keyframes loading-3{ | 253 | @keyframes loading-3{ |
253 | 0%{ | 254 | 0%{ |
254 | -webkit-transform: rotate(0deg); | 255 | -webkit-transform: rotate(0deg); |
255 | transform: rotate(0deg); | 256 | transform: rotate(0deg); |
256 | } | 257 | } |
257 | 100%{ | 258 | 100%{ |
258 | -webkit-transform: rotate(90deg); | 259 | -webkit-transform: rotate(90deg); |
259 | transform: rotate(90deg); | 260 | transform: rotate(90deg); |
260 | } | 261 | } |
261 | } | 262 | } |
262 | @keyframes loading-4{ | 263 | @keyframes loading-4{ |
263 | 0%{ | 264 | 0%{ |
264 | -webkit-transform: rotate(0deg); | 265 | -webkit-transform: rotate(0deg); |
265 | transform: rotate(0deg); | 266 | transform: rotate(0deg); |
266 | } | 267 | } |
267 | 100%{ | 268 | 100%{ |
268 | -webkit-transform: rotate(36deg); | 269 | -webkit-transform: rotate(36deg); |
269 | transform: rotate(36deg); | 270 | transform: rotate(36deg); |
270 | } | 271 | } |
271 | } | 272 | } |
272 | @keyframes loading-5{ | 273 | @keyframes loading-5{ |
273 | 0%{ | 274 | 0%{ |
274 | -webkit-transform: rotate(0deg); | 275 | -webkit-transform: rotate(0deg); |
275 | transform: rotate(0deg); | 276 | transform: rotate(0deg); |
276 | } | 277 | } |
277 | 100%{ | 278 | 100%{ |
278 | -webkit-transform: rotate(126deg); | 279 | -webkit-transform: rotate(126deg); |
279 | transform: rotate(126deg); | 280 | transform: rotate(126deg); |
280 | } | 281 | } |
281 | } | 282 | } |
282 | @media only screen and (max-width: 990px){ | 283 | @media only screen and (max-width: 990px){ |
283 | .progress{ margin-bottom: 20px; } | 284 | .progress{ margin-bottom: 20px; } |
284 | } | 285 | } |
285 | 286 | ||
286 | </style> | 287 | </style> |
287 | 288 |