chg: [retro hunt] show object match last seen date

This commit is contained in:
terrtia 2025-01-24 10:03:41 +01:00
parent 3194fb0daa
commit 1cb4142718
No known key found for this signature in database
GPG key ID: 1E1B1F50D84613D0
3 changed files with 12 additions and 7 deletions

View file

@ -89,7 +89,7 @@ class AbstractDaterangeObject(AbstractObject, ABC):
if 'sparkline' in options:
meta_dict['sparkline'] = self.get_sparkline()
if 'last_full_date' in options:
meta_dict['last_full_date'] = self.get_last_full_date()
meta_dict['last_full_date'] = meta_dict['last_seen']
return meta_dict
def set_first_seen(self, first_seen):

View file

@ -549,7 +549,7 @@ def retro_hunt_show_task():
dict_task['filters'] = json.dumps(dict_task['filters'], indent=4)
if objs:
dict_task['objs'] = ail_objects.get_objects_meta(retro_hunt.get_objs(), flask_context=True)
dict_task['objs'] = ail_objects.get_objects_meta(retro_hunt.get_objs(), options={'last_full_date'}, flask_context=True)
else:
dict_task['objs'] = []

View file

@ -204,7 +204,7 @@
<th>Type</th>
<th></th>
<th>Id</th>
<th>Tags</th>
<th>Last Date</th>
<th></th>
</tr>
</thead>
@ -226,11 +226,16 @@
<a href="{{ object['link'] }}">
{{ object['id']}}
</a>
</td>
<td>
<div>
{% for tag in object['tags'] %}
<span class="badge badge-{{ bootstrap_label[loop.index0 % 5] }} pull-left">{{ tag }}</span>
{% endfor %}
</div>
</td>
<td>
{% if object['last_full_date'] %}
{{ object['last_full_date']}}
{% endif %}
</td>
<td class="text-right">
{# <a href="{{ url_for('investigations_b.unregister_investigation') }}?uuid={{ tracker_metadata['uuid']}}&type={{ object['type'] }}&subtype={{ object['subtype']}}&id={{ object['id']}}">#}