Opened 9 years ago

Last modified 6 months ago

#5899 assigned New feature

Allow admin fieldsets to be collapsible but not initially collapsed

Reported by: Ionut Ciocirlan <ionut.ciocirlan@…> Owned by: Alexander Herrmann
Component: contrib.admin Version: newforms-admin
Severity: Normal Keywords: admin fieldset collapsed collapsible nfa-someday
Cc: cmawebsite@…, olivier.dalang@… Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: yes Patch needs improvement: no
Easy pickings: no UI/UX: yes

Description

I want to use the collapse feature of the admin, but not have the field initially collapsed, so I made this little patch.

It adds a "collapsible" class that does just that. It also patches the documentation.

Attachments (4)

django.collapsible_fieldset.diff (5.2 KB) - added by Ionut Ciocirlan <ionut.ciocirlan@…> 9 years ago.
django_newforms-admin.collapsible_fieldset.diff (5.2 KB) - added by Ionut Ciocirlan <ionut.ciocirlan@…> 9 years ago.
5899.diff (8.7 KB) - added by Alexander Herrmann 6 years ago.
5899.collapsible-fieldsets.diff (8.6 KB) - added by Julien Phalip 5 years ago.

Download all attachments as: .zip

Change History (16)

Changed 9 years ago by Ionut Ciocirlan <ionut.ciocirlan@…>

comment:1 Changed 9 years ago by Brian Rosner

Patch needs improvement: set
Triage Stage: UnreviewedAccepted
Version: SVNnewforms-admin

I am +1 on this. However, the trunk admin is longer being supported. Ionut, can you provide a patch against the newforms-admin branch?

Changed 9 years ago by Ionut Ciocirlan <ionut.ciocirlan@…>

comment:2 Changed 9 years ago by Ionut Ciocirlan <ionut.ciocirlan@…>

Patch needs improvement: unset

Done, attached new patch.

comment:3 Changed 9 years ago by Karen Tracey <kmtracey@…>

Keywords: nfa-someday added

New function, should not block merge.

comment:4 Changed 6 years ago by Gabriel Hurley

Severity: Normal
Type: New feature

comment:5 Changed 6 years ago by patchhammer

Easy pickings: unset
Patch needs improvement: set

django_newforms-admin.collapsible_fieldset.diff fails to apply cleanly on to trunk

comment:6 Changed 6 years ago by Julien Phalip

UI/UX: set

comment:7 Changed 6 years ago by Alexander Herrmann

Owner: changed from nobody to Alexander Herrmann
Status: newassigned

Changed 6 years ago by Alexander Herrmann

Attachment: 5899.diff added

comment:8 Changed 6 years ago by Alexander Herrmann

Patch needs improvement: unset

I implemented the suggested behaviour to the current trunk, see 5899.diff.

Changed 5 years ago by Julien Phalip

comment:9 Changed 5 years ago by Julien Phalip

The patch looks great, I've just updated it to current trunk. I'd be tempted to RFC this patch even if it doesn't contain tests. There are no plans on implementing a framework for testing the admin *interface* (as opposed to regular javascript code) clearly spelled out yet, even in #16193.

comment:10 Changed 4 years ago by Jannis Leidel

Needs tests: set

Now that we have selenium based interface testing this patch could be expanded with that.

comment:11 Changed 23 months ago by Collin Anderson

Cc: cmawebsite@… added

Why not simply have all fieldsets collapsable by default and only have them initially collapsed when the "collapse" class is present?

comment:12 Changed 6 months ago by Olivier

Cc: olivier.dalang@… added
Note: See TracTickets for help on using tickets.
Back to Top