From c3ba2cabaff2390ef0521717625661560498dbe2 Mon Sep 17 00:00:00 2001 From: Martin Edenhofer Date: Mon, 2 Oct 2017 14:34:34 +0200 Subject: [PATCH] Change online notification limit from 100 to 200. --- app/controllers/online_notifications_controller.rb | 6 +++--- app/controllers/sessions/collection_base.rb | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/app/controllers/online_notifications_controller.rb b/app/controllers/online_notifications_controller.rb index 6bd994aac..3b499453c 100644 --- a/app/controllers/online_notifications_controller.rb +++ b/app/controllers/online_notifications_controller.rb @@ -48,11 +48,11 @@ curl http://localhost/api/v1/online_notifications.json -v -u #{login}:#{password def index if params[:full] - render json: OnlineNotification.list_full(current_user, 100) + render json: OnlineNotification.list_full(current_user, 200) return end - notifications = OnlineNotification.list(current_user, 100) + notifications = OnlineNotification.list(current_user, 200) model_index_render_result(notifications) end @@ -146,7 +146,7 @@ curl http://localhost/api/v1/online_notifications/mark_all_as_read -v -u #{login =end def mark_all_as_read - notifications = OnlineNotification.list(current_user, 100) + notifications = OnlineNotification.list(current_user, 200) notifications.each do |notification| if !notification['seen'] OnlineNotification.seen( id: notification['id'] ) diff --git a/app/controllers/sessions/collection_base.rb b/app/controllers/sessions/collection_base.rb index 55eb9c078..03cf94d7f 100644 --- a/app/controllers/sessions/collection_base.rb +++ b/app/controllers/sessions/collection_base.rb @@ -11,7 +11,7 @@ module ExtraCollection assets = item.assets(assets) } - collections[ OnlineNotification.to_app_model ] = OnlineNotification.list(user, 100) + collections[ OnlineNotification.to_app_model ] = OnlineNotification.list(user, 200) assets = ApplicationModel.assets_of_object_list(collections[ OnlineNotification.to_app_model ], assets) collections[ RecentView.to_app_model ] = RecentView.list(user, 10)