]> git.openstreetmap.org Git - rails.git/blobdiff - app/controllers/traces_controller.rb
Remove old rails error css
[rails.git] / app / controllers / traces_controller.rb
index 4f263e9b27b3ed0ed8fcd9359d5c583dc0be6db5..0b7dbc94a60228f0e63656333a689b5abef24ec4 100644 (file)
@@ -59,9 +59,9 @@ class TracesController < ApplicationController
     @params = params.permit(:display_name, :tag, :before, :after)
 
     @traces = if params[:before]
-                traces.where("id < ?", params[:before]).order(:id => :desc)
+                traces.where("gpx_files.id < ?", params[:before]).order(:id => :desc)
               elsif params[:after]
-                traces.where("id > ?", params[:after]).order(:id => :asc)
+                traces.where("gpx_files.id > ?", params[:after]).order(:id => :asc)
               else
                 traces.order(:id => :desc)
               end