@@ -41,17 +41,6 class Workflow < ActiveRecord::Base | |||
|
41 | 41 | result |
|
42 | 42 | end |
|
43 | 43 | |
|
44 | # Find potential statuses the user could be allowed to switch issues to | |
|
45 | def self.available_statuses(project, user=User.current) | |
|
46 | Workflow.find(:all, | |
|
47 | :include => :new_status, | |
|
48 | :conditions => {:role_id => user.roles_for_project(project).collect(&:id)}). | |
|
49 | collect(&:new_status). | |
|
50 | compact. | |
|
51 | uniq. | |
|
52 | sort | |
|
53 | end | |
|
54 | ||
|
55 | 44 | # Copies workflows from source to targets |
|
56 | 45 | def self.copy(source_tracker, source_role, target_trackers, target_roles) |
|
57 | 46 | unless source_tracker.is_a?(Tracker) || source_role.is_a?(Role) |
General Comments 0
You need to be logged in to leave comments.
Login now