Patch #3461

Manage permission on issue assigment

Added by Yohann Monnier over 8 years ago. Updated over 5 years ago.

Status:ClosedStart date:2009-06-08
Priority:NormalDue date:
Assignee:-% Done:

0%

Category:Permissions and roles
Target version:-

Description

We had some problems with customers who assigned issue directly to one of our developper, so we searched how to manage right on it.

As this permission wasn't implemented, we did it. (patch linked)

With this patch you manage this permission for roles, so you can control who can assign a tack and who can not on a project, according to the role of the user.

If have no right to assign an issue, you see the name of the user assigned to the task.

I would like to see this feature add the main trunk, as i know it could be usefull for many users.

Yohann Monnier - Internethic

redmine-0.8-issue-assignment-right.patch Magnifier - Patch - issue assigment permission (3.31 KB) Yohann Monnier, 2009-06-08 13:40

redmine-1.0.4-issue-assignment-permission.patch Magnifier (3.92 KB) Arne-Kolja Bachstein, 2010-12-15 16:10

redmine-1.0.4-issue-assignment-permission.patch Magnifier (5.48 KB) Arne-Kolja Bachstein, 2010-12-15 16:35


Related issues

Related to Redmine - Patch #7444: Patch for improved issue edit permissions Closed 2011-01-25

History

#1 Updated by Jens Goldhammer over 8 years ago

+1!

#2 Updated by Adam Piotr ┼╗ochowski over 8 years ago

This ties quite well with #482 .

So anyone can create a ticket, but ticket assigned to is auto routed to right person.
This person approves ticket, and forwards to proper developer, and stops ticket dead.

Kind regards

#3 Updated by James Holle over 8 years ago

+1 Thanks. This is great!

Is it possible to have a someone without permission still be able to assign an issue to themselves though? This way we our developers could create an issue and assign it to either themselves or no one. Although managers would still retain the right to assign to anyone eligible. I'd hate make a manager assign every little task, but at the same time a developer couldn't step on any toes :)

I'm guessing this would only require a modification to the last line in your change in the rhtmls. Such as:

<p><%= f.select :priority_id, (@priorities.collect {|p| [p.name, p.id]}), :required => true %></p>
<% if User.current.allowed_to?(:manage_issue_assignment, @project) -%>
<p><%= f.select :assigned_to_id, (@issue.assignable_users.collect {|m| [m.name, m.id]}), :include_blank => true %></p>
<% else %>
<p><%= f.select :assigned_to_id, (@issue.author.collect {|m| [m.name, m.id]}), :include_blank => true %></p>
<% end %>

But, this doesn't work. No ruby skills here ;)
Your thoughts?

#4 Updated by Stanislav German-Evtushenko over 8 years ago

Hi Yohann,

Could you put screenshots here, please?

#5 Updated by Chris Grieger over 8 years ago

+1

Wasn't able to get this patch running. Is it enough to put the

  permission_manage_issue_assignment: Assign an issue 
into the Libs/redmine.rb?

I can't see the permission in my role-permission edit form to add it to a role.

#6 Updated by Yohann Monnier over 8 years ago

Hello Chris,

You have to apply the entire patch (4-5 files, it depends if you use french translation or not)

Yohann

#7 Updated by Yohann Monnier over 8 years ago

Chris Grieger wrote:

+1

Wasn't able to get this patch running. Is it enough to put the [...] into the Libs/redmine.rb?

I can't see the permission in my role-permission edit form to add it to a role.

Be carefull, you did put the right "patch" in the right patch.

#8 Updated by Yohann Monnier over 8 years ago

Sorry for the multiple post, I can not edit my comments.

Be carefull, you did NOT put the right "patch" in the right file.

#9 Updated by Harwant Pannu over 7 years ago

We tried to use this patch on our 0.9.3 install of Redmine and it did not work for us. We got some kind of "unknown variables" errors at install time.

Anyone knows what is going on? Any ideas, tips or updated patch for the newer releases of Redmine?

Thanks for your attention.

#10 Updated by Chad S about 7 years ago

I have a fix for this guys that works with 1.0.x (which i assume would work with 0.9.x, but i have not tested it.)

Click the patch above to view (this link below is the same):
http://www.redmine.org/attachments/2156/redmine-0.8-issue-assignment-right.patch

Follow it as you normally would with one exception...
The edit to the first file should not be done to this file:
app/views/issues/_form.rhtml
but to this file instead:
app/views/issues/_attributes.rhtml

I have this working after upgrading from 0.8.x to 1.0.x. Reply here if you need help getting this working.

#11 Updated by Brian Heasley almost 7 years ago

+1

Thanks for the fix, Chad S. It worked fine on 1.0.2.stable. One additional comment, the "lang/en.yml" file now seems to be in "config/locales/".

#12 Updated by Arne-Kolja Bachstein almost 7 years ago

I've created a new patch to handle this. Hope the patch file is created correctly, it's my first diff ;) Just look inside to make sure everything's fine.

I'm implementing permissions for view_issue_assignment and manage_issue_assignment and do some view conditionals based on this in show.rhtml, _attributes.rhtml.

As I included the possibility to hide assignments completely (permission view_issue_assignment) I had to do some nasty stuff in app/models/query.rb. If anyone knows how to improve it, please share. I just didn't find an other way yet.

Patch is created against Redmine 1.0.4 vanilla.

#13 Updated by Arne-Kolja Bachstein almost 7 years ago

added translations to my patch

#14 Updated by Brian Heasley over 6 years ago

Any word on using this with v1.1.0?

#15 Updated by Terence Mill over 6 years ago

+1

This so useful ! A real enteprise feature!

#16 Updated by Brian Lindahl over 6 years ago

similar improvements found in patch #7444

#17 Updated by Ivo Leite over 6 years ago

+1

#18 Updated by Terence Mill over 6 years ago

However this should be extended to a "complete" solution for this kind of feature
See #8050

#19 Updated by Jean-Philippe Lang over 5 years ago

  • Status changed from New to Closed

Superseded by #3521. Each issue field can now be controled by role/tracker/status.

Also available in: Atom PDF