Vermietungs-Tool
A local web app for a small room-rental business in Austria: guest register, room ledger, occupancy plan, invoices, the monthly tourist-tax report and the quarterly VAT list. Application code only; it ships no data. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
commit
45424e6fd6
47 files changed
+6701
No files matched your search
@@ -0,0 +1,87 @@
|
||||
{% extends "base.html" %}
|
||||
{% block main_class %}grid-page{% endblock %}
|
||||
{% block content %}
|
||||
<h1>{{ t('plan_title') }}</h1>
|
||||
<div class="toolbar">
|
||||
<a class="btn secondary small" href="{{ url_for('plan_page', start=p.prev_start, weeks=weeks) }}"
|
||||
title="{{ t('plan_prev_week') }}">◀</a>
|
||||
<a class="btn secondary small" href="{{ url_for('plan_page', weeks=weeks) }}">{{ t('plan_today') }}</a>
|
||||
<a class="btn secondary small" href="{{ url_for('plan_page', start=p.next_start, weeks=weeks) }}"
|
||||
title="{{ t('plan_next_week') }}">▶</a>
|
||||
<span class="count">{{ p.start.isoformat()|date }} – {{ p.last|date }}</span>
|
||||
<span class="seg">
|
||||
<a class="{{ 'on' if weeks == 4 }}" href="{{ url_for('plan_page', start=p.start.isoformat(), weeks=4) }}">{{ t('plan_weeks_4') }}</a>
|
||||
<a class="{{ 'on' if weeks == 8 }}" href="{{ url_for('plan_page', start=p.start.isoformat(), weeks=8) }}">{{ t('plan_weeks_8') }}</a>
|
||||
</span>
|
||||
<span class="spacer"></span>
|
||||
<span class="count">{{ t('plan_guests_one') if p.guests_today == 1 else t('plan_guests', guests=p.guests_today) }} · {{ t('plan_free_one') if p.free_beds == 1 else t('plan_free', free=p.free_beds) }}</span>
|
||||
</div>
|
||||
|
||||
<div class="tablewrap planwrap">
|
||||
<div class="plan" style="--days:{{ p.n_days }}">
|
||||
<div class="plan-head">
|
||||
<div class="plan-hrow">
|
||||
<div class="plan-label"></div>
|
||||
<div class="plan-cells">
|
||||
{% for m in p.months %}<div class="pm" style="grid-column:span {{ m.span }}">{{ m.text }}</div>{% endfor %}
|
||||
</div>
|
||||
</div>
|
||||
<div class="plan-hrow">
|
||||
<div class="plan-label"></div>
|
||||
<div class="plan-cells plan-daysrow">
|
||||
{% for d in p.days %}
|
||||
<div class="pd{{ ' we' if d.weekend }}{{ ' today' if d.today }}{{ ' mon' if d.monday }}{{ ' m1' if d.month_start }}">
|
||||
{% if p.n_days <= 35 %}<b>{{ d.dom }}</b><span>{{ d.wd }}</span>
|
||||
{% elif d.monday %}<b>{{ d.label }}</b>{% endif %}
|
||||
</div>
|
||||
{% endfor %}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{% for r in p.rooms %}
|
||||
<div class="plan-row{{ ' newfloor' if loop.index0 and r.floor != p.rooms[loop.index0 - 1].floor }}">
|
||||
<div class="plan-label">
|
||||
<div class="rl-top"><b>{{ t('plan_room', number=r.number) }}</b>
|
||||
{% if r.long_term %}
|
||||
<span class="pill unit" title="{{ t('plan_longterm') }}">{{ t('plan_longterm_short') }}</span>
|
||||
{% else %}
|
||||
<span class="pill {{ 'open' if r.today_count > r.capacity else ('have' if r.today_count >= r.capacity else 'paid') }}"
|
||||
title="{{ t('plan_pill_tip') }}">{{ r.today_count }}/{{ r.capacity }}</span>
|
||||
{% endif %}
|
||||
</div>
|
||||
<div class="rl-sub">{{ r.category }} · {{ r.unit }}</div>
|
||||
</div>
|
||||
<div class="plan-cells plan-lanes{{ ' longterm' if r.long_term }}" style="--lanes:{{ r.lanes }}">
|
||||
{# day lines live in their own full-height overlay: as grid items they could neither
|
||||
overlap the bars (auto-placement) nor reach below the last lane when the room label
|
||||
makes the row taller than the lane stack #}
|
||||
<div class="daylines">
|
||||
{% for d in p.days %}<i class="{{ 'we' if d.weekend }}{{ ' today' if d.today }}{{ ' mon' if d.monday }}{{ ' m1' if d.month_start }}"></i>{% endfor %}
|
||||
</div>
|
||||
{% if r.long_term and not r.bars %}<div class="lt-note">{{ t('plan_longterm') }}</div>{% endif %}
|
||||
{% for b in r.bars %}
|
||||
<a class="bar {{ b.state }}{{ ' clipstart' if b.clip_start }}{{ ' clipend' if b.clip_end }}"
|
||||
style="grid-column:{{ b.col }}/{{ b.col_end }};grid-row:{{ b.lane }}"
|
||||
href="{{ url_for('stay_form', stay_id=b.stay_id) }}"
|
||||
title="{{ b.name }} · {{ b.arrival|date }} – {{ b.departure|date if b.departure else t('plan_open') }}{% if b.sheet_number %} · {{ t('plan_sheet', number=b.sheet_number) }}{% endif %}{% if b.employer %} · {{ b.employer }}{% endif %}">{{ b.name }}</a>
|
||||
{% endfor %}
|
||||
</div>
|
||||
</div>
|
||||
{% endfor %}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="plan-foot">
|
||||
<span><span class="key" style="background:var(--accent)"></span>{{ t('plan_legend_current') }}</span>
|
||||
<span><span class="key" style="background:#b9c9c0"></span>{{ t('plan_legend_past') }}</span>
|
||||
<span><span class="key" style="background:var(--accent-soft);box-shadow:inset 0 0 0 1px var(--accent)"></span>{{ t('plan_legend_future') }}</span>
|
||||
<span><span class="key" style="background:#fff3d6;box-shadow:inset 0 0 0 1px var(--warn)"></span>{{ t('plan_legend_today') }}</span>
|
||||
{% if p.unplaced %}
|
||||
<span class="plan-unplaced">{{ t('plan_no_room') }}
|
||||
{% for u in p.unplaced %}
|
||||
<a href="{{ url_for('stay_form', stay_id=u.id) }}">{{ u.name }} ({{ u.arrival|date }} – {{ u.departure|date if u.departure else t('plan_open') }})</a>{{ ', ' if not loop.last }}
|
||||
{% endfor %}
|
||||
</span>
|
||||
{% endif %}
|
||||
</div>
|
||||
{% endblock %}
|
||||
Reference in new issue
Block a user