4 Matching Annotations
  1. Feb 2021
    1. So how are we going to create a model that doesn’t have a database table behind it? There are several potential solutions including various plugins but we’re going to use the method described in an entry on the Code Tunes blog. This shows a techinque that involves overriding a couple of methods in an ActiveRecord model and then manually defining the columns in the model file rather than in the database table. In our Recommendation model we’ll add in the two overridden methods and then use the column class method to define the columns in a similar way to how they’re defined in a migration file.

      Does this still work in Rails 6? I wonder.

  2. Jan 2021
  3. Oct 2020
  4. Feb 2019