python (12.9k questions)
javascript (9.2k questions)
reactjs (4.7k questions)
java (4.2k questions)
java (4.2k questions)
c# (3.5k questions)
c# (3.5k questions)
html (3.3k questions)
Ransack:Error - I'm trying to render nav bar with ransack search bar on every page but getting errors when I click on show, new page
I'm new to ruby on rails and I'm trying to build reddit clone. I'm trying to render nav bar with ransack search bar on every page and it works fine for the index page; but I'm getting errors when I cl...
Kristina Dzelebdzic
Votes: 0
Answers: 1
RubyOnRails how to create form for ransacker method with arguments?
I have a custom ransacker method called score
ransacker :score, args: [:parent, :number_one :number_two] do |parent, args|
(parent.table[:id] + parent.table[:id]) / (number_one + number_two)
en...
Ratnaraj Sukale
Votes: 0
Answers: 0
RubyOnRails Custom SQL Query in Ransack gem Advanced Forms
Click on image to see view
Ransack generated following query SELECT "sheets".* FROM "sheets" WHERE ("sheets"."id" > 5)
but I want to implement formula in que...
Ratnaraj Sukale
Votes: 0
Answers: 2
How to order users by the number of user's posts in a particular category
I have 3 models,
User (has_many :posts)
Post (Belongs_to :user, has_many :categories through: :posts_categories)
Category (has_many :posts through: :posts_categories)
Now, I want to find and order a...
HighOnRails
Votes: 0
Answers: 0