chat-space

Stars
0

README

This README would normally document whatever steps are necessary to get the application up and running.

Things you may want to cover:

  • Ruby version rails 5.0.7.2 new DataBaseDesignSample -d mysql

  • System dependencies

  • Configuration

  • Database creation

usersテーブル

Column Type Options
name string null: false, unique: true
email string null: false, unique: true

Association

  • has_many :groups, through: :groups_users
  • has_many :groups_users
  • has_many :tweets

groups_usersテーブル

Column Type Options
user_id integer null: false, foreign_key: true
group_id integer null: false, foreign_key: true

Association

  • belongs_to :group
  • belongs_to :user

groupsテーブル

Column Type Options
name string null: false, unique: true

Association

  • has_many :users, through: :groups_users
  • has_many :groups_users
  • has_many :tweets

messagesテーブル

Column Type Options
user_id integer null: false, foreign_key: true
group_id integer null: false, foreign_key: true
content string
image string

Association

  • belongs_to :group
  • belongs_to :user
  • Database initialization

  • How to run the test suite

  • Services (job queues, cache servers, search engines, etc.)

  • Deployment instructions

  • ...