mirror of
https://github.com/oonyeje/Pearlception_Website_RoR.git
synced 2025-12-25 11:47:41 +00:00
13 lines
314 B
Ruby
13 lines
314 B
Ruby
class RunsController < ApplicationController
|
|
def index
|
|
@runs = Run.all if params[:limit] == nil
|
|
@runs = Run.take(params[:limit]) if params[:limit] != nil
|
|
|
|
respond_to do |format|
|
|
format.html
|
|
format.json {render json: @runs}
|
|
end
|
|
end
|
|
|
|
end
|