Feature #1248

Permissions - Edit own issues

Added by Ronie Henrich over 9 years ago. Updated 14 days ago.

Status:NewStart date:2008-05-16
Priority:NormalDue date:
Assignee:-% Done:

0%

Category:Permissions and roles
Target version:Candidate for next major release
Resolution:

Description

  • Today (as in version 0.7.1):
    • We may only grant/revoke a role the permission to edit any issues ("Edit issues" permission).
  • Suggestion / Request:
    • It would be nice to be able to grant/revoke a role the permission to "Edit own issues".

0001-Added-edit_own_issues-and-edit_own_new_issues-permis.patch Magnifier (5.88 KB) Leo Hourvitz, 2010-10-08 05:41


Related issues

Related to Redmine - Patch #7444: Patch for improved issue edit permissions Closed 2011-01-25
Related to Redmine - Feature #5195: edit_own_issues and delete_own_issues permissions New 2010-03-26
Duplicated by Redmine - Feature #8805: Please consider to make a new permission for "edit _own_ ... Closed 2011-07-13
Duplicated by Redmine - Feature #6194: Edit own issues Closed 2010-08-23

History

#1 Updated by Jean-Philippe Lang almost 9 years ago

  • Target version deleted (0.8)

#2 Updated by Daniel Jones over 8 years ago

+1

#3 Updated by Royce Williams over 7 years ago

+1. Empowering users to modify their own request can reduce the load on the people processing requests.

#4 Updated by Алексей Лошкарёв about 7 years ago

+1 This may reduce count of misspelled or invalid bug. Because user may do mistake on filling bug.

#5 Updated by Leo Hourvitz about 7 years ago

I have a patch for this against recent trunk, attached. We are having this problem in a big way at an installation of mostly native Japanese speakers; with Asian languages, you're always hitting return to do Kanji conversion of your input and one extra carriage return means a half-baked issue in the tracker!

New Permissions

I addressed this by creating two new permissions that can be assigned to roles:
  • edit_own_issues allows users with that permission to edit issues they created (i.e., whose author field is equal to the current user). This addresses the problem, but is potentially a big workflow change, so not all sites might want it.
  • edit_own_new_issues is a more limited permission that allows a user to edit their own issues if there are no journals yet, or if all existing journals were created by the author. I think this is really the pinpoint solution to the problem; as far as I know, all edits will create a journal, so this lets you edit your issue until the moment someone else pays attention to it.
    • Because it seems like such a contained right, in the patch I added it to the default permissions for the Reporter role.

Implementation

To implement the above, I created a new editable? predicate on the issue model parallel to the visible? predicate that was already there (this also seems like a pretty good pattern to follow in general). Then, I changed the code that was doing
User.current.allowed_to?(:edit_issues, @project)
to just call
issue.editable?
instead.

I updated the English and Japanese locales as well.

The patch file was formatted with git format-patch; is that the preferred patch format? Specifically, the patch was generated against svn+ssh://rubyforge.org/var/svn/redmine/trunk@4175 e93f8b46-1217.

I'm fairly new to Redmine and Ruby, so it would definitely be good to get other eyes on this patch. I'll be able to get in some more testing next week. My configuration is:

bash-3.2$ RAILS_ENV=production ruby script/about
About your application's environment
Ruby version              1.8.7 (universal-darwin10.0)
RubyGems version          1.3.5
Rack version              1.0
Rails version             2.3.5
Active Record version     2.3.5
Active Resource version   2.3.5
Action Mailer version     2.3.5
Active Support version    2.3.5
Application root          /Users/leo/OpenSrcSources/redmine
Environment               production
Database adapter          mysql
Database schema version   20100819172912

#6 Updated by Leo Hourvitz about 7 years ago

I also applied this patch on our production redmine at work (Redmine 1.0.1 release on CentOS 5.2).

#7 Updated by Nathan Eggen almost 7 years ago

+1 - this should go in the trunk.

#9 Updated by Brian Lindahl over 6 years ago

Created patch issue to follow the progression of my patch to add this feature and other issue edit permission improvements. Please add relation to #7444.

#10 Updated by Leo Hourvitz over 6 years ago

Is there any approved way to urge this get moved to trunk? I need to apply this on every Redmine instance we use, I think any installation with real scale of users is unmanageable without something like this.

Brian: I don't seem to have permissions to add the relation.

#11 Updated by Brian Lindahl over 6 years ago

Leo: Issue relations in Redmine are controlled by a different permission: 'Manage issue relations'. I can see a situation where project managers/software leads would not want issue reporters to have the ability to set up relations. Perhaps another permission should be added: 'Manage own issue relations'?

#12 Updated by Brian Lindahl over 6 years ago

Leo: Hah! Just realized that you were saying that you don't have the permissions to relate this issue to my patch issue #7444.

#13 Updated by Etienne Massip over 6 years ago

  • Target version set to Candidate for next major release

#14 Updated by Gokay Gok almost 6 years ago

+1

#15 Updated by Aleksej Lebedev almost 6 years ago

+1

#16 Updated by Yannick Recht over 5 years ago

+1 also.

It should be interesting to add this parameter.

#17 Updated by Gabriel Mazetto over 5 years ago

It's also wise to have a "time limit" to help people not trying to modify something made a year ago, for example. As we will never find a good for everyone value, it's good to have it configurable, some values as suggestion:

  • Limit own issue editing and own issue comments:
    • Custom (please specify)
    • 30 days
    • 15 days
    • 7 days
    • 3 days
    • 24 hours
    • 12 hours
    • 6 hours
    • 3 hours
    • less then one hour
    • Never

#18 Updated by Rolf Bagge about 5 years ago

+1

#19 Updated by Bruno Passos about 5 years ago

+1

#20 Updated by Thierry Brochu almost 5 years ago

This would be an excellent feature to allow our client to edit the mistakes on its own created issues without having us to deal with it through a note left on this same issue by him. +1

#21 Updated by Terence Mill almost 5 years ago

+1 - very useful for redmine.org itself

#22 Updated by Damian G about 4 years ago

+1 crucial

#23 Updated by Florian Kaiser almost 4 years ago

+1

#24 Updated by Alain V. over 3 years ago

+1 please for 3.0.0

#25 Updated by Alain V. about 3 years ago

A feature that we should have, please!

#26 Updated by Etienne Massip about 3 years ago

#27 Updated by Toshi MARUYAMA about 3 years ago

  • Related to Feature #5195: edit_own_issues and delete_own_issues permissions added

#28 Updated by Alain V. almost 3 years ago

+1 please

#29 Updated by Oleg Aksenov over 2 years ago

+1

#30 Updated by Omer Arslan over 2 years ago

+1 - will be very useful

#31 Updated by Guillaume Laneel over 2 years ago

+1 will be usefull

#32 Updated by Sandro De Melis over 2 years ago

+1 this would be an excellent feature

#33 Updated by 4wk_ _ over 2 years ago

+1, really need this. "Editing issue" grant ppl to be like an admin ! (and we don't want that, we want "Edit own issue")

#34 Updated by Chet Wang over 2 years ago

+100

I really need this feature. We're planning to use Redmine but the lack of this feature blocks a lot.

#35 Updated by Do Lam over 2 years ago

+100. We need this permission.
Thank so much!

#36 Updated by Alexander Lyzhenkov over 2 years ago

+100 v 3.1

#37 Updated by Trurl McByte about 2 years ago

+100500 It's bad idea to give access to edit all issues for Reporter only for possibility to change Status from Resolved to Closed

#38 Updated by Adnan Topçu almost 2 years ago

Leo Hourvitz's edit_own_new_issues is good idea.
edit_own_issues is topic of this issue.
edit assigned issues is most important for me

In my opinion, "own" is not clear for this mean. Reported or created is more understable ?

#39 Updated by budo kaiman almost 2 years ago

+1 to separate "Edit Reported Issues" and "Edit Assigned Issues".

#40 Updated by Ronie Henrich almost 2 years ago

Adnan Topçu wrote:

Leo Hourvitz's edit_own_new_issues is good idea.
edit_own_issues is topic of this issue.
edit assigned issues is most important for me

In my opinion, "own" is not clear for this mean. Reported or created is more understable ?

Owner == Author all accross Redmine, modifying this Redmine convention is out of this issue's scope.

#41 Updated by Ronie Henrich almost 2 years ago

budo kaiman wrote:

+1 to separate "Edit Reported Issues" and "Edit Assigned Issues".

  • In regards to "Edit Reported Issues", please read my comment 40 (#1248#note-40) above;
  • If a user belongs to a role with "Issues can be assigned to this role" enabled, having something like "Edit Assigned Issues" is not gonna stop him/her to edit an issue, it is just a matter of assigning the issue to himself/herself and voila, now he/she may edit the issue.

#42 Updated by budo kaiman almost 2 years ago

Ronie Henrich wrote:

  • If a user belongs to a role with "Issues can be assigned to this role" enabled, having something like "Edit Assigned Issues" is not gonna stop him/her to edit an issue, it is just a matter of assigning the issue to himself/herself and voila, now he/she may edit the issue.

That only works if they already have "Edit Issues" permission, if they don't have that permission then they cannot assign an issue to themself, someone else with that permission must assign the issue to them.

Ronie Henrich wrote:

Owner == Author all accross Redmine, modifying this Redmine convention is out of this issue's scope.

I don't think that there is any scope change, just a wording change as "Author" or "Reporter" is more clear in it's intention.

#43 Updated by Yuuki NARA about 1 year ago

+1

#44 Updated by Pasi Karkkainen 10 months ago

Yes please, this is an important feature to have!

#45 Updated by José Campos 9 months ago

+1

#46 Updated by Eugene Belford 14 days ago

must have feature indeed

Also available in: Atom PDF