summaryrefslogtreecommitdiff
path: root/app/models/issue.rb
diff options
context:
space:
mode:
authorDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2013-02-28 17:46:28 +0200
committerDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2013-02-28 17:46:28 +0200
commit115454f3ed35d136c2edd77296ffff97570a6822 (patch)
tree818cdb68c48f4d89c3dbb8ed53d6e3cedff294e2 /app/models/issue.rb
parent15b121d603db92fe8f08bfb5e55530630e3da18c (diff)
downloadgitlab-ce-115454f3ed35d136c2edd77296ffff97570a6822.tar.gz
created-by-me filter for issues inside project. Fixed global project.issues order
Diffstat (limited to 'app/models/issue.rb')
-rw-r--r--app/models/issue.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/models/issue.rb b/app/models/issue.rb
index 112f43c4692..f01cad0a458 100644
--- a/app/models/issue.rb
+++ b/app/models/issue.rb
@@ -30,6 +30,10 @@ class Issue < ActiveRecord::Base
where('assignee_id = :user', user: user.id)
end
+ def authored(user)
+ where('author_id = :user', user: user.id)
+ end
+
def open_for(user)
opened.assigned(user)
end