{% load humanize i18n %} {% comment %} The InvenTree panel injected into the left column of mapped objects' detail pages (template_content.InvenTreeSyncPanel, via NetBox's PluginContentPanel('left_page')). Context: - object: the NetBox object whose page is rendering - sync_rows: one entry per tracked link (mapping), each with `synced` (the SyncedObject), `label`, `url` (the InvenTree counterpart, '' when none exists yet) and `badge_color`. Empty when nothing is synced yet but an enabled mapping covers the model — then the muted "not synced" note shows. {% endcomment %}
{% trans "InvenTree" %}
{% for row in sync_rows %} {% empty %} {% endfor %}
{% if row.url %} {{ row.label }} {% else %} {{ row.label }} {% endif %} {{ row.synced.get_status_display }} {% if row.synced.last_synced_at %} · {% trans "synced" %} {{ row.synced.last_synced_at|naturaltime }} {% endif %} {% if row.synced.last_error %}
{{ row.synced.last_error|truncatechars:120 }}
{% endif %}
{% trans "Not synced yet — no InvenTree counterpart is tracked for this object." %}