Feature #6641
opencreating project-specific activities
0%
Description
Hi
I have a couple of projects (one for each organizational unit), where people can create issues that we then handle. Sometimes someone wants to know how much time we've spent on specific activities.
For example, one project have these activities: * DNS overhaul * Storage expansion for voice-2-text servers
Another project these: * More volunteers * Sponsors for knife campaign * Artwork
I'm using the activity field to create per-project activities, which we can then map time spent into.
I found out that this is possible because there is a 'system activity' flag in the GUI which I took as a sign that non-system activities are possible. I accessed the database with a CLI tool and created per-project activities.
However, since there already is a per-project activity page (such as here: http://redmine/projects/PROJECT/settings/activities), it would be very nice if it was possible to create per-project activities here instead of with the database CLI.
In short, the per-project activity administration page needs a "New Activity" button. And an edit button to go with it. And a delete button somewhere..
If I went ahead and implemented this, would there be any philosophical arguments against integrating it into Redmine?
I am thinking that if there is a reason that this feature is currently missing, maybe I should instead work on my own plugin?
Files
Updated by Felix Schäfer about 14 years ago
I think it's a problem of permissions, as the activities are currently only manageable for the administrator.
Updated by Albert Rosenfield about 14 years ago
Hi
Thanks for the suggestion!
Just logged in and checked again, both on a production setup (0.9.something) and on a 1.0.3 I am configuring to take over.
Nope, on both systems it is not possible to add or edit per-project activities.
(I logged in as "admin", I couldn't find a way to enable more privileges for this account.)
Are the buttons supposed to be there already? Maybe this is a bug, then?
Updated by Albert Rosenfield about 14 years ago
I've looked in redmine/app/views/projects/settings/_activities.rhtml and currently there is only a Reset and Save button, nothing for add/edit/delete.
Updated by Felix Schäfer about 14 years ago
An admin can only manage (add, edit, remove) them at global, not at project level. The only project-level permission for them is selecting which ones are available for that project.
What I meant is that there is currently no permission "manage activities" (as in "add, edit, remove"), and giving those at project level would mean that they wouldn't be shareable without either making them all global or implementing a "complex" system as for the versions. This is just not there yet for the activities.
Updated by Albert Rosenfield about 14 years ago
What I meant is that there is currently no permission "manage activities"
(as in "add, edit, remove"), and giving those at project level would mean
that they wouldn't be shareable
Exactly what I'm after.
This is just not there yet for the activities.
Okay.
How do I best make this happen?
I am thinking: * Create a redmine plugin * Copy app/views/projects/settings/_activities.rhtml into the plugin * Edit this and create add/edit buttons
Then, * Test that everything works * do a diff -u and submit a patch to redmine-patches (?)
As far as I can tell, the database support is already in place for this feature in the base install.
Updated by Felix Schäfer about 14 years ago
A diff: yes, but if you want to play with core, submit a diff against core directly, i.e. work on a versioned installation. You could also make it as a plugin, but then just publish the plugin and link it from here.
Updated by Albert Rosenfield about 14 years ago
Created a plugin ;-).
It requires two patches to core:- Disallow saving an enumeration with is_default = 1 and project_id <> nil
- Avoid filtering out all system activities when a non-inherited project-specific activity exists (in system_activities_and_project_overrides).
Can we apply them to core (in app/models/project.rb)?
Even though specifically crafted for this plugin, they do not break anything.
Or is there a way that I can override models/controllers/public in a plugin? I've tried but haven't figured it out.
Updated by Albert Rosenfield about 14 years ago
- File do_not_allow_setting_is_default_if_project_id_is_set.patch do_not_allow_setting_is_default_if_project_id_is_set.patch added
- File do_not_filter_out_all_system_activities_when_a_noninherited_project_specific_activity_exists.patch do_not_filter_out_all_system_activities_when_a_noninherited_project_specific_activity_exists.patch added
Updated by Greg T over 4 years ago
This is related to #4077.
"System Activity" (enumeration_system_activity in locales) is baffling when there's no other kind.