Sha256: caaed782a4317341db2765099c838e0d38cebc88f281a9ce40b257c42e0da9e7
Contents?: true
Size: 770 Bytes
Versions: 6
Compression:
Stored size: 770 Bytes
Contents
# null: false => de-facto db-level validation class TheCommentsChangeUser < ActiveRecord::Migration def change change_table :users do |t| # "Written by me" (cache counters) t.integer :my_draft_comments_count, default: 0 t.integer :my_published_comments_count, default: 0 t.integer :my_comments_count, default: 0 # my_draft_comments_count + my_published_comments_count # commentable's comments => comcoms (cache counters) # Relation through Comment#holder_id field t.integer :draft_comcoms_count, default: 0 t.integer :published_comcoms_count, default: 0 t.integer :deleted_comcoms_count, default: 0 t.integer :spam_comcoms_count, default: 0 end end end
Version data entries
6 entries across 6 versions & 3 rubygems