Questions tagged [ruby-on-rails]
Ruby on Rails is an open source full-stack web application framework written in Ruby. It follows the popular MVC framework model and is known for its "convention over configuration" approach to application development.
ruby-on-rails
9
questions
0
votes
1
answer
17
views
Can I pass an argument and sort using ransack
"I want to display the exact ID at the top when searching.
For example:
select *
from user
order by user.id = 25 DESC, created_at DESC;
How can I implement this using ransack?"
0
votes
0
answers
13
views
HABTM relationship / validates associated: valid? is true even though I don't think it is
I made the following join table to be used in a HABTM relationship between tasks and itself:
create_table :tasks_tasks, id: false do |t|
t.belongs_to(
:dropoff_task,
null: false,
...
0
votes
0
answers
8
views
Issue with rails hotwire trix textarea resize
im trying to create a textarea resize grippie more or less like the SO for a trix textarea with rais stimulus so i set this controller below
the issue is when i pull down the textarea the textarea ...
0
votes
0
answers
17
views
RPush sending APNs 403/InvalidProviderToken
recently I'm struggling with adding APNs feature to my Ruby on Rails(7) project using RPush. I made some wrong config before and that lead to a failed launch of rails s, then I found and fixed it so I ...
0
votes
1
answer
50
views
Model VS Active record in ROR
Can somebody please explain me the difference between model and active record in simple words ?
Is active model and model same ?
PS: Knowledge regarding these topics will be appreciated.
I am newbie ...
0
votes
1
answer
29
views
Why can't I wrap Sidekiq.configure_server in Rails after_initialize?
After upgrade to Rails 6 the initializers/sidekiq.rb is causing deprecation warnings about class autoloading. As a workaround I thought I could wrap the contents of Sidekiq.configure_server in Rails....
0
votes
0
answers
19
views
Ruby on Rails throws LoadError: Unable to autoload constant for one job, but not for the second [duplicate]
My code triggers two Sidekiq jobs called ExcelImportReconcileWorker with different arguments. The worker creates a new instance of a Parsers::ExcelImport class and runs a method in it. Every time ...
0
votes
0
answers
38
views
Rails: problem with "@hotwired/turbo-rails" and redirects
// app/javascript/application.js
import "@hotwired/turbo-rails"
import "controllers"
import "trix"
import "@rails/actiontext"
import Rails from "@rails/ujs&...
0
votes
0
answers
13
views
Ruby/Rails Bunny RabbitMQ Must be one of [:method, :headers, :body, :heartbeat]
I get an error when trying to connect to RabbitMQ.
Error backtrace:
.../amq-protocol-2.3.2/lib/amq/protocol/frame.rb:67:in `decode_header'
Error:
Must be one of [:method, :headers, :body, :heartbeat]
...