Posted by Liliplanet on November 2, 2010 at 9:21am
6 followers
| Project: | Homebox |
| Version: | 7.x-2.x-dev |
| Component: | Code |
| Category: | feature request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | needs work |
Issue Summary
Hi,
Thank you for this wonderful module! I've run into a small snag. I have 2 types of nodes that are groups and would only like the 1 type (groups) to override the home page, but in the case of type 2 (projects) only to show as a tab.
Is that by chance possible please?
Looking forward to any reply.
Lilian
Comments
#1
Bumping version since 6.x-2.x is no longer being developed.
#2
This is exactly the feature I need, as well, and is the only thing preventing us from using Homebox for our Drupal-based distance learning environment. A Drupal 7-compatible version of this feature would be preferred!
#3
Attached is a patch (against 7.x-2.0-beta6) that I think will add what you are looking for (It also includes a patch to the .install file that forces homebox_og to have a weight *after* page_manager, since if it doesn't, it can be overridden).
I am using this code and so far it works just fine. If you don't ever set any custom homeboxes for the Content Types, it just defaults to the "default" action; if you do, it can either override them or *prevent* override.
Let me know if you have any questions. The mod only took me about 2 hrs to write/test.
Andrew.
#4
Awesome - thanks Andrew! My only comment is that the selections for each group type seem to only be respected if the Override group homepages (Action to take when Default selected below) option is set to something besides "- None -". I think the group type-specific options should always be respected—whether or not you want a default homebox for groups in general.
#5
paul2:
You are correct. I only fixed the alter code, but did not add new code to *ensure* the _menu_alter() hook is called.
Attached patch fixes that.
Thanks for catching this bug.
#6
is this working ?
any reviews please?
#7
@adf1969
I got this error on og group configuration page:
Warning: Invalid argument supplied for foreach() in homebox_og_group_settings_page() (line 146 of E:\wamp\www\sites\all\modules\homebox\homebox_og\homebox_og.module).