Feature #2708

Require Category

Added by Brandon Dixon over 8 years ago. Updated about 6 years ago.

Status:ClosedStart date:2009-02-10
Priority:NormalDue date:
Assignee:-% Done:

0%

Category:-
Target version:-
Resolution:Duplicate

Description

As of now I am using Redmine to monitor corporate IT. I have one main project and multiple sub-projects (i.e networking, software, etc.) that users can post tickets to. The problem I have with this is that it doesn't seem like its a correct way of doing things. I would like to have one project and then have users assign their tickets to categories (i.e networking, software, etc.). The problem now is that users submit a ticket, but since its a category is not required users won't always fill it out. This leaves me going back and fixing the mistakes. Is there a way to make the Category value required?

_form.rhtml Magnifier - app\views\issues\_form.rhtml (3.11 KB) Nanda P, 2009-04-17 21:09

issue.rb Magnifier (11.5 KB) Nanda P, 2009-04-17 21:09

_form.rhtml Magnifier (3.16 KB) Brandon Dixon, 2009-06-30 16:51


Related issues

Related to Redmine - Feature #703: Configurable required fields per tracker/status/role Closed 2008-02-21

History

#1 Updated by Eric Davis over 8 years ago

I don't use categories that much so if this feature is implemented, making category required should be an optional setting.

#2 Updated by Nanda P over 8 years ago

+1

We have 10+ Projects. For one of project, the manager wants category field as Required.

As Brandon said "When users submit a ticket, they forget to fill the category out". It is time consuming to go through the description of those tickets & fill the category later.

Another idea: If we can take out the Category field. I can add a custom field called category ;) & make it Required.

I am looking for a temp fix, until we find a solution.

Any suggestions?

Thanks,
Nanda

#3 Updated by Peter Edstrom over 8 years ago

+1

See also #703 and #582 for slightly different takes on this.

We use inbound email, where a category can be defaulted. This is great because the owner of the category is alerted when a new issue is created. When issues are created in the tool, however, the category is not required and thus no one is guaranteed to be notified of the new issue.

#4 Updated by Nanda P over 8 years ago

app\views\issues\_form.rhtml -> Change in line # 27

validates_presence_of :subject, :description, :priority, :category, :project, :tracker, :author, :status

app\models\issue.rb -> Change in line # 48

validates_presence_of :subject, :description, :priority, :category, :project, :tracker, :author, :status

#5 Updated by Nanda P over 8 years ago

Nanda Palaniswamy wrote:

appviewsissues_form.rhtml -> Change in line # 27
[...]

appmodelsissue.rb -> Change in line # 48
[...]

I modified the above files to make the category as Required field.

#6 Updated by Paul Voelker over 8 years ago

I think giving the option to require the category field would be fantastic. This would be great for those who make use of the auto-assignment functionality of categories.

#7 Updated by Brandon Dixon over 8 years ago

I am running the latest version (0.8.4) and it looks like some things were changed.

This works:
app\models\issue.rb -> Change in line # 48

validates_presence_of :subject, :description, :priority, :category, :project, :tracker, :author, :status

The first mod to the form on the other hand does not work. It now looks like this:
app\views\issues\_form.rhtml -> Change in line # 28

<p><%= f.select :category_id, (@project.issue_categories.collect {|c| [c.name, c.id]}), :include_blank => true, :required => true %>

#8 Updated by Nanda P almost 8 years ago

Brandon,

The patch is not working with trunk version (Redmine 0.8.7.devel.3131)

When you get a chance could you please have a look?

Thanks in Advance
Nanda

#9 Updated by Nanda P over 7 years ago

Any update on this?

#10 Updated by Jeremy Walker over 7 years ago

+1

#11 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.)

Follow it as you normally would with one exception...
The edit to this file....:
app/views/issues/_form.rhtml
should instead be done to this file:
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.

#12 Updated by Patrick Sherman about 7 years ago

+1

Chad, how did you do?

#13 Updated by Anonymous about 7 years ago

How about extending required yes/no to all fields in an issue?
Some of them are already required on system level.
Given the fact that you can set required yes/no on custom fields, this seems like a logical step.

#14 Updated by Terence Mill about 7 years ago

Even better would be setting required fields dependent on the status for the ticket. This way someone can better design details of the workflow..

#15 Updated by Nathanael Hansen about 6 years ago

+1

#16 Updated by Etienne Massip about 6 years ago

  • Status changed from New to Closed
  • Resolution set to Duplicate

Dup of #703.

Also available in: Atom PDF