mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2024-12-31 04:32:06 +08:00
fixed oversight, added paging to connections
This commit is contained in:
parent
c5300865d6
commit
fa54badb9a
1 changed files with 2 additions and 0 deletions
|
@ -10,6 +10,8 @@ module Api
|
|||
before_action :load_connection, only: :show
|
||||
|
||||
def index
|
||||
@connections = @connections.page(params.dig(:page, :number))
|
||||
.per(params.dig(:page, :size))
|
||||
render jsonapi: @connections, each_serializer: ConnectionSerializer
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue