Ruby on Rails Community Forum

Issues with paperclip gem on Windows 8

2
Rails
Hi, i am new to rails(**using Windows 8, rails v = 5.1.4 & ruby v= 2.2.6**) and i am having issues with image uploading using paperclip gem, i saw the documentation on github & manually ins...
Pranay Singh replied

Having trouble figuring out net/http and API calls.

3
Rails
Hi folks, I need to make a number of calls to an API, some of which are GET requests and some of which are PUT requests. I've tried to make a common function since there's a bunch of security stuf...
Jacob Montgomery replied

Should scopes be seperated out to allow chaining or be specific to the what you are trying to do?

4
Rails
I am trying to write an internal tender application and am having trouble figuring out the best approach for writing a scope. I have the following models ``` class Tender < ApplicationRecord ...
Jacob Montgomery replied

Architecture for subscription with multiple users per account

1
Rails
Hi all! I developed an app that uses Apartment for multitenancy, Devise for authentication and Pundit for auth. Each tenant is represented by a business (business model), where the id is also the ...
Luca Rossi replied

Are there any episodes or series on CMS related gems ?

5
General
Hi, I have to build CMS for one of my clients. I would like to know your suggestions also please let me know if we have any related videos here. Thanks, Pardha
Matt Walston replied

Is it safe to switch Apartment tenant using session variable to pass the tenant id?

2
Rails
Hello, I know that Rails uses a digest to secure session data, however I wanted to ask whether a better solution could be adopted. I am currently loading the tenant in apartment.rb using a tenant...
Luca Rossi replied

Form not working for polymorphic has_many through association

1
Rails
In my Rails 5.1 app I am trying to create a tagging system from scratch. I have been using the *Comments with Polymorphic Associations* episode as a template. I want `Tags` to be a polymorphic `ha...
Casey Provost replied

How to read database table in Application.rb

0
Rails
I am adding CORS validation in application.rb filw where domain names are given in Environment variable but I want to keep all domain in database table and validate these domain during CORS valid...
Puneet Gaur posted

Rails mongoid connection to remote cluster

0
Rails
I am trying to make a rails 4 application with mongodb (skipping active record). I created a cluster on https://cloud.mongodb.com, which has three hosts. The cluster is accessible in the Mongo Shel...
sommer bareen posted

Hiring Part Time Rails Devs

2
General
Hey guys, I got a bunch of projects coming through the pipes in the next 6 months, and will need part time Rails help, with a focus on ecommerce. Can anyone who is interested send me through a bri...
Andrew Scott replied

How do I create a virtual balance model in Rails?

10
Rails
This is for a game application I'm creating. I have a user model, a stock model and a UserStock join table for the previous two models. User was created with devise. I intend to attach a certain ba...
inopinatus replied

Checking for uniqueness

3
Rails
Hi people. I am working on a project that deals with enrollment activities such as generation of subject offerings and such. I have a model called Offering which has a has_many relationship with th...
Ohad Dahan replied

How do I duplicate or move a carrierwave image that's stored on S3?

0
Rails
Media page for controller: User can upload an image. User can also create a folder. I want the user to have the choice to either move or copy the uploaded image into the folder. I've looked around...
Josh Zandman posted

Episodes on Chef and Capistrano ?

1
General
Is there any videos on using Chef and Capistrano to deploy and manage our Rails applications ? Thanks -
jaems replied

How do I design a multi-tenacy Data Model for a ROR Whitelabel App

1
General
Hey Rails community, I am at a bit of an impasse. I'm new to ROR. I have been working on an ideal for a white label App utilizing metaprogramming. I started to design the data model and have been ...
Jacob Montgomery replied

Companies / Employees / Products

1
Rails
Hi GoRails friends, I have a list of products. Products can be created by users. So far so good. Now, I would like to allow some users to be part of companies (0, 1 or several). One user (the a...
Casey Provost replied

Using migrations to migrate data from one table into another

0
Rails
I have two models user and account linked with each other as following ``` account.rb belongs_to :user user.rb has_many :accounts ``` I want to move the data from column ```name ``` in ```users`...
Shairyar Baig posted

Error message is displayed One to one relationship with Ruby on Rails

1
Rails
Hi Everone, i am trying to create one to one relationship with ruby on rails5. 1. I ahve created the Dubject model in the below format class Subject < ApplicationRecord has_one :page ...
Jacob Montgomery replied

Install a custom loader with webpacker gem

0
Javascript
I am trying to use a Vue.js based material design framework called [Vuetify](https://vuetifyjs.com/) with Rails 5 and the webpacker gem. The styles for this framework are created with the [Stylus](...
Abhinav Mathur posted

Nested has many through... Or is there a better way?

0
Rails
Hi I have 2 models Tender and Group shown below. For a Tender you can add Contractors (contractor_details) and you can also add Groups (groups). Groups also contain contractor_details. This is so...
Stephen Sizer posted

Learning Ruby on Rails? Join our newsletter.

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