Skip to content

Configuring apphooks from different applications with the same application_namespace (i.e. 'default') are rejected by the admin form with 'An application instance with this name already exists.' #6479

Open
@macolo

Description

@macolo

Summary

image

Expected behaviour

  • The editor should be able to add the AppHook configuration for app A with name 'default' to a page and then add an AppHook configuration for app B with name 'default' to another page.

Actual behaviour

  • djangocms admin form returns 'An application instance with this name already exists.'
  • the editor expects this to work

Environment

  • Python version: any
  • Django version: any
  • django CMS version: 3.5.2

Proposed solution

  • in _check_unique_namespace_instance include application_urls in filter:
 return Page.objects.drafts().on_site(self._site).filter(
            application_namespace=namespace,
            application_urls=application_urls,
        ).exclude(pk=self.instance.pk).exists()

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions