{% if record %} {% if record.device__device_type__model %} {% elif record.inventory_item__part_id %} {% endif %} {% endif %}