Mailing List Archive

Restrict Changing Ticket Milestone
Hi, I've read
https://trac.edgewall.org/wiki/CookBook/PermissionPolicies#RestrictChangingTicketMilestone
and some of the linked pages, but I'm still not clear on how to get that
to work. That page says "The action can be defined using
ExtraPermissionsProvider, and with no other changes to the permission
policy, changing the milestone property will be restricted to users with
the |TICKET_CHG_MILESTONE| permission." I've added
|TICKET_CHG_MILESTONE| as an extra permission, and it's now available as
an Action in the Grant Permission section of .../admin/general/perm.
However, users with TICKET_CHGPROP and MILESTONE_VIEW, but without
TICKET_CHG_MILESTONE are still able to change the milestone.

I want users to be able to view the milestone list and query for tickets
that are in a certain milestone, but not be able to modify the milestone
of a ticket. If I remove the MILESTONE_VIEW permission, they can't
modify a ticket's milestone, but the ticket Custom Query no longer shows
any milestones in the filter dropdown (which I think is exactly the same
behavior as before I added TICKET_CHG_MILESTONE as an extra permission).

--
You received this message because you are subscribed to the Google Groups "Trac Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to trac-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/trac-users/6c048b6b-be57-f616-fd5e-de49cab1cd7f%40azeotrope.org.
Re: Restrict Changing Ticket Milestone [ In reply to ]
On 6/18/2020 12:41 PM, David Huang wrote:
> Hi, I've read
> https://trac.edgewall.org/wiki/CookBook/PermissionPolicies#RestrictChangingTicketMilestone
> and some of the linked pages, but I'm still not clear on how to get
> that to work.
Forgot to mention that I'm on Trac 1.4.2.

--
You received this message because you are subscribed to the Google Groups "Trac Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to trac-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/trac-users/fca581c1-82a5-4158-e706-d470972afe5e%40azeotrope.org.
Re: Restrict Changing Ticket Milestone [ In reply to ]
On Thursday, June 18, 2020 at 10:41:52 AM UTC-7, David Huang wrote:
>
> Hi, I've read
>
> https://trac.edgewall.org/wiki/CookBook/PermissionPolicies#RestrictChangingTicketMilestone
> and some of the linked pages, but I'm still not clear on how to get that
> to work. That page says "The action can be defined using
> ExtraPermissionsProvider, and with no other changes to the permission
> policy, changing the milestone property will be restricted to users with
> the |TICKET_CHG_MILESTONE| permission." I've added
> |TICKET_CHG_MILESTONE| as an extra permission, and it's now available as
> an Action in the Grant Permission section of .../admin/general/perm.
> However, users with TICKET_CHGPROP and MILESTONE_VIEW, but without
> TICKET_CHG_MILESTONE are still able to change the milestone.
>
> I want users to be able to view the milestone list and query for tickets
> that are in a certain milestone, but not be able to modify the milestone
> of a ticket. If I remove the MILESTONE_VIEW permission, they can't
> modify a ticket's milestone, but the ticket Custom Query no longer shows
> any milestones in the filter dropdown (which I think is exactly the same
> behavior as before I added TICKET_CHG_MILESTONE as an extra permission).


I'm happy to hear that the feature is valuable!

Unfortunately, I didn't consider that case, so I'll have to fix it in
1.4.3. In the meantime you could replace DefaultTicketPolicy as described
in:

https://trac.edgewall.org/ticket/13316

- Ryan

--
You received this message because you are subscribed to the Google Groups "Trac Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to trac-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/trac-users/969706f0-fc5a-4fcd-9c50-b93054b9381fo%40googlegroups.com.