Closed (fixed)
Project:
Taxonomy Access Control
Version:
7.x-1.x-dev
Component:
Code
Priority:
Minor
Category:
Task
Assigned:
Unassigned
Reporter:
Created:
18 Mar 2011 at 17:30 UTC
Updated:
8 Apr 2011 at 13:41 UTC
Jump to comment: Most recent file
Comments
Comment #1
David_Rothstein commentedI believe I signed up to work on this issue also.
Just to clarify... the renaming you're thinking of is
{taxonomy_term_access}and{taxonomy_term_access_defaults}, right?Comment #2
xjmI think
{taxonomy_access_term}and{taxonomy_access_default}would be good. That way the table name starts with the module name. (I think the idea before was to make it obvious they shared keys with{term_foo}tables.)There's a related schema question I'd forgotten: I believe DBTNG supports foreign keys? Should
{taxonomy_access_term}.tidand{taxonomy_access_default}.vidbe declared as foreign keys from{taxonomy_term_data}and{taxonomy_vocabulary}? The one problem I can see is that we use 0 as the "vid" for global defaults.Edit: just chatted with pwolanin on IRC about this; I guess the foreign keys are "for documentation purposes only" and don't actually add referential integrity. http://drupal.org/node/146939
Comment #3
David_Rothstein commentedOK, glad I asked... yes, that makes more sense. Here's a patch (lightly tested).
I actually wonder if the second one would be better as
{taxonomy_access_term_default}? Anyway, it's pretty easy to change via find-replace in the patch file if necessary.I didn't deal with foreign keys here, since it sounds from your comment like it's not clear if they are 100% used that way. It could be a separate issue.
Oh, and the only places in the module left after this patch that use 'term_access' are the realms in the node access hooks. I guess there might be an argument for renaming those too.
Comment #4
xjm#1105206: Rename grant realm?
#1105202: Declare foreign keys in hook_schema?
Comment #5
xjmhttp://drupalcode.org/project/taxonomy_access.git/commit/dbf35ac