Save 36% for Black Friday! Learn more

Rails Ruby on Rails Forum

Few Big Models or Many Smaller Namspaced models?

6
Rails
Anyone able to give suggestions on model design? I'm building an app to help small businesses get more reviews across the web. Concept is simple, user registers a business, and their businesses...
Rich Smith replied
Solved

How do I ask people to complete profile before continuing?

0
Rails
I have an app with Devise Users and they can sign up. Once they are signed in I want them to complete there profile before they can use the app.Anyone done this? and whats the best way to go about ...
Stephen Sizer posted

Is the adoption of Ruby on Rails in decline? Proving it wrong with Pagy

0
Rails
Did Ruby on Rails reach its full potential in 2015? Is the adoption of the platform in decline? As the numbers decline, let me show why Pagy matters. You can read everything about it at the followi...
Sandro Cantante posted

How do I transfer user data on delete

5
Rails
I have a rails app with company users using devise. I want to be able to delete users and select an employee to transfer the foreign keys to.Hope that makes sense? Thanks in advance
William Kennedy replied
Solved

Can anyone see the error here?

3
Rails
NameError in RecipesController#newuninitialized constant RecipesController::Categorydef new @recipe = current_user.recipes.build @categories = Category.all.map{ |c| [c.name, c.id] } <-...
Jacob Montgomery replied

Getting Simple Calendar to show local date and time

5
Rails
I have been using your Simple Calendar gem and it is all working great. The only problem is I can not figure out how to fix the date and time so it will show everything in local date and time. Righ...
Antonio Santoni replied

Enable HTTPS SSL in rails localhost

4
Rails
Good day, i tried to enable https secure connection for my rails application.First of all, set config.force_ssl = true in application.rb only. So, re-started rails server, but there was error: &quo...
Bilal Abbas replied

Encrypted Credentials in Rails 5.2 with Cloud9

0
Rails
Does anyone know what the [ EDITOR="cloud9 --wait" ] code is for Cloud9 so that I can edit the credentials?
Ryan Carter posted

REACT on RAILS - issue with data loading

0
Rails
I am having an issue with data loading after I add a favorite from a search page. It seems that I need to had some kind of fetch to the addFavorite function, so it knows I need to get the updated f...
ME Hoagland posted

Update an attribute on belongs_to

3
Rails
Hi all,I have my products and groups set up like so...class Product < ApplicationRecord has_many :product_groups has_many :groups, through: :product_groups endclass Group < ApplicationRec...
Alan Reid replied
Solved

Best practices for self-referential habtm setup?

1
Rails
Basic concept:Patch collecting app. There are issuing entities in the system that issue patches. That model is "issues". In many cases, these are difficult to tell apart. So I want to add...
John Athayde replied

What's the state of the art for API authentication?

0
Rails
What are the current community approved standards? JWT? Devise Tokens? What's best practices?
Ketan Anjaria posted

Attach image to summernote and send email

0
Rails
I recently implement email in my rails app. I'm using summernote to create email templates and save it. Everything works fine. I can upload image to the editor and save it to database. But when...
Lee Terng Gio posted

Form errors not displaying

3
Rails
In my model for users I am validating the presence of a number of attributes using:validates_presence_of :parent_1_first_name, :parent_1_last_name...The beginning of my form object looks like this:...
Chris Oliver replied
Solved

I18n access ".title" key with view context in layout

1
Rails
Hi!I try to create a small view helper to manage content for `<title>`.module ApplicationHelper def page_title(options = {}) app_name = Rails.application.class.to_s.split("::"...
Nicolas Brousse replied

How do I preselect a reference to a resource that is not a parent in the routes?

1
Rails
I have an app with a ContentCategory model that has_many :contents.  In the ContentCategoriesController#show view there is a button for "New Content".  This goes to the Contents...
Jacob Montgomery replied

Having some problems with Using certain data from API calls

1
Rails
Hi i've been struggling for a while now trying to grasp how to use the data received in an api call. A lot of tutorials are either outdated or focus solely on creating API's rather than usi...
kaine Wright replied

Use Devise for two different application in separate machines

0
Rails
hi,I am trying to have my devise database be used by two or more separate rails application. I have pointed my sub-application to use the main application devise database.however, when i log i...
ang nickolas posted

How do i create a version carrierwave depending of file extention

2
Rails
Hi,I trying to upload files with Carrierwave in my Rails app, files could be jpg, png, pdf or docx. Files jpg and png upload fine but pdf or docx don't, i get the error "...Minimagick, may...
Víctor Soto replied

file uploads in nested forms with Vuejs and Rails

0
Rails
Hi all,I have a Projects model which has many files and categories. So on my view, I would have a nested form where user can upload as many files and also associate as many categories when creating...
Aman DeMan posted

Learning Ruby on Rails? Join our newsletter.

We won't send you spam. Unsubscribe at any time.