Skip to main content

All Questions

Filter by
Sorted by
Tagged with
4 votes
2 answers
152 views

Ruby CLI TicTacToe

I have done Tictactoe game in Ruby. It is my first Object Oriented project in Ruby. I would like to separate all program into a few classes such as Player Board and Game. I want to use more OOP best ...
theplaceofburak's user avatar
1 vote
2 answers
274 views

Refactoring Ruby recharge REST API wrapper by using class variables

I am trying to create an API wrapper for recharge (A Shopify subscription service), I am using the HTTParty gem ...
Artyrcheek's user avatar
2 votes
2 answers
219 views

Modelling football teams and fixtures in Ruby (as compared to SQL)

I am trying to model information around football teams and fixtures. I am using the Premier League fantasy football API for my data. The fixtures API is here, and the team data (along with a lot of ...
WelshGandalf's user avatar
1 vote
1 answer
720 views

Creating an associated object on create/update

My app is setup where there are musical artists and albums have message boards through a has_one polymorphic association. ...
Carl Edwards's user avatar
3 votes
1 answer
81 views

Ensure multiple steps work/saving multiple models via a service

I just thought of something new re: saving multiple objects in Rails (though Rails is not necessary). Objectives: Create an author and a tomato, but both of those must be valid. If invalid creation, ...
Daryll Santos's user avatar
1 vote
1 answer
60 views

Old and new shouts controllers

I have a photo_shouts_controller.rb and text_shouts_controller.rb which both have almost similar implementations, and I would like to refactor it. I have implemented a refactoring but I am not too ...
Saad's user avatar
  • 111
3 votes
1 answer
66 views

Classes for attributes validation

I have two classes responsible for attributes validation: ...
just so's user avatar
  • 237
2 votes
1 answer
91 views

Content management system for media

I have a content management system for an iOS app built with Rails. Right now there are three different types of content. The first two are just strings uploaded into a textfield by the user. One is ...
Ryan Collins's user avatar
4 votes
1 answer
7k views

Searching over more models rails

I'm trying to implement search over two models. In this example Book and Article. Here are the attributes from both of these : <...
Gandalf StormCrow's user avatar
2 votes
1 answer
199 views

Duplicating Rails model for a form with meta-programming

Can someone please review my code: ...
Arthur Corenzan's user avatar