Now that I'm using the new taxonomy_access module (CVS), I'm discovering some odd behavior in selecting permission catagories. If I "save category permissions" on an empty set of permissions (no checks in boxes and no adds or removes selected), a pattern of permissions (one that I did not select) gets automatically generated for any given role. Its the same terms that generate the same permissions for the rolse each time.

Also, the defaults don't seem to carry over to other vocabularies and roles... hmmm, am I missing something here? Thanks in advanced for your help!

Comments

pyromanfo’s picture

The default sets the permissions for that role for the categories in that vocabulary. So it's working as intented

Also if you have any of the dropdowns set to add or remove it's adding or removing that permission for the categories in that vocabulary for that role.

pyromanfo’s picture

Actually, how I described defalult is somewhat inaccurate. Default sets the permissions for that role for new categories in that vocabulary. It doesn't change any existing categories, only the dropdowns do that.

bomarmonk’s picture

Okay, but any idea why taxonomy access is generating unwanted permissions (checks in boxes). It's odd. Here's the example:

I have a role called "administration." I can "remove" all the checks in the boxes just fine. I can also add permissions by checking boxes, but with limitations. If I give the "administration" role permissions to "view," "update," "delete," and "create" for the category, "administration," taxonomy_access automatically generates the same permission for another term in the same vocabularly. It also fills-in the checkboxes for another, seemingly random term. The only way I can be rid of these auto-filled checkboxes is to not select the desired permissions. Argg! It's simply not doing what it's supposed to. I'm not sure if this is because of the module or because of some corruption in my database? Would erasing my roles and recreating them get rid of the problem? Or is this a bug in the CVS release of this module? Thanks again for looking into this.

Your explanation of the default box makes sense...

pyromanfo’s picture

Could you give me the contents of term_data, term_access and term_access_defaults?

I'll take a look at it, sounds like a bug.

bomarmonk’s picture

Pyro, can you give me an e-mail so I can send you .pdf files of my tables? I've printed the pdf's from phpMyAdmin so you can see what's going on with the database-- including node_access, term_access, and term_access_default.

I have cleaned out my node_access table, deleted the term_access tables, uninstalled the taxonomy_access module and started over. I still get the same result (even after simplifying my roles to one role per user-- I had multiple roles assigned to each user)-- still permissions are getting added when I don't select them. I reinstalled the old taxonomy_access (4.50-- non CVS) and everything seems to work fine, but without the added features...

I hope I can help you do some bug hunting!

pyromanfo’s picture

Can you just attach them here? Unless your term_data holds sensitive infomation (in the descriptions maybe?) there isn't anything but category names and a bunch of numbers in those tables.

bomarmonk’s picture

StatusFileSize
new176.21 KB

You are exactly right... here is the term_access table in .pdf format...

bomarmonk’s picture

StatusFileSize
new17.34 KB

The term_access_default table....

bomarmonk’s picture

StatusFileSize
new10.93 KB

The node_access table... that should do it, if I understand the tables involved in this module. Thank you for looking into this! I hope you solve the mystery.

pyromanfo’s picture

Thanks for the help, could I get term_data as well?

bomarmonk’s picture

StatusFileSize
new34.07 KB

Ah, yes, after looking through this table, I suspect the problems are somewhere in here: if some the numbers seem slightly misaligned, I changed some of the names to keep them generic, but I changed nothing else in the report of this table. I hope it helps

bomarmonk’s picture

Any luck? Is there still a way to access the version of Taxonomy Access with check-boxes at the top of each vocabularly? They worked in much the same way as the drop downs and there was the "create" field for catagory permissions. I think this version worked with my setup. I would go back to the 4.50 version, but it only has "update," "delete," "create," and "view." Just checking... thanks for your help. Once I can get it working right, this module will do wonders for the site I am building!

pyromanfo’s picture

I'm gonna look at it tonight.

Are you not seeing any create permissions now? I haven't changed how that works since I added them in the first place.

bomarmonk’s picture

I tried reverting back to 4.50 (the most recent version that download from the module page). I deleted and reinstalled the tax_access table, etc. The module does give me a "duplicate" error when I first enable it, but it seems to work fine after that... but "view," "update," and "delete" are the only options for my category permissions. There are also only checkboxes for individual terms in this version, not for the larger vocabularies.

Hope that helps explain my situation.

pyromanfo’s picture

Oh okay yeah that's just really old, I'll try to fix your problem tonight.

pyromanfo’s picture

I think I finally fixed it, try the latest CVS.

bomarmonk’s picture

Bingo...almost everything is behaving the way I would expect it to behave now. Good work! The only thing that behaves a bit differently is the default box. It seems that these boxes are filled in automatically for every vocabulary, no matter what I do. Perhaps this is by design, and I still don't fully understand the "default's" function yet.

pyromanfo’s picture

Do you mean it's setting all the permissions on for each default, regardless of what you check/uncheck?

It's not doing that on mine, though I don't think I've disabled and enabled it, when I do that, it should set 'view' and 'create' for any defaults you didn't already set.

The latest CVS has better docs, if you're still unclear.

Anonymous’s picture

i think the problem is $vids array with duplicate values. for a vocabulary, hidden form-item with 'name=vids[] value=x' is written twice, one top of vocabulary and the other top of defaults.

the solution is either using array_unique for $vids or not outputting the second hidden form-item with 'vids[]'.
both works for me.

pyromanfo’s picture

Didn't notice that, fixed in CVS. Thanks.

Anonymous’s picture