stages/invitation: add invitation name
closes #2583 Signed-off-by: Jens Langhammer <jens.langhammer@beryju.org>
This commit is contained in:
@ -2350,7 +2350,6 @@ msgid "How to connect"
|
||||
msgstr "So verbinden Sie sich"
|
||||
|
||||
#: src/elements/forms/DeleteBulkForm.ts
|
||||
#: src/pages/stages/invitation/InvitationListPage.ts
|
||||
#: src/pages/users/RelatedUserList.ts
|
||||
#: src/pages/users/UserListPage.ts
|
||||
msgid "ID"
|
||||
@ -3048,6 +3047,8 @@ msgstr "Meine Anwendungen"
|
||||
#: src/pages/stages/dummy/DummyStageForm.ts
|
||||
#: src/pages/stages/email/EmailStageForm.ts
|
||||
#: src/pages/stages/identification/IdentificationStageForm.ts
|
||||
#: src/pages/stages/invitation/InvitationForm.ts
|
||||
#: src/pages/stages/invitation/InvitationListPage.ts
|
||||
#: src/pages/stages/invitation/InvitationStageForm.ts
|
||||
#: src/pages/stages/password/PasswordStageForm.ts
|
||||
#: src/pages/stages/prompt/PromptStageForm.ts
|
||||
|
@ -2383,7 +2383,6 @@ msgid "How to connect"
|
||||
msgstr "How to connect"
|
||||
|
||||
#: src/elements/forms/DeleteBulkForm.ts
|
||||
#: src/pages/stages/invitation/InvitationListPage.ts
|
||||
#: src/pages/users/RelatedUserList.ts
|
||||
#: src/pages/users/UserListPage.ts
|
||||
msgid "ID"
|
||||
@ -3093,6 +3092,8 @@ msgstr "My applications"
|
||||
#: src/pages/stages/dummy/DummyStageForm.ts
|
||||
#: src/pages/stages/email/EmailStageForm.ts
|
||||
#: src/pages/stages/identification/IdentificationStageForm.ts
|
||||
#: src/pages/stages/invitation/InvitationForm.ts
|
||||
#: src/pages/stages/invitation/InvitationListPage.ts
|
||||
#: src/pages/stages/invitation/InvitationStageForm.ts
|
||||
#: src/pages/stages/password/PasswordStageForm.ts
|
||||
#: src/pages/stages/prompt/PromptStageForm.ts
|
||||
|
@ -2341,7 +2341,6 @@ msgid "How to connect"
|
||||
msgstr "Cómo conectarse"
|
||||
|
||||
#: src/elements/forms/DeleteBulkForm.ts
|
||||
#: src/pages/stages/invitation/InvitationListPage.ts
|
||||
#: src/pages/users/RelatedUserList.ts
|
||||
#: src/pages/users/UserListPage.ts
|
||||
msgid "ID"
|
||||
@ -3041,6 +3040,8 @@ msgstr "Mis solicitudes"
|
||||
#: src/pages/stages/dummy/DummyStageForm.ts
|
||||
#: src/pages/stages/email/EmailStageForm.ts
|
||||
#: src/pages/stages/identification/IdentificationStageForm.ts
|
||||
#: src/pages/stages/invitation/InvitationForm.ts
|
||||
#: src/pages/stages/invitation/InvitationListPage.ts
|
||||
#: src/pages/stages/invitation/InvitationStageForm.ts
|
||||
#: src/pages/stages/password/PasswordStageForm.ts
|
||||
#: src/pages/stages/prompt/PromptStageForm.ts
|
||||
|
@ -2367,7 +2367,6 @@ msgid "How to connect"
|
||||
msgstr ""
|
||||
|
||||
#: src/elements/forms/DeleteBulkForm.ts
|
||||
#: src/pages/stages/invitation/InvitationListPage.ts
|
||||
#: src/pages/users/RelatedUserList.ts
|
||||
#: src/pages/users/UserListPage.ts
|
||||
msgid "ID"
|
||||
@ -3072,6 +3071,8 @@ msgstr "Mes applications"
|
||||
#: src/pages/stages/dummy/DummyStageForm.ts
|
||||
#: src/pages/stages/email/EmailStageForm.ts
|
||||
#: src/pages/stages/identification/IdentificationStageForm.ts
|
||||
#: src/pages/stages/invitation/InvitationForm.ts
|
||||
#: src/pages/stages/invitation/InvitationListPage.ts
|
||||
#: src/pages/stages/invitation/InvitationStageForm.ts
|
||||
#: src/pages/stages/password/PasswordStageForm.ts
|
||||
#: src/pages/stages/prompt/PromptStageForm.ts
|
||||
|
@ -2338,7 +2338,6 @@ msgid "How to connect"
|
||||
msgstr "Jak się połączyć"
|
||||
|
||||
#: src/elements/forms/DeleteBulkForm.ts
|
||||
#: src/pages/stages/invitation/InvitationListPage.ts
|
||||
#: src/pages/users/RelatedUserList.ts
|
||||
#: src/pages/users/UserListPage.ts
|
||||
msgid "ID"
|
||||
@ -3038,6 +3037,8 @@ msgstr "Moje aplikacje"
|
||||
#: src/pages/stages/dummy/DummyStageForm.ts
|
||||
#: src/pages/stages/email/EmailStageForm.ts
|
||||
#: src/pages/stages/identification/IdentificationStageForm.ts
|
||||
#: src/pages/stages/invitation/InvitationForm.ts
|
||||
#: src/pages/stages/invitation/InvitationListPage.ts
|
||||
#: src/pages/stages/invitation/InvitationStageForm.ts
|
||||
#: src/pages/stages/password/PasswordStageForm.ts
|
||||
#: src/pages/stages/prompt/PromptStageForm.ts
|
||||
|
@ -2375,7 +2375,6 @@ msgid "How to connect"
|
||||
msgstr ""
|
||||
|
||||
#: src/elements/forms/DeleteBulkForm.ts
|
||||
#: src/pages/stages/invitation/InvitationListPage.ts
|
||||
#: src/pages/users/RelatedUserList.ts
|
||||
#: src/pages/users/UserListPage.ts
|
||||
msgid "ID"
|
||||
@ -3083,6 +3082,8 @@ msgstr ""
|
||||
#: src/pages/stages/dummy/DummyStageForm.ts
|
||||
#: src/pages/stages/email/EmailStageForm.ts
|
||||
#: src/pages/stages/identification/IdentificationStageForm.ts
|
||||
#: src/pages/stages/invitation/InvitationForm.ts
|
||||
#: src/pages/stages/invitation/InvitationListPage.ts
|
||||
#: src/pages/stages/invitation/InvitationStageForm.ts
|
||||
#: src/pages/stages/password/PasswordStageForm.ts
|
||||
#: src/pages/stages/prompt/PromptStageForm.ts
|
||||
|
@ -2341,7 +2341,6 @@ msgid "How to connect"
|
||||
msgstr "Nasıl bağlanır"
|
||||
|
||||
#: src/elements/forms/DeleteBulkForm.ts
|
||||
#: src/pages/stages/invitation/InvitationListPage.ts
|
||||
#: src/pages/users/RelatedUserList.ts
|
||||
#: src/pages/users/UserListPage.ts
|
||||
msgid "ID"
|
||||
@ -3042,6 +3041,8 @@ msgstr "Uygulamalarım"
|
||||
#: src/pages/stages/dummy/DummyStageForm.ts
|
||||
#: src/pages/stages/email/EmailStageForm.ts
|
||||
#: src/pages/stages/identification/IdentificationStageForm.ts
|
||||
#: src/pages/stages/invitation/InvitationForm.ts
|
||||
#: src/pages/stages/invitation/InvitationListPage.ts
|
||||
#: src/pages/stages/invitation/InvitationStageForm.ts
|
||||
#: src/pages/stages/password/PasswordStageForm.ts
|
||||
#: src/pages/stages/prompt/PromptStageForm.ts
|
||||
|
@ -2338,7 +2338,6 @@ msgid "How to connect"
|
||||
msgstr "如何连接"
|
||||
|
||||
#: src/elements/forms/DeleteBulkForm.ts
|
||||
#: src/pages/stages/invitation/InvitationListPage.ts
|
||||
#: src/pages/users/RelatedUserList.ts
|
||||
#: src/pages/users/UserListPage.ts
|
||||
msgid "ID"
|
||||
@ -3037,6 +3036,8 @@ msgstr "我的应用"
|
||||
#: src/pages/stages/dummy/DummyStageForm.ts
|
||||
#: src/pages/stages/email/EmailStageForm.ts
|
||||
#: src/pages/stages/identification/IdentificationStageForm.ts
|
||||
#: src/pages/stages/invitation/InvitationForm.ts
|
||||
#: src/pages/stages/invitation/InvitationListPage.ts
|
||||
#: src/pages/stages/invitation/InvitationStageForm.ts
|
||||
#: src/pages/stages/password/PasswordStageForm.ts
|
||||
#: src/pages/stages/prompt/PromptStageForm.ts
|
||||
|
@ -2338,7 +2338,6 @@ msgid "How to connect"
|
||||
msgstr "如何连接"
|
||||
|
||||
#: src/elements/forms/DeleteBulkForm.ts
|
||||
#: src/pages/stages/invitation/InvitationListPage.ts
|
||||
#: src/pages/users/RelatedUserList.ts
|
||||
#: src/pages/users/UserListPage.ts
|
||||
msgid "ID"
|
||||
@ -3037,6 +3036,8 @@ msgstr "我的应用"
|
||||
#: src/pages/stages/dummy/DummyStageForm.ts
|
||||
#: src/pages/stages/email/EmailStageForm.ts
|
||||
#: src/pages/stages/identification/IdentificationStageForm.ts
|
||||
#: src/pages/stages/invitation/InvitationForm.ts
|
||||
#: src/pages/stages/invitation/InvitationListPage.ts
|
||||
#: src/pages/stages/invitation/InvitationStageForm.ts
|
||||
#: src/pages/stages/password/PasswordStageForm.ts
|
||||
#: src/pages/stages/prompt/PromptStageForm.ts
|
||||
|
@ -2338,7 +2338,6 @@ msgid "How to connect"
|
||||
msgstr "如何连接"
|
||||
|
||||
#: src/elements/forms/DeleteBulkForm.ts
|
||||
#: src/pages/stages/invitation/InvitationListPage.ts
|
||||
#: src/pages/users/RelatedUserList.ts
|
||||
#: src/pages/users/UserListPage.ts
|
||||
msgid "ID"
|
||||
@ -3037,6 +3036,8 @@ msgstr "我的应用"
|
||||
#: src/pages/stages/dummy/DummyStageForm.ts
|
||||
#: src/pages/stages/email/EmailStageForm.ts
|
||||
#: src/pages/stages/identification/IdentificationStageForm.ts
|
||||
#: src/pages/stages/invitation/InvitationForm.ts
|
||||
#: src/pages/stages/invitation/InvitationListPage.ts
|
||||
#: src/pages/stages/invitation/InvitationStageForm.ts
|
||||
#: src/pages/stages/password/PasswordStageForm.ts
|
||||
#: src/pages/stages/prompt/PromptStageForm.ts
|
||||
|
@ -44,6 +44,15 @@ export class InvitationForm extends ModelForm<Invitation, string> {
|
||||
|
||||
renderForm(): TemplateResult {
|
||||
return html`<form class="pf-c-form pf-m-horizontal">
|
||||
<ak-form-element-horizontal label=${t`Name`} ?required=${true} name="name">
|
||||
<input
|
||||
type="text"
|
||||
value="${this.instance?.name || ""}"
|
||||
class="pf-c-form-control"
|
||||
required
|
||||
data-ak-slug="true"
|
||||
/>
|
||||
</ak-form-element-horizontal>
|
||||
<ak-form-element-horizontal label=${t`Expires`} ?required=${true} name="expires">
|
||||
<input
|
||||
type="datetime-local"
|
||||
|
@ -65,7 +65,7 @@ export class InvitationListPage extends TablePage<Invitation> {
|
||||
|
||||
columns(): TableColumn[] {
|
||||
return [
|
||||
new TableColumn(t`ID`, "pk"),
|
||||
new TableColumn(t`Name`, "name"),
|
||||
new TableColumn(t`Created by`, "created_by"),
|
||||
new TableColumn(t`Expiry`),
|
||||
new TableColumn(t`Actions`),
|
||||
@ -96,7 +96,7 @@ export class InvitationListPage extends TablePage<Invitation> {
|
||||
|
||||
row(item: Invitation): TemplateResult[] {
|
||||
return [
|
||||
html`${item.pk}`,
|
||||
html`${item.name}`,
|
||||
html`${item.createdBy?.username}`,
|
||||
html`${item.expires?.toLocaleString() || t`-`}`,
|
||||
html` <ak-forms-modal>
|
||||
|
@ -2,7 +2,6 @@ import { t } from "@lingui/macro";
|
||||
|
||||
import { TemplateResult, html } from "lit";
|
||||
import { customElement } from "lit/decorators.js";
|
||||
import { ifDefined } from "lit/directives/if-defined.js";
|
||||
|
||||
import { InvitationStage, StagesApi } from "@goauthentik/api";
|
||||
|
||||
@ -49,7 +48,7 @@ export class InvitationStageForm extends ModelForm<InvitationStage, string> {
|
||||
<ak-form-element-horizontal label=${t`Name`} ?required=${true} name="name">
|
||||
<input
|
||||
type="text"
|
||||
value="${ifDefined(this.instance?.name || "")}"
|
||||
value="${this.instance?.name || ""}"
|
||||
class="pf-c-form-control"
|
||||
required
|
||||
/>
|
||||
|
Reference in New Issue
Block a user