google-code-export / django-grappelli

Automatically exported from code.google.com/p/django-grappelli
0 stars 0 forks source link

collapse - more than one ManyToMany Field with extra fields #11

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Create a model with more than one ManyToMany Field with extra fields
2. Generate automatic admin
3. Try to edit the differents inlines fields, but i can just open the first
one.

What is the expected output? What do you see instead?

I can't 'open' the collapsed field

What version of the product are you using? On what operating system?

I use the last svn version

Please provide any additional information below.

Original issue reported on code.google.com by samuel.goldszmidt on 1 Dec 2008 at 11:44

GoogleCodeExporter commented 9 years ago
There are indeed bugs related to this when you have multiple fields, due some
problems with jquery selectors in CollapsedInlineFieldsets.js.   The problems 
include
 not being able to open some fieldsets at all, and fieldsets with errors not being
open by default.

I attach a patch that addresses the issues I found.

Original comment by jsmull...@gmail.com on 6 Jan 2009 at 8:41

Attachments:

GoogleCodeExporter commented 9 years ago
This patch resolves my issues as well. I would love to see it committed to the 
SVN
repository.

Original comment by codysoyl...@gmail.com on 8 Mar 2009 at 8:22

GoogleCodeExporter commented 9 years ago
the patch doesn´t work for me: inlines with errors are closed ... I´m trying 
to take
a closer look at the scripts.

Original comment by sehmaschine on 12 Mar 2009 at 2:51

GoogleCodeExporter commented 9 years ago
I think that the end()-function doesn´t work as expected. as mentioned before, 
all
inlines are closed (even when there are errors inside).

Original comment by sehmaschine on 12 Mar 2009 at 3:56

GoogleCodeExporter commented 9 years ago
back to the original subject:

testcase 1: tabularinline as well as stacked inline with m2m-fields works fine 
for
me. what we changed: extra-fields are vertically aligned to top now ... 

testcase 2: m2m-fields with filter_horizontal. works fine with stackedinline &
tabularinline. made soome smaller changes to the look of the filter.

so, based on my testcases I can´t reproduce the original error. maybe some more
details on this one?

one think I noticed: there´s a js-error in selectfilter2.js. don´t know why 
but on
init, the from_box is not found.

Original comment by sehmaschine on 13 Mar 2009 at 12:18

GoogleCodeExporter commented 9 years ago
The error would show up for me on the second of three inlines.

I see you are starting a big refactor and adding new features, which is great.  
Trunk
seems a bit broken at the moment, so I'm going to back off for a few days until
things settle down again.

One thing might possibly help -- if in your new css/html you were to add some 
ids
(with a naming scheme) where possible just to help in coming up with good stable
selectors for the jquery hooks, to avoid stuff like
.parent().parent().parent().parent(), which is a bit hard to get one's head 
around.

Original comment by jsmull...@gmail.com on 13 Mar 2009 at 3:34

GoogleCodeExporter commented 9 years ago
trunk is working fine for me (at the moment) when it comes to editing/reorder
inlines. the features I´m adding are not relevant for inline-stuff ... I just 
added a
model for the sidebar navigation which includes an m2m-relation and it works ok 
(for me).

that´s really strange and I´d love to reconstruct that error!!!

Original comment by sehmaschine on 15 Mar 2009 at 3:41

GoogleCodeExporter commented 9 years ago

Original comment by sehmaschine on 27 Mar 2009 at 11:18

GoogleCodeExporter commented 9 years ago
please try it with the current trunk. if the problem still exists, please 
reopen this
ticket or write a new one ...

thanks.

Original comment by sehmaschine on 9 Apr 2009 at 12:54