-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
299 lines (266 loc) · 10.9 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
<!DOCTYPE html>
<html lang="pt-br">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="">
<meta name="author" content="Paulo Henrique">
<title>eVita - Dados de Busca no Aplicativo</title>
<link href="css/bootstrap.min.css" rel="stylesheet">
<link href="css/bootstrap-theme.min.css" rel="stylesheet">
<link href="css/ui-lightness/jquery-ui-1.10.4.custom.min.css" rel="stylesheet">
<link href="css/custom.css" rel="stylesheet">
<link rel="shortcut icon" href="images/favicon.png">
</head>
<body>
<header class="navbar navbar-static-top">
<div class="container">
<div class="navbar-header">
<a href="./index.html" class="navbar-brand"><img src="images/logo.png" /></a>
</div>
<ul class="nav navbar-nav navbar-right">
<li><a href="#">Conta</a></li>
<li><a href="#">Sair</a></li>
</ul>
</div>
</header>
<div class="all-content">
<section id="color-header">
<div class="container">
<div class="row">
<div class="col-lg-12">
<h1><span class="glyphicon glyphicon-stats"></span> Dados de Busca no Aplicativo</h1>
</div>
</div>
</div>
</section>
<section id="choose-chart-type" class="content">
<div class="container">
<div class="row">
<div class="col-lg-12 text-center">
<h2><span class="glyphicon glyphicon-stats"></span> Escolha o tipo de gráfico:</h2>
<button id="btn-choose-1" type="button" class="btn btn-primary btn-xl">Comparação entre Medicamentos</button>
<button id="btn-choose-2" type="button" class="btn btn-primary btn-xl">Medicamentos de uma Categoria</button>
</div>
</div>
</div>
</section>
<div id="choose-medicines" class="content">
<div class="container">
<div class="row">
<div class="col-lg-2"></div>
<div class="col-lg-8 text-center">
<h2><span class="glyphicon glyphicon-sort-by-alphabet"></span> Escolha os medicamentos para comparar:</h2>
<div class="ui-widget">
<input id="medicine-search" class="form-control" placeholder="Digite aqui o nome do medicamento"></input>
<button id="btn-add-medicine" class="btn btn-primary" type="button"><span class="glyphicon glyphicon-plus"></span> Adicionar</button>
<select multiple id="medicine-list" class="form-control"></select>
<button id="btn-follow-1" type="button" class="btn btn-primary btn-xl">Seguir <span class="glyphicon glyphicon-chevron-right"></span></button>
</div>
</div>
<div class="col-lg-2"></div>
</div>
</div>
</div>
<div id="choose-category" class="content">
<div class="container">
<div class="row">
<div class="col-lg-2"></div>
<div class="col-lg-8 text-center">
<h2><span class="glyphicon glyphicon-sort-by-alphabet"></span> Escolha uma categoria de medicamentos:</h2>
<div class="ui-widget">
<select id="category-list" class="form-control">
<option>Ansiolíticos e Hipnóticos</option>
<option>Antidepressivos</option>
<option>Anticonvulsivantes</option>
<option>Antipsicóticos e Neurolépticos</option>
<option>Antiparkisonianos</option>
<option>Diuréticos Tiazídicos</option>
<option>Antiinflamatórios Não Esteróides</option>
<option>Antialérgicos</option>
<option>Penicilinas</option>
<option>Sulfas</option>
<option>Antibacteriano e Cicatrizante</option>
</select>
<button id="btn-follow-2" type="button" class="btn btn-primary btn-xl">Seguir <span class="glyphicon glyphicon-chevron-right"></span></button>
</div>
</div>
<div class="col-lg-2"></div>
</div>
</div>
</div>
<div id="choose-location" class="content">
<div class="container">
<div class="row">
<div class="col-lg-2"></div>
<div class="col-lg-8 text-center">
<h2><span class="glyphicon glyphicon-globe"></span> Informe uma localização:</h2>
<div class="ui-widget">
<input id="medicine-search" class="form-control" placeholder="Digite aqui o CEP que deseja"></input>
<button id="btn-search-cep" class="btn btn-primary" type="button"><span class="glyphicon glyphicon-search"></span> Procurar</button>
<iframe src="https://www.google.com/maps/embed?pb=!1m18!1m12!1m3!1d3950.3130808272153!2d-34.92309545!3d-8.06951475!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!3m3!1m2!1s0x7ab1933ee2d2ef9%3A0x1783002f0f0c2294!2sRecife+-+PE!5e0!3m2!1spt-BR!2s!4v1401418978952" width="100%" height="450" frameborder="0" style="border:0"></iframe>
<button id="btn-generate" type="button" class="btn btn-primary btn-xl"><span class="glyphicon glyphicon-ok"></span> Gerar Gráfico</button>
</div>
</div>
<div class="col-lg-2"></div>
</div>
</div>
</div>
<div id="medicine-chart" class="content">
<div class="container">
<div class="row">
<div class="col-lg-2"></div>
<div class="col-lg-8 text-center">
<h2><span class="glyphicon glyphicon-sort"></span> Comparação entre medicamentos:</h2>
<div id="chart_div" style="width: 780px; height: 500px;"></div>
</div>
<div class="col-lg-2"></div>
</div>
</div>
</div>
<div id="category-chart" class="content">
<div class="container">
<div class="row">
<div class="col-lg-2"></div>
<div class="col-lg-8 text-center">
<h2><span class="glyphicon glyphicon-sort"></span> Categoria de medicamentos:</h2>
<div id="piechart" style="width: 780px; height: 500px;"></div>
</div>
<div class="col-lg-2"></div>
</div>
</div>
</div>
</div>
<footer class="navbar navbar-default navbar-fixed-bottom">
<div class="container">
<div class="row">
<div class="col-lg-12 text-center">
<a href="http://www.procuratecnologia.com"><img class="logo" src="images/copyright.png" title="Desenvolvido por Procura Tecnologia" /></a>
</div>
</div>
</div>
</footer>
<script src="js/jquery-1.11.1.min.js"></script>
<script type="text/javascript">
jQuery.fn.visible = function() {
return this.css('visibility', 'visible');
};
jQuery.fn.invisible = function() {
return this.css('visibility', 'hidden');
};
$("#choose-medicines").invisible();
$("#choose-category").invisible();
$("#choose-location").invisible();
$("#medicine-chart").invisible();
$("#category-chart").invisible();
$("#btn-choose-1").click(function(){
$("#choose-chart-type").hide();
$("#choose-medicines").visible();
$("#choose-category").hide();
chartType = "med";
});
$("#btn-choose-2").click(function(){
$("#choose-chart-type").hide();
$("#choose-medicines").hide();
$("#choose-category").visible();
chartType = "cat";
});
$("#btn-add-medicine").click(function(){
$("#medicine-list").append(new Option($("#medicine-search").val(), $("#medicine-search").val(), false, false));
});
$("#btn-follow-1").click(function(){
$("#choose-medicines").hide();
$("#choose-category").hide();
$("#choose-location").visible();
});
$("#btn-follow-2").click(function(){
$("#choose-medicines").hide();
$("#choose-category").hide();
$("#choose-location").visible();
});
$("#btn-generate").click(function(){
$("#choose-location").hide();
if(chartType == "med") {
$("#medicine-chart").visible();
$("#category-chart").hide();
}
else if(chartType == "cat") {
$("#medicine-chart").hide();
$("#category-chart").visible();
}
});
$(function() {
var chartType = "";
var availableTags = [
"Ciprofloxacino",
"Flagyl",
"Pantozol",
"Lantus U 100 Ui/Ml",
"Tylex",
"Novalgina Oral",
"Apresolina",
"Candicort Creme e Pomada",
"Floratil",
"Zyprexa",
"Aldomet",
"Furomida",
"Stavigile",
"Tecnomet",
"Clonazepam",
"Finasterida 1 Mg",
"Rivotril",
"Dipirona",
"Decadronal",
"Carvedilol",
"Morfenil",
"Dimorf Lc"
];
$("#medicine-search").autocomplete({
source: availableTags
});
});
</script>
<script src="js/bootstrap.min.js"></script>
<script src="js/jquery-ui-1.10.4.custom.min.js"></script>
<script type="text/javascript" src="https://www.google.com/jsapi"></script>
<script type="text/javascript">
google.load("visualization", "1", {packages:["corechart"]});
google.setOnLoadCallback(drawChart);
function drawChart() {
var data = google.visualization.arrayToDataTable([
['Data', 'Finasterida 1 Mg', 'Rivotril', 'Morfenil'],
['28/05/2014', 1000, 400, 150],
['29/05/2014', 1170, 460, 300],
['30/05/2014', 660, 1120, 10],
['31/05/2014', 1030, 540, 100]
]);
var options = {
title: 'Busca por Medicamentos no CEP 50070-123',
hAxis: {title: 'Data', titleTextStyle: {color: '#333'}},
vAxis: {minValue: 0}
};
var chart = new google.visualization.AreaChart(document.getElementById('chart_div'));
chart.draw(data, options);
}
</script>
<script type="text/javascript">
google.load("visualization", "1", {packages:["corechart"]});
google.setOnLoadCallback(drawChart);
function drawChart() {
var data = google.visualization.arrayToDataTable([
['Medicamento', 'Número de Consultas'],
['Carbolitium', 11],
['Amplictil', 20],
['Haldol Decanoato', 22],
['Neozine', 2],
['Neuleptil', 70]
]);
var options = {
title: 'Busca por Medicamentos Antipsicóticos e Neurolépticos no CEP 50070-123'
};
var chart = new google.visualization.PieChart(document.getElementById('piechart'));
chart.draw(data, options);
}
</script>
</body>
</html>