I have routes in Rails application:
resources :products do
get 'preview', to: 'products#preview', on: :member
#member do
# get 'preview'
#end
end
which defines route '/products/:id/preview'.
Products.id is bigint in a database.
When I open URL '/products/15/preview' it works fine. But when I open it with big id = 67500 which is bigger than max value for integer = 65535:
http://localhost:3000/products/67500/preview
it shows 404 error. Here id = 67500 which is bigger than Integer (65535) and the route doesn't work.
How to make Rails recognize id of BIGINT type ?