summaryrefslogtreecommitdiffstats
path: root/app/models/committership.rb
diff options
context:
space:
mode:
authorJohan Sørensen <johan@johansorensen.com>2009-02-18 15:54:34 +0100
committerJohan Sørensen <johan@johansorensen.com>2009-04-22 15:14:29 +0200
commit78e8dfe12131b99627ff55268794070d25ed6d10 (patch)
tree3af72ab907f192012bac3a7179a08927466cb03b /app/models/committership.rb
parent74b4c751c7eddfcb2ee7fca4c79d23aaf953bdd8 (diff)
downloadgitorious-mainline-outdated-78e8dfe12131b99627ff55268794070d25ed6d10.zip
gitorious-mainline-outdated-78e8dfe12131b99627ff55268794070d25ed6d10.tar.gz
gitorious-mainline-outdated-78e8dfe12131b99627ff55268794070d25ed6d10.tar.bz2
Clicking the "manage committers" link on a repository takes them to the
committerships page
Diffstat (limited to 'app/models/committership.rb')
-rw-r--r--app/models/committership.rb5
1 files changed, 4 insertions, 1 deletions
diff --git a/app/models/committership.rb b/app/models/committership.rb
index 1711d32..f6832ba 100644
--- a/app/models/committership.rb
+++ b/app/models/committership.rb
@@ -22,12 +22,15 @@ class Committership < ActiveRecord::Base
validates_presence_of :committer_id, :committer_type, :repository_id
+ named_scope :groups, :conditions => { :committer_type => "Group" }
+ named_scope :users, :conditions => { :committer_type => "User" }
+
def breadcrumb_parent
Breadcrumb::Committerships.new(repository)
end
def title
- new_record? ? "New commit team" : "Commit team"
+ new_record? ? "New committer" : "Committer"
end
# returns all the users in this committership, eg if it's a group it'll