From 96d49bf04ce77c975fe500f4d961e4a1ffed4c26 Mon Sep 17 00:00:00 2001 From: Dmitriy Zaporozhets Date: Sun, 30 Dec 2012 14:43:00 +0200 Subject: Use sdoc to generate application code documentation --- doc/code/classes/DashboardHelper.html | 195 ++++++++++++++++++++++++++++++++++ 1 file changed, 195 insertions(+) create mode 100644 doc/code/classes/DashboardHelper.html (limited to 'doc/code/classes/DashboardHelper.html') diff --git a/doc/code/classes/DashboardHelper.html b/doc/code/classes/DashboardHelper.html new file mode 100644 index 00000000000..6fcb426cf13 --- /dev/null +++ b/doc/code/classes/DashboardHelper.html @@ -0,0 +1,195 @@ + + + + + DashboardHelper + + + + + + + + + + + + + +
+
+ + + + + + + + + + + + + + + +
Methods
+
+ +
D
+
+ +
+ +
E
+
+ +
+ +
+ + + + + + + + + + + + + + + + + + + + +
Instance Public methods
+ +
+
+ + dashboard_filter_path(entity, options={}) + + +
+ + +
+ +
+ + + + + + +
+ + +
+
# File app/helpers/dashboard_helper.rb, line 2
+def dashboard_filter_path(entity, options={})
+  exist_opts = {
+    status: params[:status],
+    project_id: params[:project_id],
+  }
+
+  options = exist_opts.merge(options)
+
+  case entity
+  when 'issue' then
+    dashboard_issues_path(options)
+  when 'merge_request'
+    dashboard_merge_requests_path(options)
+  end
+end
+
+
+ +
+ +
+
+ + entities_per_project(project, entity) + + +
+ + +
+ +
+ + + + + + +
+ + +
+
# File app/helpers/dashboard_helper.rb, line 18
+def entities_per_project project, entity
+  items = project.items_for(entity)
+
+  items = case params[:status]
+          when 'closed'
+            items.closed
+          when 'all'
+            items
+          else
+            items.opened
+          end
+
+  items.where(assignee_id: current_user.id).count
+end
+
+
+ +
+
+ +
+ + \ No newline at end of file -- cgit v1.2.1