Promotion CRUD

This commit is contained in:
Phyo
2017-08-16 18:36:23 +06:30
parent 73cceaf482
commit fc2927b341
13 changed files with 225 additions and 2 deletions

View File

@@ -3,8 +3,8 @@ class CreatePromotion < ActiveRecord::Migration[5.1]
create_table :promotions do |t|
t.string :promo_code, :limit => 16
t.datetime :promo_start_date, :null => false
t.datetime :promo_end_date, :null => false
t.date :promo_start_date, :null => false
t.date :promo_end_date, :null => false
t.time :promo_start_hour, :null => false
t.time :promo_end_hour, :null => false
t.string :promo_day, :null => false, :default => "[0,1,2,3,4,5,6]"