vereinshaus/pocketbase/pb_migrations/1779230100_sepa_fields.js
rene 77c6f513b5 Feature: SEPA-Export, Push-Notifications, Onboarding + vollständige UI
- Phosphor Icons (Icon.svelte, svg-Registry)
- Schema-Abgleich: alle Felder zwischen PB-Migrations und types.ts konsistent
- Stripe entfernt, SEPA pain.008 XML-Export implementiert (sepa.ts)
- Beiträge: vollständiges CRUD + SEPA-Einzug-Sheet mit Vorschau
- Termine: vollständiges CRUD (upcoming/vergangen, datetime-local)
- Mitglieder: Formulare um alle Felder erweitert (Adresse, SEPA-Mandat, Notizen)
- Nachrichten: Brevo E-Mail via PocketBase-Hook, UI mit Gruppen-Filter
- Push-Notifications: VAPID, Custom Service Worker (injectManifest),
  Subscribe/Send API-Routen, automatische Subscription nach Login
- Onboarding: 3-Schritt-Flow für neue Vereine, Guard im App-Layout
- Makefile: .env wird vollständig zur DS übertragen
2026-05-20 13:01:11 +02:00

58 lines
2.1 KiB
JavaScript

/// <reference path="../pb_data/types.d.ts" />
migrate((app) => {
// vereine: +glaeubigerid, +iban, +bic (Vereinskonto für SEPA-Einzug)
{
const c = app.findCollectionByNameOrId("pbc_3589557411")
c.fields.addAt(99, new Field({
"type": "text", "id": "text2001000050", "name": "glaeubigerid",
"help": "", "hidden": false, "presentable": false, "required": false, "system": false,
"autogeneratePattern": "", "min": 0, "max": 0, "pattern": ""
}))
c.fields.addAt(99, new Field({
"type": "text", "id": "text2001000051", "name": "iban",
"help": "", "hidden": false, "presentable": false, "required": false, "system": false,
"autogeneratePattern": "", "min": 0, "max": 0, "pattern": ""
}))
c.fields.addAt(99, new Field({
"type": "text", "id": "text2001000052", "name": "bic",
"help": "", "hidden": false, "presentable": false, "required": false, "system": false,
"autogeneratePattern": "", "min": 0, "max": 0, "pattern": ""
}))
app.save(c)
}
// mitglieder: +mandatsreferenz, +mandatsdatum (SEPA-Mandat des Mitglieds)
{
const c = app.findCollectionByNameOrId("pbc_2707111162")
c.fields.addAt(99, new Field({
"type": "text", "id": "text2001000053", "name": "mandatsreferenz",
"help": "", "hidden": false, "presentable": false, "required": false, "system": false,
"autogeneratePattern": "", "min": 0, "max": 0, "pattern": ""
}))
c.fields.addAt(99, new Field({
"type": "date", "id": "date2001000054", "name": "mandatsdatum",
"help": "", "hidden": false, "presentable": false, "required": false, "system": false,
"min": "", "max": ""
}))
app.save(c)
}
}, (app) => {
{
const c = app.findCollectionByNameOrId("pbc_3589557411")
c.fields.removeById("text2001000050")
c.fields.removeById("text2001000051")
c.fields.removeById("text2001000052")
app.save(c)
}
{
const c = app.findCollectionByNameOrId("pbc_2707111162")
c.fields.removeById("text2001000053")
c.fields.removeById("date2001000054")
app.save(c)
}
})