Closed (fixed)
Project:
Book access
Version:
7.x-2.x-dev
Component:
Code
Priority:
Critical
Category:
Bug report
Assigned:
Reporter:
Created:
20 Dec 2012 at 11:33 UTC
Updated:
21 Jan 2013 at 17:30 UTC
Jump to comment: Most recent file
Hi,
it seems there is a little bug persistent I mentioned earlier. Now I can give default permissions and the most of them are granted correctly to the concrete book. But if I look inside the access permissions of a particular book (not the defaults) the author's permission are not granted correctly (the fields are empty). I'm not sure but it may be a serious problem for the owner (author) of a book if the rights management is very restrictive. In one case I had to grant the rights manually before I got my access back.
Kind regards!
| Comment | File | Size | Author |
|---|---|---|---|
| #13 | book_access-default_author_access_not_granted-1871124-0.patch | 6.51 KB | thelee |
Comments
Comment #1
Zippy commentedHi,
the problem seems to be even more serious!
When I create a new book everyone can view/edit it! (created the book as admin) I only get the correct rights management if
I enable the missing grants for the authorI select/deselect one arbitrary access permission for the particular book (access control per book). It seems there is a job, that should run automatically but has to be started manually....Comment #2
thelee commentedComment #3
thelee commentedI think I have an idea what the problem may be judging from your description. I'll take a look.
Comment #4
thelee commentedActually, no, I can't recreate this. Can you tell me what your default permissions are (for author especially)?
I also have a (critical) bug fix coming out today. In it, there's a way to reset permissions to the defaults (which also fixes problems with bad permissions being saved in previous versions). It would be helpful if you could use the new version (-beta2), make sure your defaults are correct, reset everything to defaults, and see if the problem still occurs.
Comment #5
Zippy commentedBy default the author gets all permissions available. But, as I mentioned, these permissions don't show up in the access table for the concrete book.
Comment #6
thelee commentedAlright I see now. I'm going to split comment #1 off into a separate bug, because I can't recreate #1 and I think it might be separate.
Comment #7
thelee commentedOK Sven, I can recreate your bug and I think I have a vague idea about it. No promises, but I'll try to get it fixed today since it is pretty critical.
Comment #8
Zippy commentedThank you very much! I really appreciate your hard work!
Comment #9
thelee commentedSo more specifically - this looks like this is a problem when you retroactively "upgrade" a page into a book. IE
versus
If you have any time, can you verify that this is what's happening? If this is the case I think it's just a missing hook call that should be easy to fix.
Comment #10
Zippy commentedI will test what you've mentioned but here is what I do to run into trouble...
I create a completely new book (node/add/book) and save it. That's it. The book shows up without any permissons defined for the author.
Comment #11
Zippy commentedSorry I cannot test this:
Create a book page
Forget to add it to a book
Go back, add it to book
Book Access shows no permissions for author
I have mandatory fields (node references) that can't get any value without a book parent. I need to get a completely new drupal installation to test this. It will take some time...
Here two of the modules I have installed that maybe cause the problems - but I don't know...
http://drupal.org/project/book_made_simple
http://drupal.org/project/nodeaccess_nodereference
Comment #12
thelee commentedAlright, how's about this - I'm going to push a patch that is related to what you're talking about (and gets me 0 author permissions when I create a node).
Upgrade to -beta3 when it comes out (not -beta2, doesn't have the patch I'm talking about right now). Save your book_access defaults, reset permissions to defaults (new option on that page), rebuild permissions (you'll automatically be prompted to after you reset permissions to defaults), then see if it works. I suspect you have previously bad data from earlier bugs in book_access that is causing part of the problem here (which -beta2 fixes).
Comment #13
thelee commentedFor reference, this is the patch i'm going to be using for -beta3
Comment #14
thelee commentedComment #15
Zippy commentedI can confirm that behaviour!
Comment #16
Zippy commentedCan confirm this (new installation):
Comment #17
thelee commentedGreat! This patch will definitely fix this for you.
And crap - unfortunately my home computer is being repaired and my work computer blocks the port I need to push this patch into drupal.org. So, even though I'm literally staring at the bug fix, I can't push it out for a couple days at least.
Comment #18
thelee commentedIf you're handy with command line tools or with version control, you can apply that patch yourself without worrying about incompatibilities (since it's literally the same code I'll be using).
Comment #19
Zippy commentedOkay,
the module book_made_simple causes the error.
This module enables you to define content types that automatically create a book outline. It also enables you to define different content types that can be part of a book.
If I create a book using book_made_simple the author doesn't get the permissions and (probably) the outline is visible for all users until I change some permissions with book access....
Comment #20
Zippy commentedYes, I am able to apply the patch.
I will test it...
Thanks a lot!
Comment #21
Zippy commentedI've tested the patch but no change. The problem is definitely caused by books made simple.
Comment #22
Zippy commentedI've started a bug report for book made simpe
Comment #23
thelee commentedThis patch has finally been committed, I'll be monitoring the other issue.
Comment #24
thelee commentedI applied and pushed a patch to fix the interaciton problem with book_made_simple on my side os you do n't have to manually update the system table. it's in the development snapshot, it'll be a while before it hits release (i want to group some other bug fixes with it).
Comment #25.0
(not verified) commentedcorrection