Closed (fixed)
Project:
Content Construction Kit (CCK)
Version:
6.x-1.x-dev
Component:
General
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
28 Aug 2006 at 11:29 UTC
Updated:
11 Nov 2006 at 11:02 UTC
Jump to comment: Most recent file
Comments
Comment #1
mh86 commentedI wrote a patch, which would fix the described problem above. I added the weight attribute to the $form[$field['field_name']] array to the cck field types.
Comment #2
mh86 commentedhere the patch for 4.7.
Comment #3
fagoworks fine.
the patch is important to have the weights correctly working with the fieldgroup module.
so let's use the form api weights for what they exist.. further this patch would be needed for any sorted hook_form_alter extensions.
so +1 for this
Comment #4
whereisian commentedbig +1 - patch seems to work correctly. solved my issue with fieldgroups also.
cheers!
Comment #5
karens commentedWouldn't it make more sense for content.module to do this? Content.module controls the widget that sets the weight, so it should also manage the setting of the weight in the form. That also eliminates the need for redundant code in all the field modules.
I have no time to create a patch right now, unfortunately.
Comment #6
eliza411 commentedWhen I installed the fieldgroup module, I thought that the input form and default output would honor those groups and weights. I also thought the "manage fields" tab would, too, although that's less problematic since the users never see it.
Instead, the default output and the "manage fields" seem to honor only the weight.
I tried installing the patch here, but I don't see any change in the behavior . . . was the patch supposed to make it so that the default output order would be sorted by groups then weights within the groups or was that wishful thinking.
Comment #7
fagothe fieldgroup module does nothing regarding output, it's about forms only. but that's another topic and has nothing to do with this issue.
Comment #8
RobRoy commentedAny progress on a non-redundant patch for content.module? This patch works, but I agree that this code is better suited in a central location. I'm pretty weak on CCK atm, but may try next week if no one else gets to this.
Comment #9
karens commentedIn the process of creating the 5.0 port I found a very simple non-redundant way to get the content module to insert the field weight in the form array (see http://drupal.org/node/91030) so I am committing this change to the 4.7 version. This means no changes to the individual field modules will be required.
Comment #10
(not verified) commented