diff --git a/sigi/apps/utils/admin.py b/sigi/apps/utils/admin.py index 0dcbf20..5279135 100644 --- a/sigi/apps/utils/admin.py +++ b/sigi/apps/utils/admin.py @@ -31,12 +31,19 @@ class JobScheduleInline(admin.TabularInline): return False @mark_safe - @admin.display(description=_("executar")) + @admin.display(description=_("Ver/executar")) def get_runner(self, sched): if sched.status == JobSchedule.STATUS_AGENDADO: url = reverse("admin:utils_jobschedule_runjob", args=[sched.id]) return ( - f"play_arrow" + f"" + "play_arrow" + ) + elif sched.status == JobSchedule.STATUS_CONCLUIDO: + url = reverse("admin:utils_jobschedule_change", args=[sched.id]) + return ( + f"" + "description" ) return "" diff --git a/sigi/menu_conf.yaml b/sigi/menu_conf.yaml index 4238cf4..f657305 100644 --- a/sigi/menu_conf.yaml +++ b/sigi/menu_conf.yaml @@ -21,7 +21,7 @@ admin_menu: - title: Jobs de cron view_name: admin:utils_cronjob_changelist - title: Jobs agendados - view_name: admin_utils_jobschedule_changelist + view_name: admin:utils_jobschedule_changelist querystr: status__exact=A main_menu: