Correct Current Cycle and add styling to new/update
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
fa7d46623e
commit
ebee2d514c
@ -1,15 +1,31 @@
|
|||||||
{% extends 'base.html' %}
|
{% extends 'base.html' %}
|
||||||
|
|
||||||
{% block header %}
|
|
||||||
<h1>{% block title %}New Cycle{% endblock %}</h1>
|
|
||||||
{% endblock %}
|
|
||||||
|
|
||||||
{% block content %}
|
{% block content %}
|
||||||
|
|
||||||
|
|
||||||
|
<div class="container-fluid">
|
||||||
|
<div class="table-responsive">
|
||||||
|
<div class="table-wrapper">
|
||||||
|
<div class="table-title">
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-6">
|
||||||
|
{% block header %}
|
||||||
|
<h2>{% block title %}New Cycle{% endblock %}</h2>
|
||||||
|
{% endblock %}
|
||||||
|
</div>
|
||||||
|
<div class="col-sm-6">
|
||||||
|
<a class="btn btn-primary" href="{{ url_for('cycles.create') }}">New Cycle</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
<form method="post">
|
<form method="post">
|
||||||
<label for="start_time">Start Time</label>
|
<label for="start_time">Start Time</label>
|
||||||
<input name="start_time" id="title" value="{{ request.form['start_time'] }}" required type="date">
|
<input name="start_time" id="title" value="{{ request.form['start_time'] }}" required type="date">
|
||||||
|
<br><br>
|
||||||
<label for="end_time">End Time</label>
|
<label for="end_time">End Time</label>
|
||||||
<input name="end_time" id="end_time" value="{{ request.form['end_time'] }}" type="date">
|
<input name="end_time" id="end_time" value="{{ request.form['end_time'] }}" type="date">
|
||||||
|
<br>
|
||||||
<input type="submit" value="Save">
|
<input type="submit" value="Save">
|
||||||
</form>
|
</form>
|
||||||
{% endblock %}
|
{% endblock %}
|
@ -24,7 +24,7 @@
|
|||||||
<h5 class="card-title">
|
<h5 class="card-title">
|
||||||
{% if cycle['cycle_length'] %}
|
{% if cycle['cycle_length'] %}
|
||||||
{% if loop.first %}
|
{% if loop.first %}
|
||||||
Day <b>{{ cycle['cycle_length'] }}</b>
|
Day <b>{{ cycle['cycle_length'] - 1 }}</b>
|
||||||
{% else %}
|
{% else %}
|
||||||
<b>{{ cycle['cycle_length'] }}</b> days.
|
<b>{{ cycle['cycle_length'] }}</b> days.
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
@ -1,13 +1,28 @@
|
|||||||
{% extends 'base.html' %}
|
{% extends 'base.html' %}
|
||||||
|
|
||||||
{% block header %}
|
|
||||||
<h1>{% block title %}Edit Cycle{% endblock %}</h1>
|
|
||||||
{% endblock %}
|
|
||||||
|
|
||||||
{% block content %}
|
{% block content %}
|
||||||
|
|
||||||
|
|
||||||
|
<div class="container-fluid">
|
||||||
|
<div class="table-responsive">
|
||||||
|
<div class="table-wrapper">
|
||||||
|
<div class="table-title">
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-6">
|
||||||
|
{% block header %}
|
||||||
|
<h2>{% block title %}Edit Cycle{% endblock %}</h2>
|
||||||
|
{% endblock %}
|
||||||
|
</div>
|
||||||
|
<div class="col-sm-6">
|
||||||
|
<a class="btn btn-primary" href="{{ url_for('cycles.create') }}">New Cycle</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
<form method="post">
|
<form method="post">
|
||||||
<label for="start_time">Start Time</label>
|
<label for="start_time">Start Time</label>
|
||||||
<input name="start_time" id="title" value="{{ request.form['start_time'] or cycle['start_time'][:10] }}" required type="date">
|
<input name="start_time" id="title" value="{{ request.form['start_time'] or cycle['start_time'][:10] }}" required type="date">
|
||||||
|
<br>
|
||||||
<label for="end_time">End Time</label>
|
<label for="end_time">End Time</label>
|
||||||
<input name="end_time" id="end_time" value="{{ request.form['end_time'] or cycle['end_time'][:10] if cycle['end_time'] is not none }}" type="date">
|
<input name="end_time" id="end_time" value="{{ request.form['end_time'] or cycle['end_time'][:10] if cycle['end_time'] is not none }}" type="date">
|
||||||
<input type="submit" value="Save">
|
<input type="submit" value="Save">
|
||||||
|
Loading…
Reference in New Issue
Block a user