TheHive-Project / TheHive

TheHive: a Scalable, Open Source and Free Security Incident Response Platform
https://thehive-project.org
GNU Affero General Public License v3.0
3.42k stars 623 forks source link

Sorted display of case templates #1006

Open ITServ-DE opened 5 years ago

ITServ-DE commented 5 years ago

Request Type

Feature Request

Work Environment

Question Answer
OS version (server) Ubuntu
OS version (client) Windows
TheHive version / git hash 3.3.0-1
Package Type DEB

Problem Description

Case templates should be sortable or - at least - displayed sorted on all occurences.

When importing an alert, I can pick a case template from the menu. However, this menu is (practically) unsorted. This way, it's hard to find the correct case template if you have many of them.

07-06-_2019_09-42-21

Possible Solutions

When displaying the list of available case templates, always soft them by name. If someone want's to have a different order, he/she could workaround by adding numbers, grouping names, whatsoever.

nadouani commented 5 years ago

I'm not sure what sort is used in that list, but it's probably the the same order defined in the case template list. @github-pba Can you please confirm?

ITServ-DE commented 5 years ago

Confirmed. The order in this menu is the same as in the case template list.

But: the "sort order" is the order in which the case templates were defined. As you will probably not implement a perfectly ordered list of templates at the very first time, you can assume the list order as "unsorted" in the moment you add further templates.

For that reason, the list should be orderable either manually or at least be automatically sorted by the case template name.

Thank you

ITServ-DE commented 5 years ago

@nadouani you said it's "... the same sort order used in the case template [definition] list".

Do you agree with me the list is unsorted and I am not missing anything?

ITServ-DE commented 5 years ago

I have sent a Pull Request with a fix.