50 lines
2.3 KiB
HTML
{% extends "base.html" %}
| |||
| |||
{% block title %}Результаты оптимизации - Веб-приложение для оптимизации Adwizard{% endblock %}
| |||
| |||
{% block content %}
| |||
<div class="row">
| |||
<div class="col-md-12">
| |||
<h2>Результаты оптимизации (последние 50 проходов)</h2>
| |||
| |||
{% if passes %}
| |||
<table class="table table-striped table-hover">
| |||
<thead>
| |||
<tr>
| |||
<th>ID</th>
| |||
<th>Задача</th>
| |||
<th>ID прохода</th>
| |||
<th>Прибыль</th>
| |||
<th>Фактор прибыли</th>
| |||
<th>Коэффициент Шарпа</th>
| |||
<th>Восстановительный фактор</th>
| |||
<th>Дата</th>
| |||
<th>Действия</th>
| |||
</tr>
| |||
</thead>
| |||
<tbody>
| |||
{% for pass in passes %}
| |||
<tr>
| |||
<td>{{ pass.id_pass }}</td>
| |||
<td>{{ pass.task.id_task }}</td>
| |||
<td>{{ pass.id_pass or 'N/A' }}</td>
| |||
<td>{{ "%.2f"|format(pass.profit|float) if pass.profit else 'N/A' }}</td>
| |||
<td>{{ "%.2f"|format(pass.profit_factor|float) if pass.profit_factor else 'N/A' }}</td>
| |||
<td>{{ "%.2f"|format(pass.sharpe_ratio|float) if pass.sharpe_ratio else 'N/A' }}</td>
| |||
<td>{{ "%.2f"|format(pass.recovery_factor|float) if pass.recovery_factor else 'N/A' }}</td>
| |||
<td>{{ pass.pass_date if pass.pass_date else 'N/A' }}</td>
| |||
<td>
| |||
<a href="{{ url_for('task_detail', task_id=pass.id_task) }}" class="btn btn-sm btn-outline-primary">К задаче</a>
| |||
</td>
| |||
</tr>
| |||
{% endfor %}
| |||
</tbody>
| |||
</table>
| |||
{% else %}
| |||
<div class="alert alert-info">
| |||
<p>В базе данных пока нет результатов оптимизации.</p>
| |||
</div>
| |||
{% endif %}
| |||
</div>
| |||
</div>
| |||
{% endblock %}
|