{% from "table_search.html" import table_search with context %} {% from "utils.html" import batch_state_indicator, submit_button, link, truncated_link %} {% extends "layout.html" %} {% block title %}Batches{% endblock %} {% block head %} {% endblock %} {% block content %}
| ID | Batch Name | {% for batch in batches %}|||||||
|---|---|---|---|---|---|---|---|---|
| {{ batch_state_indicator(batch) }} |
{{ link(base_path ~ "/batches/" ~ batch['id'], batch['id']) }}
|
{% if 'attributes' in batch and 'name' in batch['attributes'] %}
{{ truncated_link(base_path ~ "/batches/" ~ batch['id'], batch['attributes']['name']) }}
{% else %}
{{ truncated_link(base_path ~ "/batches/" ~ batch['id'], 'no name') }}
{% endif %}
|
{{ batch['billing_project'] }}
|
{% set statuses = [] %}
{% if batch['n_jobs'] - batch['n_completed'] != 0 %}
{% do statuses.append((batch['n_jobs'] - batch['n_completed'])|string ~ ' pending') %}
{% endif %}
{% if batch['n_succeeded'] != 0 %}
{% do statuses.append(batch['n_succeeded'] ~ ' succeeded') %}
{% endif %}
{% if batch['n_cancelled'] != 0 %}
{% do statuses.append(batch['n_cancelled'] ~ ' cancelled') %}
{% endif %}
{% if batch['n_failed'] != 0 %}
{% do statuses.append(batch['n_failed'] ~ ' failed') %}
{% endif %}
{{ statuses|join(', ') }}
|
{{ batch.get('time_created') or '' }} | {{ batch.get('time_completed') or '--' }} | {{ batch.get('duration') or '' }} | {{ batch.get('cost') or '' }} |