metatroncubeswdev 190e51a7da feat(community_membership): QR card, verification endpoint, member portal (Session 1-C)
Adds a QWeb PDF "Membership Card" report (85x54mm landscape, custom
report.paperformat) showing the company logo, member name/ID, tier, and
a QR code generated with the qrcode library (embedded as a base64 PNG via
a non-stored res.partner.membership_card_qr compute field). The QR encodes
a public verification URL built from ir.config_parameter's web.base.url.

Adds the public GET /membership/verify/<member_id> controller: shows
valid/expired/not-found with no personal data beyond name (and tier, for
valid members) - internal states like 'invoiced'/'none' are deliberately
reported as not-found so partial signup state isn't leaked.

Adds the member portal: /my/membership (status/tier/expiry), /my/membership/
renew (finds or creates a draft renewal invoice, redirects to the existing
portal invoice page), and /my/membership/card (PDF download) - plus a
"Membership" entry card on the main /my portal home page. Since
community_theme_base doesn't exist yet (that's Phase 6), the card uses
res.company.logo rather than a theme setting - still brand-neutral,
just resolved from the standard company record for now.

Verified against a live Odoo 19 + Postgres 16 container, both via the
test suite (12/12 tests: unit tests, HttpCase tests hitting the real verify
endpoint for valid/expired/unknown IDs) and by hand end-to-end - created a
tier and member over JSON-RPC, activated the membership, fetched the live
/membership/verify/ page, and rendered the actual PDF card via
/report/pdf/... (11.7KB single-page PDF, confirmed non-blank).

Along the way, hit a third real Odoo 19 API change: res.users.groups_id
was renamed to group_ids.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-17 21:19:30 -04:00

54 lines
1.8 KiB
Python

{
'name': 'Community OS - Membership',
'version': '19.0.1.0.0',
'category': 'Sales/Members',
'summary': 'Configurable membership tiers, family grouping, renewals, QR membership card and self-service portal',
'description': """
Community OS - Membership
===========================
A fully generic membership engine for community and cultural organizations:
* Admin-configurable membership tiers (name, price, period) - never hardcoded
* Family grouping and auto-generated member IDs (configurable format)
* Automated renewal reminders, expiry handling, and draft renewal invoices
* Self-service member portal (status, tier, expiry, renew, download card)
* QR-coded membership card (PDF) with a public verification endpoint
No client names, prices, or branding are hardcoded - everything is a
configuration record managed by the deployment layer.
""",
'author': 'Metatroncube Software Solutions LLP',
'website': 'https://www.metatroncube.com',
'license': 'LGPL-3',
'price': 0.00,
'currency': 'USD',
'depends': [
'contacts',
'account',
'portal',
'website',
],
'data': [
'security/membership_security.xml',
'security/ir.model.access.csv',
'data/ir_sequence.xml',
'data/mail_templates.xml',
'data/ir_cron.xml',
'report/membership_card_report.xml',
'views/membership_tier_views.xml',
'views/res_partner_views.xml',
'views/res_config_settings_views.xml',
'views/membership_menus.xml',
'views/portal_templates.xml',
'views/membership_verify_templates.xml',
],
'demo': [],
'images': ['static/description/banner.png'],
'application': True,
'installable': True,
'external_dependencies': {
'python': ['qrcode'],
},
}