Project

General

Profile

Actions

Defect #35224

open

Adding new project impossible with mandatory custom field of type users

Added by Marc Cramer almost 3 years ago. Updated almost 3 years ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
Projects
Target version:
-
Start date:
Due date:
% Done:

0%

Estimated time:
Resolution:
Affected version:

Description

Redmine: 4.1.2
Rails: 5.2.4.4
PostgreSQL: 12.5
No Plugins

I was just hit by this issue, kind of a logical bug:

I cannot add a new project if there is a mandatory custom field with a user
drop-down list, since there are no users initially--but I cannot add users
unless the project has been created...

To reproduce:

- Add a custom field to projects
- Field type: Users
- Make the field mandatory
- Try to add a new project

Expected behaviour:

- Find a prefilled list of users in the drop down
- Able to submit (create new project)

Current behaviour:

- User list is empty (possibly because the project has no users?)
- Toggling inheritage of users does not help
- Cannot submit project because the custom field is still empty but mandatory

Workaround:

- Make custom field optional
- Add project (with empty user selection)
- Add users to the project
- Edit project again and select user from drop down list

Am I missing something trivial?

Thanks

Actions #1

Updated by Go MAEDA almost 3 years ago

Marc Cramer wrote:

Expected behaviour:

- Find a prefilled list of users in the drop down
- Able to submit (create new project)

Current behaviour:

- User list is empty (possibly because the project has no users?)
- Toggling inheritage of users does not help
- Cannot submit project because the custom field is still empty but mandatory

I agree that there is a problem with the current behavior as you pointed out, but if the behavior changed as above, the project will be created with the required custom field blank. This means that fixing this "bug" makes another bug.

Actions #2

Updated by Marc Cramer almost 3 years ago

Go MAEDA wrote:

Marc Cramer wrote:

Expected behaviour:

- Find a prefilled list of users in the drop down
- Able to submit (create new project)

Current behaviour:

- User list is empty (possibly because the project has no users?)
- Toggling inheritage of users does not help
- Cannot submit project because the custom field is still empty but mandatory

I agree that there is a problem with the current behavior as you pointed
out, but if the behavior changed as above, the project will be created with
the required custom field blank. This means that fixing this "bug" makes
another bug.

Yeah, right... Maybe we should then distinguish a bit:

I can imagine a lot of cases (like mine) where it makes sense to select a user
from the drop-down list that is just any existing user and unrelated to
the users being assigened to the project.

So, it sounds like this issue is direcing us towards a RFE to have a custom
field type like 'project member' vs. 'any user'.

In my case I'd need something like a drop-down for 'any user'.

Does that make sense to you?

Actions #3

Updated by Marc Cramer almost 3 years ago

Ok, can we move this into the Open Features list then somehow?

Summary: Custom field 'users' should be split into 'users (project members)' and 'users (all)'
since a mandatory user drop-down prevents from adding new projects because there are no users
yet.

Actions

Also available in: Atom PDF