diff options
author | Cefin <kevon@tuta.io> | 2021-12-06 14:50:37 +0000 |
---|---|---|
committer | Étienne Loks <etienne.loks@iggdrasil.net> | 2022-07-08 09:58:49 +0200 |
commit | 7aba565adaed0e58f7098d03860c5441ee9bd973 (patch) | |
tree | a9213751a9788192d2cddec256907f8dfbd4c100 /ishtar_common | |
parent | 4e6bde42b0b0643dfadd354bfa31cf4f59d4b5ae (diff) | |
download | Ishtar-7aba565adaed0e58f7098d03860c5441ee9bd973.tar.bz2 Ishtar-7aba565adaed0e58f7098d03860c5441ee9bd973.zip |
rapid action on person record add account #5216 part four
Diffstat (limited to 'ishtar_common')
-rw-r--r-- | ishtar_common/models.py | 2 | ||||
-rw-r--r-- | ishtar_common/urls.py | 5 | ||||
-rw-r--r-- | ishtar_common/views.py | 14 |
3 files changed, 3 insertions, 18 deletions
diff --git a/ishtar_common/models.py b/ishtar_common/models.py index af7908b53..74d81281d 100644 --- a/ishtar_common/models.py +++ b/ishtar_common/models.py @@ -2919,7 +2919,7 @@ class Person(Address, Merge, OwnPerms, ValueGetter, MainItem): return actions actions += [ ( - reverse("account_creation", args=[self.pk]), + reverse("account_management", args=[self.pk]), _("Create new account"), "fa fa-user", "", diff --git a/ishtar_common/urls.py b/ishtar_common/urls.py index 7490788c7..9e120a945 100644 --- a/ishtar_common/urls.py +++ b/ishtar_common/urls.py @@ -202,11 +202,6 @@ urlpatterns = [ name="account_deletion", ), url( - r"account_creation/(?P<step>.+)?$", - check_rights(["add_ishtaruser"])(views.account_creation_wizard), - name="account_creation", - ), - url( r"^import-new/$", check_rights(["change_import"])(views.NewImportView.as_view()), name="new_import", diff --git a/ishtar_common/views.py b/ishtar_common/views.py index ee7fc1ee7..9b7e8d5e2 100644 --- a/ishtar_common/views.py +++ b/ishtar_common/views.py @@ -307,16 +307,6 @@ account_management_wizard = wizards.AccountWizard.as_view( url_name="account_management", ) -account_creation_wizard = wizards.AccountWizard.as_view( - [ - ("account-account_management", forms.AccountForm), - ("profile-account_management", forms.ProfileFormset), - ("final-account_management", forms.FinalAccountForm), - ], - label=_("Account creation"), - url_name="account_creation", -) - account_deletion_wizard = wizards.IshtarUserDeletionWizard.as_view( [ ("selec-account_deletion", forms.AccountFormSelection), @@ -327,13 +317,13 @@ account_deletion_wizard = wizards.IshtarUserDeletionWizard.as_view( ) def account_create(request, pk): - if not wizard_is_available(account_creation_wizard, request, models.IshtarUser): + if not wizard_is_available(account_management_wizard, request, models.IshtarUser): return HttpResponseRedirect("/") wizards.AccountWizard.session_set_value( request, "selec-account_management", "pk", pk, reset=True ) return redirect( - reverse("account_creation", kwargs={"step": "account-account_management"}) + reverse("account_management", kwargs={"step": "account-account_management"}) ) |