KITPraktomatTeam / Praktomat

quality control for programming assignments
http://pp.ipd.kit.edu/projects/praktomat/praktomat.php
GNU General Public License v2.0
46 stars 22 forks source link

Admin solutions changelist view + Admin tasks changelist view: should have more logic while choosing colours and symbols for column entries #315

Open ifrh opened 3 years ago

ifrh commented 3 years ago

current behavior grafik You see the "Tests Failed" is coloured red having a white "x". That symbol should mean: "hey, here is a problem". But "having no failed tests" should not been calling like having a problem.

Expected behavior:

R(x) = symbol x with red circle => "not accepted solution" , "required tests failed", "Plagiarism detected" G(v) = symbol tick with green circle => "final solution", "accepted solution", "no tests failed", "no plagiarism" O(x) = symbol w with orange circle => in column tests failed : "only not required tests failed" B(v) = symbol tick with blue circle => in column final : "accepted but not final solution"

But perhaps not only the colour logic should be extended but also the symbolic should change: "Red triangle with x" for problem = R(x) "Green circle with tick" for no problem = G(v) "Orange triangle" for warning = O(x) "Blue circle with tick" for "neutral" or "at least not negativ information" = B(v)

Using circle and triangle helps colour-blind persons (see BGG NRW §10 "Barrierefreie Informationstechnik" or for BaWü L-BGG §10 "Barrierefreie mediale Angebote").

I think, that Django-Models itself do not need to change Boolean to other types.

ifrh commented 3 years ago

As mentioned on other websites, i.e.

it is possible to create sortable, filerable columns showed by admin list views using calculated "fields" having own HTML in strings. Withreturn format_html( " HTML-CODE" ): it should be possible to exchange the symbols in columns and the method logic has to choose which Symbol is used ...

ifrh commented 3 years ago

a use full overview: "How-to annotate a Django QuerySet with calculated properties, and use them in ModelAdmin for filtering and sorting (and in other places too)" https://marioorlandi.medium.com/how-to-annotate-a-django-queryset-with-calculated-properties-and-use-them-in-modeladmin-for-e21dc41ac27f

ifrh commented 3 years ago

That annotated querysets are sortable, I used in commit 11c11f5 to the feature_admin-solution-new-filter branch on ifrh/Praktomat for pullrequest https://github.com/KITPraktomatTeam/Praktomat/pull/314 Feature admin solution changelist view : add new filter "latest of only failed" + made annotated columns "tests failed" and "Latest of only failed" sortable

Therefor open is only the discussion if modifying the symbolic should happen. Perhaps if symbolic could be modified, than there could be a new symbol for admin task changelist view, too, which could mark for other trainers,admins which tasks are currently in state "run all checkers".