Allow each group to administer their own book.
I know this existed sometime in the past but I don't think it ever made it out fully into the wild.

For the administrator, the outline structure might look something like

Top Level
- Organic Groups
-- Group 1
--- A book from Group 1
--- Another book from Group 1
-- Group 2
- Public book 1 (added by admin / user with sufficient privledges)
- Public book 2
-- Sub item of Public book 2

An end user would only see the groups they are subscribed too and the public books
- MY Groups
-- Group 1
--- A book from Group 1
--- Another book from Group 1
-- Group 2
- Public book 1 (added by admin / user with sufficient privledges)
- Public book 2
-- Sub item of Public book 2

The idea being that normal users can post to items inside their

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

nikle’s picture

"The idea being that normal users can post to items inside their..."

The idea being that normal users can post to items inside their group or in public books, but like other OG modules are prevented from viewing, editing or adding items in groups they are not members of.

dan_aka_jack’s picture

Version: 5.x-1.0 » master

I too would love to see a feature whereby members of organic groups could start a book which "contained" within the group.

dugh’s picture

To generalize this request, I would like to be able to associate and auto-create other content types when new groups are created, for example, to automatically create a chat room for each group. Couldn't do this properly with workflow-ng.

Grayside’s picture

This issues doesn't describe auto-creation of content. This is effectively a UI issue for Group-associated books. I've looked into such a thing briefly, and the closest I've found is the node_factory module.

I'd like to see the Book Outline:Book selector in the node/book/add and node/*/edit pages be limited to the current group as well. That selector gets unwieldy quickly when you allow individual groups to create their own books.

mailme.eva’s picture

i am just playing around with book expand.
maybe this is interesting for you?
http://drupal.org/project/bookexpand

irtech’s picture

@grayside:

Drupal 6 deals with books much better so the ridiculously long parent selector can be limited to current book. Combined with the OG User Roles module I found the functionality I need. People add book pages only within a particular book (one book per group), which simplifies parent selection, and group association is automatic through context.

Grayside’s picture

@mailme.eva:
Thanks for the tip, but Bookexpand looks like it will take a lot of work to get it brushed up for D6.

@alevy:
While that is a solution, it's not particularly optimal. It makes more sense in my situation to have multiple books per group. What's more, I would like my users to be able to go to the group home page, click on Create Book page in the Group details block, and be ready to go for Group-limited content creation.

tonyliuh’s picture

I need the book module with OG module deadly. My goal is that OG admin create a new book and OG members add content to this book. When a new user registers, s/he can choose which group s/he can join. If no group for her/him to choose, s/he can apply for creating a new group and being this new group admin.

irtech’s picture

FileSize
881 bytes

Here is my first attempt at a drupal module: ogbookblock

It is for drupal 6 and depends on the JqueryMenu module (for ajaxy book navigation).

I've only tested it for a few minutes on a very simple site with almost no content. It doesn't make any changes to the database so I wouldn't be too worried about testing it (please let me know what you think).

Basically it will display a book navigation block in the following case:
- user is viewing a page associated with a group (group context)
- user is a member of the group (block will not show if non-member)
- the book itself is part of that group (this was only tested for single group 'membership' - multiple groups & multiple books comes later).

I setup two test groups each with a single book associated with them. It switched between them nicely based on context.

If you have a chance, test it out and let me know what you think.

irtech’s picture

FileSize
900 bytes

I've made a small update so it now supports multiple books per group.

I didn't make this clear in the post above, but to turn this on you just need to go to block configuration and turn on ogbookblock.

moshe weitzman’s picture

Status: Active » Closed (won't fix)

You may feel free to discuss it here, but this should be a contrib module, and not in OG proper.

Taz’s picture

I think creating an OG Book module for this is needed. Books in private groups (or the greater issue of non-joined groups) currently show up in the 'Outline' (hierarchy) selector. This select box can be altered to not include non-joined groups fairly easily.

Anyone interested in further discussion? A "Yes this is what I need!" is what i'm looking for and i'll write the module up as contribution, otherwise i'll let it fall away and just have custom code for my site.

The block posted above could also be included, without the requirement for the jquery module. I don't have a need for this *yet* so won't do it *yet*.

marcp’s picture

You may want to look at Book Manager, which provides personal books, to see if there's any code you can leverage there.

Grayside’s picture

Somehow this issue fell of my list. I've spent a few hours walking through the Book Manager and piecing together an OG Book integration module. It looks to me like the adaption works, and if anything will produce a simpler module. However, I am new to Drupal development, so you never know. I promise to get the Coder module installed soon.

Based on how callbacks are overridden in the Book Manager (and thus my little project), I don't see these being compatible with each other.

When I get a little farther, I'll go about getting CVS access for a project.

Taz’s picture

Status: Closed (won't fix) » Needs review
FileSize
156 bytes
1.02 KB

Here's what I came up with for filtering out books, it needs one more alter for the selector on the Outline tab .
It's only roughly put together and needs more around it for the project it's included in.

Test it out as non-admin user...

Grayside’s picture

You might also want to implement new permissions, such as "add page to group books". I think keeping the global permission and the group-limited permission separate is a good thing.

I'll do some testing with your code on Monday. Since you have something closer to working than myself, I'll put my efforts behind your project.

Taz’s picture

Project: Organic groups » OG Book
Version: master »
Component: og.module » Code

Moving to a newly created OG Book

Grayside,
what I have done on my system for group-editable books is use the Group User Roles, Flag module and Content Access.
This flag 'Make a wiki' actually works for all group content.
When you flag, it just sets the nodes (and for a book would set child nodes maybe) permissions with added EDIT for this role.
I can provide the flag action code for this easily enough, as well as the hook_links() code, but in my system it is not book specific but any content type in a group.

A bonus is that you don't have to set the entire content type a wiki using the OG settings.

Chompas’s picture

alevy: I'm using your ogbookblock.tgz and for now (I haven't tested a lot) but it works great. It shows the books that are associated with a group when you are navigating on it. Its just what I need! Any recommendation?

nelsonlee’s picture

It is a good news to hear that og_book module is under requested. I wish to have it today!

og_book module can help the users to organize their content in a better way, so that everyone get benefit. Remember to include an editable/rearrangable TOC (Table of Content), to link to the nodes. Together with og_taxonomy, users can create their books online.

irtech’s picture

@chompas: I'm glad it works for you. I've actually updated it a bit since then (added support for multiple books per group and another block for viewing all books associated with current user's groups). Didn't see much interest so I didn't update - but if there is interest I'll clean it up and upload.

Grayside’s picture

Definitely upload it! I've been trapped in what amounts to a one-man documentation sprint for the last couple weeks or I'd be sitting on your head.

Taz’s picture

Update:

Will post a module within the week, basically the functionality to begin with when the module is turned on is:

Better integration with book manager (Required)
Personal books is a great idea and when OG is installed personal books should be the default setting in my opinion.
Will put 'book structure' tab on EVERY book page if you can edit it, regardless if personal book or not. The drag-and-drop is too useful not to put everywhere.

Restricts books
Restricts books to your personal books, global books or books in your OGs and remove all others.

dergachev’s picture

subscribing

Chompas’s picture

@alevy, I have a problem. When I enter in a group as a non registered user (all my groups are public) the block doesn't appear.

Is there a way to manage this? I would like very much if you put your updates to download. I need it right away.

Edit: I managed to fix this, commenting a line in your code. My main problem now is that when you create a book or page inside a group, the Book Outline options, list all books so, considering that you have a lot of books in the groups with the same name, you can't even identify them.

spearhead93’s picture

Hi Taz,

Any help needed for this module? I have the same requirement so instead of starting from scratch, I'd be happy to join forces for this one.

Spearhead

Taz’s picture

Version: » 6.x-1.x-dev

I have made an initial commit, very basic in what it does.

It still needs...
permission created - (eg: can see all books)
outline tab needs filtering

spearhead93, any help is more than welcome. Anything you come up with i'll gladly combine, or if you want CVS access we can discuss off-thread.

Taz’s picture

I have an idea to replace the blocks (or add also) code with a view. There is a feature request for the OG module to make the Tools block use a hook. In human, this would mean other modules could add links to this block - perfect place to put a 'Books in this group' link.

Then it would be a simple matter of enabling a view provided by this module.

Taz’s picture

alevy,

if you'd like to pass on your new block I can add it officially in to the module.

itsnotme’s picture

I officially love you, folks! My colleague just chimed in today with "books are so great for sorting contents" but my whole project is made with organic groups! I'll download the dev module and check it out.

irtech’s picture

FileSize
1.07 KB

@taz: Here is my updated module... take whatever you like out of it. I haven't worked on it in a while, but it was working last time I tested it :)

Layne’s picture

subscribe

neil.sonaron’s picture

Hi,
I have installed the 'og_book' module on my test site. I have created some groups and also created a book for one group.

Is there a way to restrict only members of one group could write on the group's book?

Thanks in advice.

irtech’s picture

@chompas - what would you suggest as a fix for multiple books with the same name? It would be fairly simple to append the group name next to the top level page or something like that. But I'm not sure this would meet your needs.

irtech’s picture

@neil: OG Access (part of the OG module) might do what you need.

neil.sonaron’s picture

I tried but not a valid solution.
I think I need the same behaviour like og_forum but with ob_book :)

Any tips, help and ideas will be appreciate.

PS: I'm very new with drupal, and too much to develop a module by my hand, but if I can serve testing any module count with me.

Taz’s picture

OG Access is a step in the right direction there, I achieved this using some custom written flag actions.

I suppose this module could expose an action or trigger to be used globally, that way the flag module or... well any module could use it.

neil.david’s picture

Subscribing

BetaTheta’s picture

subscribing

ajayg’s picture

Any update on this further?

sam6’s picture

subscribing

cpotter’s picture

subscribe