Files
Personal-Finance-Management/app/templates/schwab/map_accounts.html
T
2026-06-02 17:05:44 -04:00

53 lines
2.3 KiB
HTML

{% extends "base.html" %}
{% block title %}Map Schwab Accounts{% endblock %}
{% block page_title %}Map Schwab Accounts{% endblock %}
{% block content %}
<div class="row justify-content-center">
<div class="col-12 col-lg-8">
<div class="pcard mb-3" style="background:#f0fdf4;border-color:#bbf7d0;">
<div style="font-size:13px;color:#166534;">
<i class="bi bi-info-circle me-1"></i>
Link each Schwab account to a PFM account, or create a new one automatically.
Accounts set to "Skip" won't be synced.
</div>
</div>
<div class="pcard">
<form method="POST">
<input type="hidden" name="csrf_token" value="{{ csrf_token() }}">
{% for sa in schwab_accounts %}
<div class="{% if not loop.last %}mb-4 pb-4{% endif %}" style="{% if not loop.last %}border-bottom:1px solid var(--border);{% endif %}">
<div class="d-flex align-items-center gap-2 mb-2">
<div style="width:32px;height:32px;border-radius:8px;background:#dbeafe;color:#1e40af;display:flex;align-items:center;justify-content:center;font-size:14px;">
<i class="bi bi-bank"></i>
</div>
<div>
<div style="font-size:14px;font-weight:600;">{{ sa.account_name }}</div>
<div style="font-size:11px;color:var(--muted);">{{ sa.account_number_display }} · {{ sa.account_type }}</div>
</div>
</div>
<select name="pfm_account_{{ sa.id }}" class="form-select form-select-sm" style="font-size:13px;">
<option value="">— Skip this account —</option>
<option value="new" {% if not sa.pfm_account_id %}{% endif %}>+ Create new PFM account</option>
{% for acct in pfm_accounts %}
<option value="{{ acct.id }}" {% if sa.pfm_account_id == acct.id %}selected{% endif %}>
{{ acct.name }} ({{ acct.account_type | replace('_',' ') | title }})
</option>
{% endfor %}
</select>
</div>
{% endfor %}
<div class="d-flex gap-2 mt-4">
<button type="submit" class="btn btn-primary">Save Mapping</button>
<a href="{{ url_for('schwab.index') }}" class="btn btn-outline-secondary">Cancel</a>
</div>
</form>
</div>
</div>
</div>
{% endblock %}