Hi,
My users have the right to edit their own node. But I would like them to be able to do that only on unpublished nodes. Would be fine to add this option in TAC, to prevent users to edit published nodes :p
Hi,
My users have the right to edit their own node. But I would like them to be able to do that only on unpublished nodes. Would be fine to add this option in TAC, to prevent users to edit published nodes :p
Comments
Comment #1
keve commentedThis should not be a TAC issue, maybe you should write a different module for it.
But this feature has not much point. As far as i know, unpublished nodes are completely invisible except for user 1. Other users cannot even see it, so how would you like to make them to be able to edit it?
Maybe you should make a vocab that controlls access, on my commercial site i have a vocab that controlls permissions w/ terms: 'Editor's page' (Only content editors can see, and edit it), and 'public page' (Published pages viewable by everybody. When page is completely ready, editors can set this term for the page, so it became 'published' to the public)
Comment #2
Julien PHAM commentedWith a module such as workspace a user can see ALL of his nodes, even those who are not published yet. So they can edit their own node... But they can edit published nodes as well, and I don't like that...
Your vocab thing seems cool... do you have more info on how I can setup this? Perhaps three different vocabs? One for composing articles, one for moderation articles, and one for published one?
I'm using drupal CMS for some kind of a newspaper, where people create articles... They can edit them, and then they put them in moderation queue... And a moderator put them as published. I use workflow to do this, but perhaps I can find a better way to do this.
The more important thing in my website is that there are two people : the redactor and the moderator. The writer can write articles but cannot publish it, only the moderator can publish'em. And the writer should be able to edit an article as long as he wish before submitting it to moderation queue. And if I can... after an article is published the writer shouldn't be able to edit it again... I'm unsure how I can do this, until then I used workflows...
Comment #3
keve commentedI am not familiar w/ workflow module.
You can try making only one vocabulary called e.g "Visibility" or "Moderation".(THis controls who can see or edit article):
Make three TERMS there: eg: "one composing articles, one
for moderation articles, and one for published one".
Then you can set permissions for each term for each user role.
Comment #4
Julien PHAM commentedThanks. I tried and it works fine. And I created views so I can filter to not display some nodes according to this new vocabulary.
My only issue now is that if a writer follows the link to the taxonomy term, he will see all articles.
Is it possible to setup drupal so when a user follows the taxonomy link term he will be redirected to the views instead?
Thanks
Comment #5
keve commentedYou can hide term link, by unchecking 'List' permission for that user role. (In this case, also term-page gives page not found e.g./taxonomy/term/{tid})
Comment #6
Julien PHAM commentedI do not want to hide it, I like having the taxonomy in my article, but I would like to redirect for example taxonomy/term/2 to the view I created for this...
Perhaps I can play then with the .htaccess file and apache redirect feature...
Comment #7
keve commentedOk, for this two option:
1. you have to patch taxonomy.module hook_links.
2. you write a module for this to create the links, and then you can hide original taxonomy links either with TAC or taxonomy_hide.
Comment #8
Julien PHAM commentedI just found a cool module to do this... taxonomy redirect :p
Comment #9
Julien PHAM commentedmmm correction it does not fix anything, it just changes the path :) I'll have to find someting better ;)
Comment #10
keve commentedIf you can redirect path for term's page, you can write your own module for creating customized page.
GL, Keve
Comment #11
Julien PHAM commentedI found a better way. Taxonomy redirect can redirect the taxonomy to any webpage, such as a view, so I redirected all taxonomy to /view path, so the taxonomy term 1 is at http://www.example.org/view/1. And so on. I then changed all my views to have such urls like /view/number. And then I use the alias system to give my view/1 an other name.