{% extends "base.html" %} {% block title %}Instrument #{{ instrument.id }}: {{ instrument.name }} — {{ service_name }}{% endblock %} {% block content %}

{{ instrument.name }}

{% if instrument.is_hidden %}

This instrument has been hidden from instrument lists.

{% endif %} {% if instrument.description_as_html or instrument.description %}
{% if instrument.description_as_html %}{{ instrument.description_as_html | safe }}{% else %}

{{ instrument.description }}

{% endif %}
{% endif %} {% include "instruments/instrument_scientists.html" %} {% if not current_user.is_readonly %} {% if current_user.is_admin or current_user in instrument.responsible_users %} Edit Instrument {% endif %} {% endif %}

Actions

{% for action in instrument.actions %} {% if not action.is_hidden or current_user.is_admin %}

{{ action.name }}

{% if action.description_as_html %}{{ action.description_as_html | safe }}{% else %}

{{ action.description }}

{% endif %} {{ action.type.view_text }} {% if not current_user.is_readonly %} {{ action.type.perform_text }} {% endif %} {% endif %} {% endfor %} {% if is_instrument_responsible_user %}

Instrument Scientist Notes

These notes are only visible to the instrument scientists. Read more.

{% if instrument.notes_as_html or instrument.notes %}
{% if instrument.notes_as_html %}{{ instrument.notes_as_html | safe }}{% else %}

{{ instrument.notes }}

{% endif %}
{% else %} — {% endif %} {% endif %} {% if is_instrument_responsible_user or instrument.users_can_create_log_entries or instrument.users_can_view_log_entries %}

Instrument Log

{% if is_instrument_responsible_user %} Instrument scientists can use the instrument log to keep track of problems, maintenance or other events. Instrument scientists can edit the instrument settings to configure whether users can create or view log entries. {% if instrument.users_can_view_log_entries and instrument.users_can_create_log_entries %} Currently, users can create and view log entries. {% elif instrument.users_can_create_log_entries %} Currently, users cannot view log entries, but they can create new entries. {% elif instrument.users_can_view_log_entries %} Currently, users can view log entries, but they cannot create new entries. {% else %} Currently, users can neither create nor view log entries. {% endif %} {% else %} {% if instrument.users_can_view_log_entries %} Instrument scientists can use the instrument log to keep track of problems, maintenance or other events. {% endif %} {% if instrument.users_can_create_log_entries %} Users can create entries in the instrument log to notify instrument scientists about any issues they encounter. {% endif %} {% endif %} Read more.

{% if is_instrument_responsible_user or instrument.users_can_view_log_entries %} {% if instrument_log_entries %}
{% if not current_user.is_readonly and (is_instrument_responsible_user or instrument.users_can_create_log_entries) %} {% endif %}
{% for log_entry in instrument_log_entries %}
{% for category in log_entry.versions[-1].categories %} {{ category.title }} {% endfor %}
{% if log_entry.versions[-1].content %}
{{ log_entry.versions[-1].content }}
{% else %} — {% endif %}
{{ log_entry.author.name }}, {% if log_entry.versions | length > 1 %}{{ log_entry.versions[0].utc_datetime.strftime('%Y-%m-%d %H:%M:%S') }} – {{ log_entry.versions[-1].utc_datetime.strftime('%Y-%m-%d %H:%M:%S') }}{% else %}{{ log_entry.versions[-1].utc_datetime.strftime('%Y-%m-%d %H:%M:%S') }}{% endif %}
{% if log_entry.versions[:-1] %}
{% if log_entry.user_id == current_user.id and not current_user.is_readonly %} / Edit log entry{% endif %}
{% for version in log_entry.versions[:-1] | reverse %}

{% if version.content %}
{{ version.content }}
{% else %} — {% endif %}
{{ version.utc_datetime.strftime('%Y-%m-%d %H:%M:%S') }}
{% endfor %} {% elif log_entry.user_id == current_user.id and not current_user.is_readonly %}
Edit log entry
{% endif %} {% if log_entry.file_attachments or log_entry.object_attachments %}
{% endif %} {% set file_attachments = log_entry.file_attachments %} {% if file_attachments %}
Attached Files:
    {% with hidden_file_attachments = [] %} {% for file_attachment in file_attachments %}{% if not file_attachment.is_hidden %}
  • {% if file_attachment | attachment_is_image %}  Fullscreen Image Preview {% else %} {% endif %} {{ file_attachment.file_name }}
  • {% else %}{{ hidden_file_attachments.append(file_attachment) or '' }}{% endif %}{% endfor %} {% if hidden_file_attachments %}
  • {{ hidden_file_attachments | length }} hidden file{% if hidden_file_attachments | length > 1 %}s{% endif %}
  • {% endif %} {% endwith %}
{% endif %} {% set object_attachments = log_entry.object_attachments %} {% if object_attachments %}
Attached Objects:
{% endif %}
{% if not current_user.is_readonly and log_entry.user_id == current_user.id %} {% endif %}
{% endfor %}
{% else %}

There are no log entries for this instrument.

{% if not current_user.is_readonly and (is_instrument_responsible_user or instrument.users_can_create_log_entries) %} {% endif %} {% endif %} {% endif %} {% if not current_user.is_readonly and (is_instrument_responsible_user or instrument.users_can_create_log_entries) %} {% set log_entry_text_missing = [] %} {% for message in get_flashed_messages() %} {% if 'Please enter a log entry text' in message %} {{ log_entry_text_missing.append(True) or '' }} {% endif %} {% endfor %} {% endif %} {% endif %} {% if mobile_upload_qrcode and mobile_upload_url%} {% endif %} {% endblock %} {% block stylesheets %} {{ super() }} {% endblock %} {% block scripts %} {{ super() }} {% if config['LOAD_OBJECTS_IN_BACKGROUND'] %} {% endif %} {% endblock %}