mirror of https://github.com/MISP/misp-dashboard
Consider time as a default value in logs table
parent
d80aa1e7a3
commit
220e0985d5
|
@ -7,7 +7,7 @@ max_img_rotation = 10
|
||||||
hours_spanned = 48
|
hours_spanned = 48
|
||||||
|
|
||||||
[Log]
|
[Log]
|
||||||
fieldname_order=["time", "id", "category", "type", "value"]
|
fieldname_order=["id", "category", "type", "value"]
|
||||||
|
|
||||||
[RedisLog]
|
[RedisLog]
|
||||||
host=localhost
|
host=localhost
|
||||||
|
|
|
@ -32,6 +32,7 @@ eventNumber = 0
|
||||||
class LogItem():
|
class LogItem():
|
||||||
|
|
||||||
FIELDNAME_ORDER = []
|
FIELDNAME_ORDER = []
|
||||||
|
FIELDNAME_ORDER.append("time")
|
||||||
for item in json.loads(cfg.get('Log', 'fieldname_order')):
|
for item in json.loads(cfg.get('Log', 'fieldname_order')):
|
||||||
FIELDNAME_ORDER.append(item)
|
FIELDNAME_ORDER.append(item)
|
||||||
|
|
||||||
|
|
|
@ -80,7 +80,7 @@ def default_attribute(jsonattr):
|
||||||
print('sending', 'attribute')
|
print('sending', 'attribute')
|
||||||
jsonattr = jsonattr['Attribute']
|
jsonattr = jsonattr['Attribute']
|
||||||
to_push = []
|
to_push = []
|
||||||
for field in json.loads(cfg.get('Log', 'fieldname_order'))[1:]:
|
for field in json.loads(cfg.get('Log', 'fieldname_order')):
|
||||||
to_push.append(jsonattr[field])
|
to_push.append(jsonattr[field])
|
||||||
|
|
||||||
#try to get coord
|
#try to get coord
|
||||||
|
|
Loading…
Reference in New Issue