wiki:TracUserSelectFieldPlugin

Version 9 (modified by Cauly, 7 years ago) (diff)

--

Enable a drop-down list to select users for custom fields. Set a specific user according to workflow

This plugin uses a 'patch-style' implementation rather than the normal one. It may cause unknown influence to other plugins that depends on TicketSystem.custom_fields and ConfigurableTicketWorkflow._to_users.

Not recommended in production use. Use at your own risks.

Description

This plugin enables a field to select a specific user according to configuration. This field can later be used in workflow.

  1. Create a select Custom Field:
project_usera = select
project_usera.format = user
project_usera.user = Manager     

where:

  • field type must be 'select',
  • format must be 'user',
  • user is optional and default to 'authenticated', and can be set to comma separated users, groups or PERMISSIONS.

  1. Use this user in workflow:
    pj0102_test = PJ01 -> PJ02
    pj0102_test.operations = set_owner
    pj0102_test.name = test
    pj0102_test.set_owner = $project_usera
    

all you need to do is use a '$' with the field name.

Notice: Function 2 can also be achieved by AdvancedTicketWorkflowPlugin's set_owner_to_field operation

[ticket]
workflow = ConfigurableTicketWorkflow, TicketWorkflowOpOwnerField

[ticket-workflow]
reassign2 = new,assigned,accepted,reopened -> assigned
reassign2.operations = set_owner_to_field
reassign2.set_owner_to_field = project_usera

Bugs/Feature Requests

Existing bugs and feature requests for TracUserSelectFieldPlugin are here.

If you have any issues, create a new ticket.

defect

2 / 2

Download

Download the zipped source from here.

Source

You can check out TracUserSelectFieldPlugin from here using Git.

Installation

General instructions on installing Trac plugins can be found on the TracPlugins page.

Special: UserSelectFieldPlugin should be activated, but PatchedTicketSystem is not supposed to be activated!

Then make the following changes in your trac.ini file:

tracuserselectfield.userselectfield.userselectfieldplugin = enabled

Author/Contributors

Author: cauly
Maintainer: Cauly
Contributors:

Attachments (2)

Download all attachments as: .zip