Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- create_table "addresses", force: :cascade do |t|
- t.bigint "user_id"
- t.bigint "city_id"
- t.bigint "province_id"
- t.bigint "subdistrict_id"
- t.string "slug"
- t.string "name"
- t.string "lat"
- t.string "lon"
- t.string "address"
- t.string "phone"
- t.datetime "created_at", null: false
- t.datetime "updated_at", null: false
- t.index ["city_id"], name: "index_addresses_on_city_id"
- t.index ["province_id"], name: "index_addresses_on_province_id"
- t.index ["slug"], name: "index_addresses_on_slug"
- t.index ["subdistrict_id"], name: "index_addresses_on_subdistrict_id"
- t.index ["user_id"], name: "index_addresses_on_user_id"
- end
- create_table "admins", force: :cascade do |t|
- t.string "email", default: "", null: false
- t.string "encrypted_password", default: "", null: false
- t.string "name"
- t.string "status"
- t.string "role"
- t.string "auth_token"
- t.string "firebase_token"
- t.string "slug"
- t.string "phone"
- t.integer "level", default: 0
- t.string "photo"
- t.text "jwt"
- t.string "reset_password_token"
- t.datetime "reset_password_sent_at"
- t.datetime "remember_created_at"
- t.integer "sign_in_count", default: 0, null: false
- t.datetime "current_sign_in_at"
- t.datetime "last_sign_in_at"
- t.string "current_sign_in_ip"
- t.string "last_sign_in_ip"
- t.datetime "created_at", null: false
- t.datetime "updated_at", null: false
- t.index ["auth_token"], name: "index_admins_on_auth_token", unique: true
- t.index ["email"], name: "index_admins_on_email", unique: true
- t.index ["firebase_token"], name: "index_admins_on_firebase_token", unique: true
- t.index ["reset_password_token"], name: "index_admins_on_reset_password_token", unique: true
- t.index ["slug"], name: "index_admins_on_slug", unique: true
- end
- create_table "cart_items", force: :cascade do |t|
- t.bigint "cart_id"
- t.bigint "product_id"
- t.float "price"
- t.float "base_price"
- t.integer "amount"
- t.float "subtotal"
- t.float "base_subtotal"
- t.datetime "created_at", null: false
- t.datetime "updated_at", null: false
- t.index ["cart_id"], name: "index_cart_items_on_cart_id"
- t.index ["product_id"], name: "index_cart_items_on_product_id"
- end
- create_table "carts", force: :cascade do |t|
- t.bigint "user_id"
- t.bigint "admin_id"
- t.string "slug"
- t.float "total"
- t.string "status"
- t.string "trx_id"
- t.string "payment_date"
- t.string "payment_status"
- t.string "payment_status_desc"
- t.string "payment_receipt"
- t.string "payment_channel_code"
- t.string "payment_channel_name"
- t.datetime "created_at", null: false
- t.datetime "updated_at", null: false
- t.index ["admin_id"], name: "index_carts_on_admin_id"
- t.index ["slug"], name: "index_carts_on_slug"
- t.index ["user_id"], name: "index_carts_on_user_id"
- end
- create_table "cities", force: :cascade do |t|
- t.bigint "province_id"
- t.string "name"
- t.string "tipe"
- t.string "postal_code"
- t.index ["province_id"], name: "index_cities_on_province_id"
- end
- create_table "currencies", force: :cascade do |t|
- t.string "name"
- t.string "slug"
- t.float "rate"
- t.boolean "base"
- t.string "roundup"
- t.datetime "created_at", null: false
- t.datetime "updated_at", null: false
- t.index ["slug"], name: "index_currencies_on_slug"
- end
- create_table "faspay_channels", force: :cascade do |t|
- t.string "name"
- t.string "code"
- t.string "icon"
- t.boolean "active"
- t.datetime "created_at", null: false
- t.datetime "updated_at", null: false
- end
- create_table "offices", force: :cascade do |t|
- t.bigint "city_id"
- t.bigint "province_id"
- t.bigint "subdistrict_id"
- t.string "slug"
- t.string "name"
- t.string "lat"
- t.string "lon"
- t.string "photo"
- t.string "address"
- t.datetime "created_at", null: false
- t.datetime "updated_at", null: false
- t.index ["city_id"], name: "index_offices_on_city_id"
- t.index ["province_id"], name: "index_offices_on_province_id"
- t.index ["slug"], name: "index_offices_on_slug"
- t.index ["subdistrict_id"], name: "index_offices_on_subdistrict_id"
- end
- create_table "photos", force: :cascade do |t|
- t.bigint "product_id"
- t.string "pict"
- t.datetime "created_at", null: false
- t.datetime "updated_at", null: false
- t.index ["product_id"], name: "index_photos_on_product_id"
- end
- create_table "products", force: :cascade do |t|
- t.bigint "office_id"
- t.string "slug"
- t.string "code"
- t.string "name"
- t.string "status"
- t.string "photo"
- t.text "description"
- t.datetime "created_at", null: false
- t.datetime "updated_at", null: false
- t.index ["office_id"], name: "index_products_on_office_id"
- t.index ["slug"], name: "index_products_on_slug"
- end
- create_table "provinces", force: :cascade do |t|
- t.string "name"
- end
- create_table "roots", force: :cascade do |t|
- t.string "email", default: "", null: false
- t.string "encrypted_password", default: "", null: false
- t.string "name"
- t.string "auth_token"
- t.string "firebase_token"
- t.index ["auth_token"], name: "index_roots_on_auth_token", unique: true
- t.index ["email"], name: "index_roots_on_email", unique: true
- t.index ["firebase_token"], name: "index_roots_on_firebase_token", unique: true
- end
- create_table "shipments", force: :cascade do |t|
- t.bigint "admin_id"
- t.bigint "user_id"
- t.bigint "cart_id"
- t.bigint "office_id"
- t.bigint "address_id"
- t.string "slug"
- t.string "pickup_hotel"
- t.string "pickup_lat"
- t.string "pickup_lon"
- t.string "pickup_room"
- t.string "delivery_name"
- t.string "delivered_phone"
- t.string "delivered_address"
- t.string "status"
- t.string "resi_number"
- t.string "note"
- t.datetime "created_at", null: false
- t.datetime "updated_at", null: false
- t.index ["address_id"], name: "index_shipments_on_address_id"
- t.index ["admin_id"], name: "index_shipments_on_admin_id"
- t.index ["cart_id"], name: "index_shipments_on_cart_id"
- t.index ["office_id"], name: "index_shipments_on_office_id"
- t.index ["slug"], name: "index_shipments_on_slug"
- t.index ["user_id"], name: "index_shipments_on_user_id"
- end
- create_table "subdistricts", force: :cascade do |t|
- t.bigint "city_id"
- t.bigint "province_id"
- t.string "name"
- t.index ["city_id"], name: "index_subdistricts_on_city_id"
- t.index ["province_id"], name: "index_subdistricts_on_province_id"
- end
- create_table "users", force: :cascade do |t|
- t.string "email", default: "", null: false
- t.string "encrypted_password", default: "", null: false
- t.string "name"
- t.string "slug"
- t.string "status", default: "ACTIVE"
- t.string "phone"
- t.string "auth_token"
- t.string "firebase_token"
- t.string "photo"
- t.string "jwt"
- t.boolean "optin_email"
- t.string "reset_password_token"
- t.datetime "reset_password_sent_at"
- t.datetime "remember_created_at"
- t.integer "sign_in_count", default: 0, null: false
- t.datetime "current_sign_in_at"
- t.datetime "last_sign_in_at"
- t.string "current_sign_in_ip"
- t.string "last_sign_in_ip"
- t.datetime "created_at", null: false
- t.datetime "updated_at", null: false
- t.index ["email"], name: "index_users_on_email", unique: true
- t.index ["phone"], name: "index_users_on_phone", unique: true
- t.index ["reset_password_token"], name: "index_users_on_reset_password_token", unique: true
- t.index ["slug"], name: "index_users_on_slug"
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement