EMA
* adds Ema model (basically Compensation inherited) * adds index view for EMAs * fixes drop-down link bug for menu 'More' in navbar * refactors some more forms to use process_request() * adds modified attribute to BaseResource for easy last_modified check * adds setting of modified attribute in all places where UserAction.EDITED is added to log * adds EMA_ACCOUNT_IDENTIFIER_LENGTH and EMA_ACCOUNT_IDENTIFIER_TEMPLATE to ema/settings.py * adds EmaAdmin to ema/admin.py * fixes wrong title in intervention detail view html for revocations * adds support for subtitle variable to BaseTable and generic_index.html * drops next_version attribute from models * adds/updates translations * adds default ordering for UserActionLogEntry * removes extra ordering in log modal rendering
This commit is contained in:
@@ -50,7 +50,7 @@ class InterventionTable(BaseTable):
|
||||
lm = tables.Column(
|
||||
verbose_name=_("Last edit"),
|
||||
orderable=True,
|
||||
accessor="created__timestamp",
|
||||
accessor="modified__timestamp",
|
||||
)
|
||||
"""
|
||||
# ToDo: Decide to keep actions column or to dismiss them
|
||||
@@ -164,23 +164,3 @@ class InterventionTable(BaseTable):
|
||||
icn_class="fas fa-edit rlp-r-inv" if has_access else "far fa-edit",
|
||||
)
|
||||
return format_html(html)
|
||||
|
||||
def render_ac(self, value, record):
|
||||
"""
|
||||
Renders possible actions for this record, such as delete.
|
||||
"""
|
||||
intervention = _("Intervention")
|
||||
html = ""
|
||||
html += self.render_open_btn(
|
||||
_("Open {}").format(intervention),
|
||||
reverse("intervention:open", args=(record.id,))
|
||||
)
|
||||
html += self.render_edit_btn(
|
||||
_("Edit {}").format(intervention),
|
||||
reverse("intervention:edit", args=(record.id,)),
|
||||
)
|
||||
html += self.render_delete_btn(
|
||||
_("Delete {}").format(intervention),
|
||||
reverse("intervention:remove", args=(record.id,)),
|
||||
)
|
||||
return format_html(html)
|
||||
|
||||
Reference in New Issue
Block a user