Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I'm using the latest version of this great module.
Unfortunately I'm not able to solve a simple issue:
- I created to fieldgroups with some CCK fields.
- I set the type of the fieldgroups to "vertical tabs"
- I moved the fieldgroups to the top of the cck group settings
Although, the "Authoring information" and the "Publishing options" are on the first position. How can I change this? I would like to have "Addressdetails" on the first position.
Comment | File | Size | Author |
---|---|---|---|
#6 | test1.jpg | 23.54 KB | ayalon |
#6 | test2.jpg | 16.6 KB | ayalon |
#3 | 692822-cck-node-fieldsets-D6.patch | 1.24 KB | Dave Reid |
vertical-tabs.jpg | 37.99 KB | ayalon | |
cck_settings.jpg | 90.63 KB | ayalon |
Comments
Comment #1
Dave ReidYou'd need something to expose the 'Authoring Information' and 'Publishing Options' fieldsets to CCK. Otherwise they're always going to be stuck first and you can't put anything 'above' them in vertical tabs since they'll always have the lowest weight.
Comment #2
ayalon CreditAttribution: ayalon commentedAnd how can I do that? These fieldsets are in the node.pages.inc of the core so I cannot modify these fieldsets.
Comment #3
Dave ReidMoving this to the CCK issue queue...
I apologize if this is by design, but I tried searching for a duplicate issue and couldn't find one. Is there a reason that the 'Authoring information' and 'Publishing options' fieldsets are not added on behalf of node.module in content_content_extra_fields()? It seems really odd to provide the Revision fieldset, but not the others.
Comment #4
Dave ReidTested this patch and it allowed me to put fieldsets above all the node.module fieldsets.
Comment #5
ayalon CreditAttribution: ayalon commentedThanks! I'll test the patch! Are you always as lightning fast? :-)
Comment #6
ayalon CreditAttribution: ayalon commentedI'm speechless! You are a real drupal expert / specialist / crack what ever! Thanks alot!
The patch works perfect on the first try.
I'm really astonished, that no one complained about this!
Can this be included in the next dev version?
Comment #7
t.lan CreditAttribution: t.lan commentedSubscribing - Will this patch make it into the nxt version?
Comment #8
DamienMcKenna+1 for inclusion in the next release.
Comment #9
moritzz CreditAttribution: moritzz commentedLooks good.
+1 for inclusion in the next release.
Comment #10
KarenS CreditAttribution: KarenS commentedI actually put this in a long long time ago and it got taken out because it has no effect on normal node forms. It does however do something if you use vertical tabs. I went ahead and added this back in. Hopefully I won't get too much grief for introducing this change so late in the cycle. The weights are high enough that the new fields should stay at the bottom unless you deliberately move them, which I hope means nothing unexpected will happen to existing forms.
Comment #11
yched CreditAttribution: yched commentedIt's a bit far now, but it kinds of rings a vague bell. If having those items reorderable has no effect without VT, then would it make sense to let VT module take care of exposing them as reorderable ?
Comment #12
Dave ReidAre we sure that this doesn't have any affect without VT? Doesn't it set the #weight properties also? Even if you're not using VT, this would still allow the fieldsets themselves to be re-ordered.
The reason I pushed for this here is because there are x other modules that could do whiz-bang stuff with node edit forms. Vertical tabs is only one of them. Do we want to duplicate code, or put the support at the root? Plus it's really odd that we'd leave out author and option fieldsets and only support the revision fieldset. Why not all of them?
Comment #13
KarenS CreditAttribution: KarenS commentedWhat I mean to say is that the core code ignores the weights for some reason so they have no effect (it's been a long time, I forget exactly what was going one). So, there may be other modules that do things with them and custom code could also.
It does seem like this is the right place for this code, since CCK is doing the same thing for other core fields. It's just really late in the cycle to be doing this. And Drupal 7 is different, I forget what is being done there, you'd have to see if you need something done in core in D7.
This is one of those issues I could have done a won't fix on, but it seemed so logical to have it in that I went ahead. I can pull it back out if yched thinks this is a bad idea.
Comment #15
cousin_itt CreditAttribution: cousin_itt commentedAuthoring information and Publishing options would not obey CCK reordering until I overrode theme_node_form() in node.pages.inc in my therme (MYTHEME_node_form() in template.php)
I just had to remove the code where the $admin content was built.