You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Feature] Add possibility to add additional custom obects from Typed-tab #9
Behavior: each Typed tab gets an "Add Type" button (top-right). Clicking it opens the native customobject_add view with the back-reference field pre-populated to the parent object's PK and return_url set to the tab path, so saving lands you back on the tab with filters preserved.
Multi-field case: if a Custom Object Type has more than one field referencing the same parent model (e.g. primary_device + backup_device → Device), the button becomes a split-dropdown listing each field.
Permissions: hidden for users lacking add_customobject.
Note on empty tabs: typed tabs still use hide_if_empty=True — the tab is only visible once at least one object references the parent, so the first instance still needs to be created via the native Custom Objects menu. Subsequent additions use the new button. Open to switching to "always visible when user can add" if that's preferred.
Activity
Kani999 commentedon Apr 22, 2026
Proposed in #10.
Behavior: each Typed tab gets an "Add Type" button (top-right). Clicking it opens the native
customobject_addview with the back-reference field pre-populated to the parent object's PK andreturn_urlset to the tab path, so saving lands you back on the tab with filters preserved.Multi-field case: if a Custom Object Type has more than one field referencing the same parent model (e.g.
primary_device+backup_device→ Device), the button becomes a split-dropdown listing each field.Permissions: hidden for users lacking
add_customobject.Note on empty tabs: typed tabs still use
hide_if_empty=True— the tab is only visible once at least one object references the parent, so the first instance still needs to be created via the native Custom Objects menu. Subsequent additions use the new button. Open to switching to "always visible when user can add" if that's preferred.Add Add-button on Typed tabs with reverse-reference prefill (closes #9)
Merge pull request #10 from CESNET/feature/typed-tab-add-button