33 lines
1.0 KiB
HTML
33 lines
1.0 KiB
HTML
{% extends "base.html" %}
|
|
{% block title %}New Babystep · Superior Finance{% endblock %}
|
|
{% block content %}
|
|
<h1>New Babystep</h1>
|
|
{% if not goals %}
|
|
<p class="empty">You need a goal before you can add a babystep. <a href="{{ url_for('new_goal') }}">Create one first</a>.</p>
|
|
{% else %}
|
|
<form method="post">
|
|
<label>Goal
|
|
<select name="goal_id" required>
|
|
{% for goal in goals %}
|
|
<option value="{{ goal.id }}">{{ goal.title }}</option>
|
|
{% endfor %}
|
|
</select>
|
|
</label>
|
|
<label>Title
|
|
<input type="text" name="title" required>
|
|
</label>
|
|
<label>Description
|
|
<textarea name="description" rows="3"></textarea>
|
|
</label>
|
|
<label>Monthly amount ($)
|
|
<input type="number" name="monthly_amount" min="1" required>
|
|
</label>
|
|
<label class="checkbox-row">
|
|
<input type="checkbox" name="completed">
|
|
Already achieved
|
|
</label>
|
|
<button type="submit">Create Babystep</button>
|
|
</form>
|
|
{% endif %}
|
|
{% endblock %}
|