Lizenzmodell: Plan-Anzeige in Einstellungen, SEPA-Gate für Free-Plan
This commit is contained in:
parent
b8e2a69912
commit
95c2dc0f26
2 changed files with 119 additions and 7 deletions
|
|
@ -20,6 +20,11 @@
|
|||
let saving = $state(false);
|
||||
let formError = $state('');
|
||||
|
||||
// Plan-Check
|
||||
const hatSepa = $derived(
|
||||
verein?.plan && ['starter', 'wachstum', 'verband'].includes(verein.plan)
|
||||
);
|
||||
|
||||
// --- SEPA-Export ---
|
||||
let sepaFor = $state<Beitrag | null>(null);
|
||||
let einzugsdatum = $state(minEinzugsdatum());
|
||||
|
|
@ -189,9 +194,14 @@
|
|||
<button class="btn-primary" onclick={neuerBeitrag}>+ Beitragsart</button>
|
||||
</div>
|
||||
|
||||
{#if sepaFehlt && !loading}
|
||||
{#if !loading && !hatSepa}
|
||||
<div class="plan-hinweis">
|
||||
<strong>SEPA-Export</strong> ist im <strong>Starter-Plan</strong> verfügbar (7 €/Monat).
|
||||
<a href="/einstellungen">Jetzt upgraden →</a>
|
||||
</div>
|
||||
{:else if sepaFehlt && !loading}
|
||||
<div class="hinweis">
|
||||
SEPA-Einzug nicht möglich: Gläubiger-ID, IBAN und BIC des Vereins fehlen noch in den Einstellungen.
|
||||
SEPA-Einzug nicht möglich: Gläubiger-ID, IBAN und BIC des Vereins fehlen noch in den <a href="/einstellungen">Einstellungen</a>.
|
||||
</div>
|
||||
{/if}
|
||||
|
||||
|
|
@ -214,7 +224,7 @@
|
|||
</span>
|
||||
</div>
|
||||
<div class="karte-aktionen">
|
||||
<button class="btn-sepa" onclick={() => sepaOeffnen(b)} disabled={sepaFehlt}>
|
||||
<button class="btn-sepa" onclick={() => sepaOeffnen(b)} disabled={sepaFehlt || !hatSepa}>
|
||||
SEPA
|
||||
</button>
|
||||
<button class="btn-icon" onclick={() => bearbeiten(b)} title="Bearbeiten">✎</button>
|
||||
|
|
@ -344,6 +354,12 @@
|
|||
}
|
||||
h1 { font-size: 1.4rem; font-weight: 700; color: #1e293b; }
|
||||
|
||||
.plan-hinweis {
|
||||
background: #eff6ff; border: 1px solid #bfdbfe; border-radius: 8px;
|
||||
padding: 0.75rem 1rem; font-size: 0.875rem; color: #1e40af; margin-bottom: 1rem;
|
||||
}
|
||||
.plan-hinweis a { color: #1e40af; font-weight: 700; }
|
||||
|
||||
.hinweis {
|
||||
background: #fef9c3;
|
||||
border: 1px solid #fde047;
|
||||
|
|
@ -353,6 +369,7 @@
|
|||
color: #713f12;
|
||||
margin-bottom: 1rem;
|
||||
}
|
||||
.hinweis a { color: #713f12; }
|
||||
|
||||
.hint { color: #94a3b8; font-size: 0.95rem; text-align: center; margin-top: 3rem; }
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue