Skip to content

add invitation - #863

Open
nananankona wants to merge 6 commits into
nextcloud:masterfrom
nananankona:master
Open

add invitation#863
nananankona wants to merge 6 commits into
nextcloud:masterfrom
nananankona:master

Conversation

@nananankona

Copy link
Copy Markdown

Allow-list with email domains (including wildcard) or exact email addresses to register with
Invitation codes and invitation links: restrict who can register, limit the number of uses per link, set a storage quota for invited users and optionally skip the email verification step

@tcitworld

Copy link
Copy Markdown
Member

Thanks! Will review when I get the time.

Do you mind rebasing so that the CI passes ? You may drop the css/js changes to make it easier, they can be recompiled here. Ideally, please remove the translation files changes as well, those are usually handled through Transifex.

@tcitworld
tcitworld self-requested a review September 1, 2026 21:03
…limits- Add invitation links (/apps/registration/invite/{code}) with optional email/domain restriction, storage quota, maximum number of uses and expiry date; the usage counter is incremented and the quota applied when an account is created- Add allowed email addresses setting (in addition to allowed domains)- Add option to require an invitation code for all registrations- Add invitation management UI to the admin settings

Signed-off-by: nananankona <[email protected]>
… bypass- Add skip_email_verification option to invitations: registrations via such an invitation skip the email verification step and go straight to the account creation form- Show the invitation code and shareable link in a dialog after creating an invitation, each with a copy button; add a Details button to the invitation list for the same dialog- Add Japanese translations (l10n/ja) for the invitation strings

Signed-off-by: nananankona <[email protected]>
…time-typed expires/created_at fields can be returned as DateTimeobjects from the entity, which JSON-encode as objects and break thefrontend formatting (TypeError: b.replace is not a function). Normalizedates to Y-m-d H:i:s strings in the controller and harden isExpired andformatDate against non-string values.

Signed-off-by: nananankona <[email protected]>
…skip_email_verification flag can return null from the entity when thecolumn is missing or unset, which broke the bool return type ofinvitationSkipsVerification() with a TypeError on invite links. Defaultthe flag to false in the entity constructor and compare with === trueinstead of relying on the raw value.

Signed-off-by: nananankona <[email protected]>
The backtick-quoted uses + 1 expression breaks on PostgreSQL and
Oracle, which do not accept backticks as identifier quotes. Use the
unquoted column reference instead (uses is not a reserved word).

Also guard domainMatches() against email addresses without an @ sign,
which previously raised an undefined key warning and a TypeError in the
wildcard branch instead of a clean RegistrationException.

Signed-off-by: nananankona <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants