{% extends 'usage/usage_base.html' %} {% load static %} {% load custom_tags_and_filters %} {% load billing_tags %} {% block extrahead %} {% endblock %} {% block usage_content %}

This data is provided for informational purposes and uses the latest rates.
Other adjustments/discounts might not be included in this information. {% if "adjustment_requests"|customization:"adjustment_requests_enabled" and adjustment_time_limit %}

Adjustment requests can be made for charges ending after {{ adjustment_time_limit.date }}. {% endif %}
{% if no_charges %}

There was no usage between {{ start_date|date }} and {{ end_date|date }}.

{% else %} {% if not "billing_rates"|customization:"rates_usage_hide_charges" %}
Total charges: {{ total_charges }} {% if pending_charges %}(includes {{ pending_charges }} pending){% endif %}
{% endif %} {% endif %}
{% regroup detailed_items by item_type as detailed_items_by_type %} {% for detailed_item in detailed_items_by_type %} {% if detailed_item.grouper.name == "MISSED_RESERVATION" %}

Missed reservations

{% for m in detailed_item.list %}
{{ m.item.reservation_item }}{{ m.rate_time_name_add }}
{% if explicitly_display_customer %} Missed by {{ m.user }}
{% endif %} {{ m.start }}
Charged to project {{ m.project }}
{% if not "billing_rates"|customization:"rates_usage_hide_charges" %} {{ m.billable_rate|default_if_none:"" }} {% endif %}
{% if m.item|can_be_adjusted:user %} {% include "usage/adjustment_request_button.html" with charge=m.item %} {% endif %} {% if not "billing_rates"|customization:"rates_usage_hide_charges" %}{{ m.billable_display_amount }}{% endif %}
{% endfor %} {% endif %} {% if detailed_item.grouper.name == "CONSUMABLE" %}

Supplies and consumables

{% for c in detailed_item.list %}
{{ c.consumable }}{{ c.rate_time_name_add }}
{% if explicitly_display_customer %} For {{ c.item.customer }}
{% endif %} Quantity {{ c.quantity }}
Purchased from {{ c.item.merchant }}
{{ c.start }}
Charged to project {{ c.project }}
{% if not "billing_rates"|customization:"rates_usage_hide_charges" %} {{ c.billable_rate|default_if_none:"" }} {% endif %}
{% if c.item|can_be_adjusted:user %} {% include "usage/adjustment_request_button.html" with charge=c.item %} {% endif %} {% if not "billing_rates"|customization:"rates_usage_hide_charges" %}{{ c.billable_display_amount }}{% endif %}
{% endfor %} {% endif %} {% if detailed_item.grouper.name == "STAFF_CHARGE" %}

Staff charges

{% for s in detailed_item.list %} {% if s.area %}
{{ s.area }}{{ s.rate_time_name_add }}
Area accessed by {{ s.proxy_user }} {% if explicitly_display_customer %} on behalf of {{ s.user }} {% else %} on your behalf {% endif %}
{{ s.start }}
{{ s.end|default_if_none:"In progress" }}
Charged to project {{ s.project }}
{% if not "billing_rates"|customization:"rates_usage_hide_charges" %} {{ s.billable_rate|default_if_none:"" }} {% endif %}
{% if s.item|can_be_adjusted:user %} {% include "usage/adjustment_request_button.html" with charge=s.item %} {% endif %} {% if not "billing_rates"|customization:"rates_usage_hide_charges" %}{{ s.billable_display_amount }}{% endif %}
{% elif s.tool %}
{{ s.tool }}{{ s.rate_time_name_add }}
Operated by {{ s.proxy_user }} {% if explicitly_display_customer %} on behalf of {{ s.user }} {% else %} on your behalf {% endif %}
{{ s.start }}
{{ s.end }}
Charged to project {{ s.project }}
{% if not "billing_rates"|customization:"rates_usage_hide_charges" %} {{ s.billable_rate|default_if_none:"" }} {% endif %}
{% if s.item|can_be_adjusted:user %} {% include "usage/adjustment_request_button.html" with charge=s.item %} {% endif %} {% if not "billing_rates"|customization:"rates_usage_hide_charges" %}{{ s.billable_display_amount }}{% endif %}
{% else %}
Work performed by {{ s.proxy_user }} {% if explicitly_display_customer %} on behalf of {{ s.user }} {% else %} on your behalf {% endif %} {{ s.rate_time_name_add }}
{% if s.item.note %} Charge note: {{ s.item.note|linebreaksbr }}
{% endif %} {{ s.start }}
{{ s.end }}
Charged to project {{ s.project }}
{% if not "billing_rates"|customization:"rates_usage_hide_charges" %} {{ s.billable_rate|default_if_none:"" }} {% endif %}
{% if s.item|can_be_adjusted:user %} {% include "usage/adjustment_request_button.html" with charge=s.item %} {% endif %} {% if not "billing_rates"|customization:"rates_usage_hide_charges" %}{{ s.billable_display_amount }}{% endif %}
{% endif %} {% endfor %} {% endif %} {% if detailed_item.grouper.name == "TRAINING" %}

Training sessions

{% for t in detailed_item.list %}
{{ t.tool }}{{ t.rate_time_name_add }}
{{ t.item.get_type_display }} training {% if explicitly_display_customer %}for {{ t.user }}{% endif %} for {{ t.quantity }} minutes taught by {{ t.proxy_user }} {{ t.start }}
Charged to project {{ t.project }}
{% if not "billing_rates"|customization:"rates_usage_hide_charges" %} {{ t.billable_rate|default_if_none:"" }} {% endif %}
{% if not "billing_rates"|customization:"rates_usage_hide_charges" %}{{ t.billable_display_amount }}{% endif %}
{% endfor %} {% endif %} {% if detailed_item.grouper.name == "AREA_ACCESS" %}

Area access

{% for a in detailed_item.list %}
{{ a.area }}{{ a.rate_time_name_add }}
{% if a.item.staff_charge %} Area accessed by {{ a.proxy_user }} {% if explicitly_display_customer %} on behalf of {{ a.user }} {% else %} on your behalf {% endif %}
{% else %} {% if explicitly_display_customer %} Area accessed by {{ a.user }}
{% endif %} {% endif %} {{ a.start }}
{{ a.end|default_if_none:"In progress" }}
Charged to project {{ a.project }}
{% if not "billing_rates"|customization:"rates_usage_hide_charges" %} {{ a.billable_rate|default_if_none:"" }} {% endif %}
{% if a.item|can_be_adjusted:user %} {% include "usage/adjustment_request_button.html" with charge=a.item %} {% endif %} {% if not "billing_rates"|customization:"rates_usage_hide_charges" %}{{ a.billable_display_amount }}{% endif %}
{% endfor %} {% endif %} {% if detailed_item.grouper.name == "TOOL_USAGE" %}

Tool usage

{% for u in detailed_item.list %}
{{ u.tool }}{{ u.rate_time_name_add }}
{% if u.user != u.proxy_user %} Operated by {{ u.proxy_user }} {% if explicitly_display_customer %} on behalf of {{ u.user }} {% else %} on your behalf {% endif %}
{% else %} {% if explicitly_display_customer %} Operated by {{ u.user }}
{% endif %} {% endif %} {{ u.start }}
{{ u.end }}
Charged to project {{ u.project }}
{% if not "billing_rates"|customization:"rates_usage_hide_charges" %} {{ u.billable_rate|default_if_none:"" }} {% endif %}
{% if u.item|can_be_adjusted:user %} {% include "usage/adjustment_request_button.html" with charge=u.item %} {% endif %} {% if not "billing_rates"|customization:"rates_usage_hide_charges" %}{{ u.billable_display_amount }}{% endif %}
{% if u.item.pre_run_data_json.items or u.item.post_run_data_json.items %} {% if u.item.pre_run_data_json.items %}
Pre run data
{% for question_name, data in u.item.pre_run_data_json.items %} {% if not data.readonly %} {% if data.type == 'group' %} {% else %} {% endif %} {% endif %} {% endfor %}
{{ data.title }} {% if data.title|slice:"-1:" != ":" %}:{% endif %} {% res_question_tbody data.user_input %}
{{ data.title }} {% if data.title|slice:"-1:" != ":" %}:{% endif %} {{ data.user_input|linebreaksbr }}
{% endif %} {% if u.item.post_run_data_json.items %}
Post run data
{% for question_name, data in u.item.post_run_data_json.items %} {% if not data.readonly %} {% if data.type == 'group' %} {% else %} {% endif %} {% endif %} {% endfor %}
{{ data.title }} {% if data.title|slice:"-1:" != ":" %}:{% endif %} {% res_question_tbody data.user_input %}
{{ data.title }} {% if data.title|slice:"-1:" != ":" %}:{% endif %} {{ data.user_input|linebreaksbr }}
{% endif %} {% endif %}
{% endfor %} {% endif %} {% if detailed_item.grouper.name == "CUSTOM_CHARGE" %}

Custom charges

{% for c in detailed_item.list %}
{{ c.item.name }}
{% if explicitly_display_customer %} For {{ c.user }}
{% endif %}
{{ c.start }}
Charged to project {{ c.project }}
{% if not "billing_rates"|customization:"rates_usage_hide_charges" %} {{ c.billable_rate|default_if_none:"" }} {% endif %}
{% if not "billing_rates"|customization:"rates_usage_hide_charges" %}{{ c.billable_display_amount }}{% endif %}
{% endfor %} {% endif %} {% endfor %}
{% endblock %}