product edit permissions

Posts: 68
Joined: 11/26/2007

I've created an "editor" role, and checked all four of these:

- administer products
- create products
- edit own products
- edit products

under uc_product module on the Access Control page. However, when I login as an editor, I don't get the edit tab for my products, and if I go to /node/##/edit, I get permission denied.

What am I missing?

Posts: 2008
Joined: 08/07/2007
AdministratoreLiTe!

About the only thing I can see is the lack of "access content". Not having that permission overrides all of those others you checked.

Posts: 68
Joined: 11/26/2007

no, that's checked, too.

Posts: 2008
Joined: 08/07/2007
AdministratoreLiTe!

Gosh, I don't know. Double-check everything: editor role really has those permissions, a user really has the editor role, you're really logged in as that user. uc_product_access() looks correct here, and I think it has been for a long time. Check the node_access table, though the logic shouldn't be getting that far for editing.

If nothing else, you can turn on 'administer nodes' to shortcut past all the logic that doesn't work. Of course, you probably have a good reason for not doing that already. :-/

Posts: 68
Joined: 11/26/2007

turned out that when I manually created the items in the db using sql statements, I accidently assigned a input format that editors don't have permission to use. This led it to disallow editing completely. Interesting....

Posts: 17
Joined: 08/15/2007

Hi Sprungman,
Thanks for taking the time to post the result of your investigation!
Had the same problem when using uc_importer, the "format" value is hard coded to full html.

Posts: 2008
Joined: 08/07/2007
AdministratoreLiTe!

Ah yes. That's a holdover from when I used it last. Sorry for the confusion. I've changed it now to use whatever the default format has been set to.