summaryrefslogtreecommitdiff
path: root/app/controllers
diff options
context:
space:
mode:
authorFilipa Lacerda <filipa@gitlab.com>2017-02-03 19:51:41 +0000
committerFilipa Lacerda <filipa@gitlab.com>2017-02-03 19:51:41 +0000
commitfdbdd45d22c47c5b14b9ddc59d1a309bd2d7d9ce (patch)
treefcb5af6d573826d15fd1aad82304bddd2ba687d6 /app/controllers
parent183772c4488a82364425f5bc39e551988a2ac8ec (diff)
parentd76b9291f75031c729760e3e00d9f7f1aa01644d (diff)
downloadgitlab-ce-fdbdd45d22c47c5b14b9ddc59d1a309bd2d7d9ce.tar.gz
Merge branch 'master' into fe-commit-mr-pipelines
* master: (65 commits) Fixed eslint test failure Fixed adding to list bug Remove unnecessary queries for .atom and .json in Dashboard::ProjectsController#index Fixed modal lists dropdown not updating when list is deleted Fixed remove btn error after creating new issue in list Removed duplicated test Removed Masonry, instead uses groups of data Uses mixins for repeated functions Fixed up specs Props use objects with required & type values Removes labels instead of closing issue when clicking remove button Fixed JS lint errors Fixed issue card spec Added webkit CSS properties Fixed bug with empty state showing after search Fixed users href path being incorrect Fixed bug where 2 un-selected issues would stay on selected tab Fixed DB schema Changed how components are added in objects Added remove button Add optional id property to the issue schema Fixed issue link href ...
Diffstat (limited to 'app/controllers')
-rw-r--r--app/controllers/dashboard/projects_controller.rb4
-rw-r--r--app/controllers/projects/boards/issues_controller.rb6
2 files changed, 4 insertions, 6 deletions
diff --git a/app/controllers/dashboard/projects_controller.rb b/app/controllers/dashboard/projects_controller.rb
index c08eb811532..3ba8c2f8bb9 100644
--- a/app/controllers/dashboard/projects_controller.rb
+++ b/app/controllers/dashboard/projects_controller.rb
@@ -10,10 +10,8 @@ class Dashboard::ProjectsController < Dashboard::ApplicationController
@projects = @projects.sort(@sort = params[:sort])
@projects = @projects.page(params[:page])
- @last_push = current_user.recent_push
-
respond_to do |format|
- format.html
+ format.html { @last_push = current_user.recent_push }
format.atom do
event_filter
load_events
diff --git a/app/controllers/projects/boards/issues_controller.rb b/app/controllers/projects/boards/issues_controller.rb
index dc33e1405f2..61fef4dc133 100644
--- a/app/controllers/projects/boards/issues_controller.rb
+++ b/app/controllers/projects/boards/issues_controller.rb
@@ -7,7 +7,7 @@ module Projects
def index
issues = ::Boards::Issues::ListService.new(project, current_user, filter_params).execute
- issues = issues.page(params[:page])
+ issues = issues.page(params[:page]).per(params[:per] || 20)
render json: {
issues: serialize_as_json(issues),
@@ -59,7 +59,7 @@ module Projects
end
def filter_params
- params.merge(board_id: params[:board_id], id: params[:list_id])
+ params.merge(board_id: params[:board_id], id: params[:list_id]).compact
end
def move_params
@@ -73,7 +73,7 @@ module Projects
def serialize_as_json(resource)
resource.as_json(
labels: true,
- only: [:iid, :title, :confidential, :due_date],
+ only: [:id, :iid, :title, :confidential, :due_date],
include: {
assignee: { only: [:id, :name, :username], methods: [:avatar_url] },
milestone: { only: [:id, :title] }