Commit 620e4a5a473096824cb440853533b9cae2919c01
1 parent
070a133a
Exists in
master
ajuste do modelo da base
Showing
2 changed files
with
10 additions
and
7 deletions
Show diff stats
wscacicneo/model/reports.py
@@ -70,7 +70,7 @@ class Reports(): | @@ -70,7 +70,7 @@ class Reports(): | ||
70 | except HTTPError as err: | 70 | except HTTPError as err: |
71 | log.error(err.strerror) | 71 | log.error(err.strerror) |
72 | return None | 72 | return None |
73 | - | 73 | + |
74 | return coleta | 74 | return coleta |
75 | 75 | ||
76 | def update_coleta(self,id, document): | 76 | def update_coleta(self,id, document): |
@@ -116,6 +116,7 @@ class Reports(): | @@ -116,6 +116,7 @@ class Reports(): | ||
116 | for elm in results: | 116 | for elm in results: |
117 | if child: | 117 | if child: |
118 | parent = getattr(elm, attr) | 118 | parent = getattr(elm, attr) |
119 | + print(parent) | ||
119 | attribute = getattr(parent, child) | 120 | attribute = getattr(parent, child) |
120 | else: | 121 | else: |
121 | attribute = getattr(elm, attr) | 122 | attribute = getattr(elm, attr) |
wscacicneo/templates/conf_report.pt
@@ -40,20 +40,22 @@ | @@ -40,20 +40,22 @@ | ||
40 | orgao = $('#orgao').val() | 40 | orgao = $('#orgao').val() |
41 | attr = $('#coleta').val() | 41 | attr = $('#coleta').val() |
42 | if(attr == 'hd'){ | 42 | if(attr == 'hd'){ |
43 | - item = "tipo_hd" | 43 | + alert('Não disponivel no momento') |
44 | } | 44 | } |
45 | else if(attr == 'bios'){ | 45 | else if(attr == 'bios'){ |
46 | - item = "fabricante_bios" | 46 | + attr = 'win32_bios' |
47 | + item = "win32_bios_manufacturer" | ||
47 | } | 48 | } |
48 | else if(attr == 'Sistemas Operacionais'){ | 49 | else if(attr == 'Sistemas Operacionais'){ |
49 | - attr = 'sistemaoperacional' | ||
50 | - item = 'nome_so' | 50 | + attr = 'operatingsystem' |
51 | + item = 'operatingsystem_caption' | ||
51 | } | 52 | } |
52 | else if(attr == 'memoria'){ | 53 | else if(attr == 'memoria'){ |
53 | - item = 'interface_memoria' | 54 | + alert('não disponivel no momento') |
54 | } | 55 | } |
55 | else if(attr == 'processador'){ | 56 | else if(attr == 'processador'){ |
56 | - item = 'nome_processador' | 57 | + attr = 'win32_processor' |
58 | + item = 'win32_processor_manufacturer' | ||
57 | } | 59 | } |
58 | else{ | 60 | else{ |
59 | alert('Selecione o Item da coleta') | 61 | alert('Selecione o Item da coleta') |