shop

Tables (25)

tbl_about_us

  • about_us_id — BIGINT — Primary key
  • title — VARCHAR(255) — NOT NULL
  • content — TEXT — NOT NULL
  • image_url — VARCHAR(500)
  • video_url — VARCHAR(500)
  • display_order — INT
  • first_create_id — BIGINT
  • first_create_at — DATETIME
  • last_update_id — BIGINT
  • last_update_at — DATETIME
  • is_deleted — BOOLEAN
  • is_enabled — BOOLEAN

tbl_attribute

  • attribute_id — BIGINT — Primary key
  • name — VARCHAR(100) — NOT NULL
  • input_type — VARCHAR(50) — NOT NULL
  • first_create_id — BIGINT
  • first_create_at — DATETIME
  • last_update_id — BIGINT
  • last_update_at — DATETIME
  • is_deleted — BOOLEAN
  • is_enabled — BOOLEAN

tbl_attribute_value

  • attribute_value_id — BIGINT — Primary key
  • product_id — BIGINT — Foreign key → tbl_product.product_id
  • attribute_id — BIGINT — Foreign key → tbl_attribute.attribute_id — NOT NULL
  • value — VARCHAR(255) — NOT NULL
  • first_create_id — BIGINT
  • first_create_at — DATETIME
  • last_update_id — BIGINT
  • last_update_at — DATETIME
  • is_deleted — BOOLEAN
  • is_enabled — BOOLEAN

tbl_brand

  • brand_id — BIGINT — Primary key
  • name — VARCHAR(255) — NOT NULL
  • logo_url — VARCHAR(255)
  • country — VARCHAR(100)
  • description — TEXT
  • first_create_id — BIGINT
  • first_create_at — DATETIME
  • last_update_id — BIGINT
  • last_update_at — DATETIME
  • is_deleted — BOOLEAN
  • is_enabled — BOOLEAN

tbl_cart

  • cart_id — BIGINT — Primary key
  • user_id — BIGINT — NOT NULL
  • created_at — DATETIME
  • updated_at — DATETIME
  • first_create_id — BIGINT
  • first_create_at — DATETIME
  • last_update_id — BIGINT
  • last_update_at — DATETIME
  • is_deleted — BOOLEAN
  • is_enabled — BOOLEAN

tbl_cart_item

  • cart_item_id — BIGINT — Primary key
  • cart_id — BIGINT — Foreign key → tbl_cart.cart_id — NOT NULL
  • product_variant_id — BIGINT — Foreign key → tbl_product_variant.product_variant_id — NOT NULL
  • quantity — BIGINT — NOT NULL
  • created_at — DATETIME
  • updated_at — DATETIME
  • first_create_id — BIGINT
  • first_create_at — DATETIME
  • last_update_id — BIGINT
  • last_update_at — DATETIME
  • is_deleted — BOOLEAN
  • is_enabled — BOOLEAN
  • shop_id (shop_id2) — BIGINT — Foreign key
  • brand_id (brand_id2) — BIGINT — Foreign key
  • product_id (product_id2) — BIGINT — Foreign key
  • product_variant_id (product_variant_id2) — BIGINT — Foreign key → tbl_product_variant.product_variant_id
  • cart_id (cart_id2) — BIGINT — Foreign key → tbl_cart.cart_id

tbl_contact_info

  • contact_info_id — BIGINT — Primary key
  • shop_name — VARCHAR(255)
  • email — VARCHAR(255)
  • phone_number — VARCHAR(50)
  • address — VARCHAR(500)
  • working_hours — VARCHAR(255)
  • facebook_url — VARCHAR(500)
  • instagram_url — VARCHAR(500)
  • tiktok_url — VARCHAR(500)
  • map_embed_url — TEXT
  • additional_note — TEXT
  • first_create_id — BIGINT
  • first_create_at — DATETIME
  • last_update_id — BIGINT
  • last_update_at — DATETIME
  • is_deleted — BOOLEAN
  • is_enabled — BOOLEAN

tbl_contact_message

  • contact_message_id — BIGINT — Primary key
  • full_name — VARCHAR(255) — NOT NULL
  • email_address — VARCHAR(255) — NOT NULL
  • contact_category_id — BIGINT — NOT NULL
  • subject — VARCHAR(255)
  • message — TEXT — NOT NULL
  • first_create_id — BIGINT
  • first_create_at — DATETIME
  • last_update_id — BIGINT
  • last_update_at — DATETIME
  • is_deleted — BOOLEAN
  • is_enabled — BOOLEAN

tbl_faq

  • faq_id — BIGINT — Primary key
  • faq_category_id — BIGINT — NOT NULL
  • question — VARCHAR(500) — NOT NULL
  • answer — TEXT — NOT NULL
  • display_order — INT
  • first_create_id — BIGINT
  • first_create_at — DATETIME
  • last_update_id — BIGINT
  • last_update_at — DATETIME
  • is_deleted — BOOLEAN
  • is_enabled — BOOLEAN

tbl_order

  • order_id — BIGINT — Primary key
  • user_id — BIGINT — NOT NULL
  • total_amount — DECIMAL(10, 2) — NOT NULL
  • order_status_id — BIGINT — NOT NULL
  • payment_method — VARCHAR(50)
  • shipping_address — TEXT
  • billing_address — TEXT
  • note — TEXT
  • ordered_at — DATETIME
  • first_create_id — BIGINT
  • first_create_at — DATETIME
  • last_update_id — BIGINT
  • last_update_at — DATETIME
  • is_deleted — BOOLEAN
  • is_enabled — BOOLEAN

tbl_order_item

  • order_item_id — BIGINT — Primary key
  • order_id — BIGINT — Foreign key → tbl_order.order_id — NOT NULL
  • product_variant_id — BIGINT — Foreign key → tbl_product_variant.product_variant_id — NOT NULL
  • product_id — BIGINT — Foreign key → tbl_product.product_id — NOT NULL
  • product_name — VARCHAR(255) — NOT NULL
  • variant_name — VARCHAR(255)
  • variant_attributes — TEXT
  • image_url — VARCHAR(255)
  • price — DECIMAL(10, 2) — NOT NULL
  • sale_price — DECIMAL(10, 2)
  • quantity — BIGINT — NOT NULL
  • total — DECIMAL(10, 2) — NOT NULL
  • first_create_id — BIGINT
  • first_create_at — DATETIME
  • last_update_id — BIGINT
  • last_update_at — DATETIME
  • is_deleted — BOOLEAN
  • is_enabled — BOOLEAN

tbl_payment_detail

  • payment_detail_id — BIGINT — Primary key
  • order_id — BIGINT — Foreign key → tbl_order.order_id — NOT NULL
  • payment_method_id — BIGINT — Foreign key → tbl_payment_method.payment_method_id — NOT NULL
  • payment_reference_code — VARCHAR(100)
  • paid_amount — DECIMAL(10, 2) — NOT NULL
  • paid_at — DATETIME
  • status — VARCHAR(50)
  • note — TEXT
  • first_create_id — BIGINT
  • first_create_at — DATETIME
  • last_update_id — BIGINT
  • last_update_at — DATETIME
  • is_deleted — BOOLEAN
  • is_enabled — BOOLEAN
  • order_id (order_id2) — BIGINT — Foreign key → tbl_order.order_id
  • payment_method_id (payment_method_id2) — BIGINT — Foreign key → tbl_payment_method.payment_method_id

tbl_payment_method

  • payment_method_id — BIGINT — Primary key
  • code — VARCHAR(50) — NOT NULL
  • name — VARCHAR(100) — NOT NULL
  • description — TEXT
  • first_create_id — BIGINT
  • first_create_at — DATETIME
  • last_update_id — BIGINT
  • last_update_at — DATETIME
  • is_deleted — BOOLEAN
  • is_enabled — BOOLEAN

tbl_product

  • product_id — BIGINT — Primary key
  • shop_id — BIGINT — Foreign key → tbl_shop.shop_id — NOT NULL
  • category_id — BIGINT — NOT NULL
  • brand_id — BIGINT — Foreign key → tbl_brand.brand_id
  • name — VARCHAR(255) — NOT NULL
  • slug — VARCHAR(255) — NOT NULL
  • description — TEXT
  • material — VARCHAR(100)
  • gender — VARCHAR(20)
  • first_create_id — BIGINT
  • first_create_at — DATETIME
  • last_update_id — BIGINT
  • last_update_at — DATETIME
  • is_deleted — BOOLEAN
  • is_enabled — BOOLEAN

tbl_product_image

  • product_image_id — BIGINT — Primary key
  • product_id — BIGINT — Foreign key → tbl_product.product_id — NOT NULL
  • image_url — VARCHAR(255) — NOT NULL
  • alt_text — VARCHAR(255)
  • is_thumbnail — BOOLEAN
  • first_create_id — BIGINT
  • first_create_at — DATETIME
  • last_update_id — BIGINT
  • last_update_at — DATETIME
  • is_deleted — BOOLEAN
  • is_enabled — BOOLEAN
  • shop_id (shop_id2) — BIGINT — Foreign key
  • brand_id (brand_id2) — BIGINT — Foreign key
  • product_id (product_id2) — BIGINT — Foreign key → tbl_product.product_id

tbl_product_review

  • review_id — BIGINT — Primary key
  • product_id — BIGINT — Foreign key → tbl_product.product_id — NOT NULL
  • user_id — BIGINT — NOT NULL
  • order_id — BIGINT — Foreign key → tbl_order.order_id — NOT NULL
  • order_order_id — BIGINT — Foreign key → tbl_order_item.order_item_id — NOT NULL
  • title — VARCHAR(255)
  • content — TEXT
  • rating — INT
  • first_create_id — BIGINT
  • first_create_at — DATETIME
  • last_update_id — BIGINT
  • last_update_at — DATETIME
  • is_deleted — BOOLEAN
  • is_enabled — BOOLEAN
  • shop_id (shop_id2) — BIGINT — Foreign key
  • brand_id (brand_id2) — BIGINT — Foreign key
  • product_id (product_id2) — BIGINT — Foreign key → tbl_product.product_id
  • product_variant_id (product_variant_id2) — BIGINT — Foreign key
  • order_id (order_id2) — BIGINT — Foreign key → tbl_order.order_id
  • order_item_id — BIGINT — Foreign key → tbl_order_item.order_item_id

tbl_product_variant

  • product_variant_id — BIGINT — Primary key
  • product_id — BIGINT — Foreign key → tbl_product.product_id — NOT NULL
  • sku — VARCHAR(100) — NOT NULL
  • quantity — BIGINT
  • price — DECIMAL(10, 2) — NOT NULL
  • sale_price — DECIMAL(10, 2)
  • image_url — VARCHAR(255)
  • first_create_id — BIGINT
  • first_create_at — DATETIME
  • last_update_id — BIGINT
  • last_update_at — DATETIME
  • is_deleted — BOOLEAN
  • is_enabled — BOOLEAN

tbl_role_b

  • role_id — VARCHAR(255) — Primary key — NOT NULL
  • role_name — VARCHAR(255)
  • first_create_id — INT
  • first_create_at — DATETIME
  • last_update_id — INT
  • last_update_at — DATETIME

tbl_shop

  • shop_id — BIGINT — Primary key
  • owner_user_id — BIGINT — NOT NULL
  • name — VARCHAR(255) — NOT NULL
  • slug — VARCHAR(255) — NOT NULL
  • description — TEXT
  • logo_url — VARCHAR(255)
  • banner_url — VARCHAR(255)
  • address — VARCHAR(500)
  • phone_number — VARCHAR(50)
  • email — VARCHAR(255)
  • rating — DECIMAL(2, 1)
  • total_reviews — INT
  • first_create_id — BIGINT
  • first_create_at — DATETIME
  • last_update_id — BIGINT
  • last_update_at — DATETIME
  • is_deleted — BOOLEAN
  • is_enabled — BOOLEAN

tbl_shop_review

  • shop_review_id — BIGINT — Primary key
  • shop_id — BIGINT — Foreign key → tbl_shop.shop_id — NOT NULL
  • user_id — BIGINT — NOT NULL
  • order_id — BIGINT — Foreign key → tbl_order.order_id
  • title — VARCHAR(255)
  • content — TEXT
  • rating — INT
  • first_create_id — BIGINT
  • first_create_at — DATETIME
  • last_update_id — BIGINT
  • last_update_at — DATETIME
  • is_deleted — BOOLEAN
  • is_enabled — BOOLEAN
  • shop_id (shop_id2) — BIGINT — Foreign key → tbl_shop.shop_id
  • order_id (order_id2) — BIGINT — Foreign key → tbl_order.order_id

tbl_user_b

  • id — BIGINT — Primary key — NOT NULL
  • first_name — VARCHAR(255)
  • last_name — VARCHAR(255)
  • email — VARCHAR(255)
  • phone_number — VARCHAR(255)
  • password — VARCHAR(255)
  • email_notification (Field) — BOOLEAN
  • sms_notifications (Field2) — BOOLEAN
  • newsletter (Field3) — BOOLEAN
  • is_deleted — BOOLEAN — NOT NULL
  • is_enabled — BOOLEAN — NOT NULL
  • first_create_id — INT
  • first_create_at — DATETIME
  • last_update_id — INT
  • last_update_at — DATETIME
  • shop_status (Field4)

tbl_user_role

  • user_id — BIGINT — Foreign key → tbl_user_b.id — NOT NULL
  • role_id — VARCHAR(255) — Foreign key → tbl_role_b.role_id — NOT NULL

tbl_wishlist_item

  • wishlist_id — BIGINT — Primary key
  • user_id — BIGINT — NOT NULL
  • product_id — BIGINT — Foreign key → tbl_product.product_id — NOT NULL
  • product_variant_id — BIGINT — Foreign key → tbl_product_variant.product_variant_id
  • first_create_id — BIGINT
  • first_create_at — DATETIME
  • last_update_id — BIGINT
  • last_update_at — DATETIME
  • is_deleted — BOOLEAN
  • is_enabled — BOOLEAN
  • shop_id (shop_id2) — BIGINT — Foreign key
  • brand_id (brand_id2) — BIGINT — Foreign key
  • product_id (product_id2) — BIGINT — Foreign key → tbl_product.product_id
  • product_variant_id (product_variant_id2) — BIGINT — Foreign key → tbl_product_variant.product_variant_id

varian_value (Untitled)

  • varian_value_id (Field) — BIGINT — Primary key
  • variant_id (Field5) — BIGINT — Foreign key → variant.variant_id
  • name (Field2) — VARCHAR
  • image (Field3) — VARCHAR
  • is_deleted (Field4) — BOOLEAN

variant (Untitled2)

  • variant_id (Field) — BIGINT — Primary key
  • name (Field2) — VARCHAR
  • is_deleted (Field3) — BOOLEAN