{% block view_css %}{% endblock %}
{% macro add_admin_console_nav(active=False) -%}
Admin Console
{%- endmacro %} {% macro add_user_admin_nav(active=False) -%}
Users
{%- endmacro %} {% macro add_dashboard_nav(active=False) -%}
Dashboard
{%- endmacro %} {% macro add_budgets_nav(active=False) -%}
Budgets
{%- endmacro %} {% macro add_budget_items_nav(active=False) -%}
Budget Items
{%- endmacro %} {% macro add_accounts_nav(active=False) -%}
Accounts
{%- endmacro %} {% macro add_transactions_nav(active=False) -%}
Transactions
{%- endmacro %} {% macro add_user_nav(edit=True, reset=True, logout=True) -%}
{{ user.username }}
{% if edit %}
Edit Profile
{% endif %} {% if reset %}
Reset Password
{% endif %} {% if logout %}
Logout
{% endif %}
{%- endmacro %} {% block nav_items %}{% endblock %}
{% with messages = get_flashed_messages(with_categories=true) %} {% if messages %} {% for category, message in messages %} {% if category == 'error' %}
{{ message }}
{% elif category == 'warning' %}
{{ message }}
{% else %}
{{ message }}
{% endif %} {% endfor %} {% endif %} {% endwith %}
{% macro add_edit_profile_modal() -%}
Edit Profile
{% macro user_profile_input(id, label, value='', type='text') -%}
{% if type != 'hidden' %}
{{ label }}
{% endif %}
{%- endmacro %} {{ user_profile_input(id='first_name', label='First Name:', value=user.first_name) }} {{ user_profile_input(id='middle_name', label='Middle Name:', value=user.middle_name) }} {{ user_profile_input(id='last_name', label='Last Name:', value=user.last_name) }} {{ user_profile_input(id='address_line_1', label='Address line 1:', value=user.address_line_1) }} {{ user_profile_input(id='address_line_2', label='Address line 2:', value=user.address_line_2) }} {{ user_profile_input(id='city', label='City:', value=user.city) }} {{ user_profile_input(id='state', label='State:', value=user.state) }} {{ user_profile_input(id='zipcode', label='Zipcode:', value=user.zipcode) }} {{ user_profile_input(id='email', label='Email:', value=user.email, type='email') }} {{ user_profile_input(id='phone_number', label='Phone Number:', value=user.phone_number) }}
{%- endmacro %} {% macro add_reset_password_modal() -%}
Reset Password
{% macro user_password_input(id, label, value='', type='text') -%}
{% if type != 'hidden' %}
{{ label }}
{% endif %}
{%- endmacro %} {{ user_password_input(id='username', label='Username:', value=user.username, type='hidden') }} {{ user_password_input(id='current_password', label='Current Password:', type='password') }} {{ user_password_input(id='new_password', label='New Password:', type='password') }} {{ user_password_input(id='confirm_password', label='Confirm New Password:', type='password') }}
{%- endmacro %} {% block modals %}{% endblock %}
{% block main_content %}{% endblock %}