Ruby on Rails Community Forum
Why is viewer_id 0 on every video?
4
Rails
The viewer_id always returns 0 after creating a video. A mentor creates a video with a user via hangouts. Mentor then creates the video on our website. Only the mentor and viewer should see the vi...
How to order stimulus reflex morph asc?
2
Javascript
I have a morph for stimulus reflex that updates a portion of the page when todos are created. What the customer would like to have happen is that when they create new todos they are added to the bo...
Boolean wont update
0
Rails
I have a column in my users table named `active` that is a boolean that defaults to true.
I cannot seem to update this value at all. Both in the console and through the update method in my users c...
RJ McCollam posted
Sorting Images using Active Storage
25
Rails
I'm experimenting with Active Storage to manage images. I got the multiple uploads working, but I want to use acts_as_list position with jQuery sortable to manage their order using ajax, like in [t...
Tony Serkis replied
Hotwire/Turbo + Webpacker/Stimulusjs
0
General
I think I'm confused. I love the functionality of Hotwire and experimented a little with it in a fresh app. I don't understand though, if I can also have Stimulusjs running - I have different needs...
Bevin posted
Issues with filter with searchkick elastic rails
0
Rails
I am currently on the part where you add
<% if params[:price]==bucket["key"].to_s%>
<%= link_to bucket["key"], request.params.except(:price)%>
<% else %>
<%= link_to bu...
Authorization with Pundit Discussion
28
General
It is really helpful. I've also seen CanCan. But I'm little bit confuse, which one should I use? Do you have any suggestion? Beside this I've a request that it'll be very helpful, if provide a vide...
Liam replied
How to use background job with ActiveAdmin to generate csv
0
Rails
With ActiveAdmin not able to generate CSV file with more records
Mahantesh posted
Stripe - Save Card and Reuse at checkout
0
Rails
I managed to create a customer with cards, but when I create a checkout session, I couldn't manage to bring the card to the form.
Victor Morelli posted
Setup Ubuntu 21.10 Impish Indri Discussion
0
General
HOW TO POPULATE DATA FROM ANOTHER FORM
1
General
How can I populate data from another form, for example when I select 'Request No' should fill 'Request description' or 'Requester' on my form. I know this can be achieved by JavaScript's but i am s...
GDPR and Rails 6
2
Javascript
I am trying to add a GDPR consent javascript to my rails 6 app.
I have found the cookies-eu-banner (https://github.com/Alex-D/Cookies-EU-banner), which should be easy as pie to integrate, but I ju...
Mads Holm Oldfield Nielsen replied
Setup MacOS 11.0 Big Sur Discussion
0
General
Using Pundit and ActiveAdmin
0
Rails
Hello, I'm using pundit with active admin and getting this error message
Pundit::NotDefinedError at /admin
unable to find scope `Admin::AdminUserPolicy::Scope` for `[:admin, AdminUser(id: integer,...
Maksk89 posted
Getting NoMethodError while calling method from Model_name.rb
1
General
I am testing a model class method from 'rails console' called "progress" which is inside class 'Okr' as 'Okr.progess'. But getting NoMethodError (undefined method progress' for Okr (call 'Okr.conne...
Ruby on Rails with Postgresql database
0
Rails
I am new to ROR & Postgresql database. I am trying to create a ROR API Application with Using Existing Database for my development. i want to know how to achieve the same. I referred many sites...
balaganesh posted
How do I search through associations with searchkick (elastic search) together aggregations
0
Rails
Hello folks,
I’m trying to do a search query through an association. Here’s what I have.
I have Property model which has_many :characteristics, as: characteristicable on one side. On the other si...
Owen posted
How do I hide fields based on option selected in dropdown
0
Javascript
I have a standard rails form with 2 fields:
1. Metric type (number, percent, boolean)
2. current metric value
If the metric type is boolean, I want to hide the input for metric value
Is there a ...
How do I dynamically load variables in Liquid templates?
2
General
I'm new to using Liquid templates, but I'm wondering how do I load data dynamically in my controller? The reason is because all the data is stored in my db in different tables, and loading all of t...
delete not working after using webpack
0
Rails
I have a rails 5.2 app, which run in a good way. After I followed the lesson about real-time group chat and used web pack, all the delete methods in my app are not working now. What are the possibl...
yy00809 posted