smart-lineup

Tables (4)

attendee

  • attendee_id — BIGINT — Primary key — NOT NULL
  • user_id — BIGINT — Foreign key → users.user_id — NOT NULL
  • phone — VARCHAR(20)
  • info — JSON
  • created_at — TIMESTAMP — NOT NULL
  • updated_at — TIMESTAMP — NOT NULL

line

  • line_id — BIGINT — Primary key — NOT NULL
  • user_id — BIGINT — Foreign key → users.user_id — NOT NULL
  • name — VARCHAR(100) — NOT NULL
  • created_at — TIMESTAMP — NOT NULL
  • updated_at — TIMESTAMP — NOT NULL

queue

  • queue_id — BIGINT — Primary key — NOT NULL
  • attendee_id (attendee_id2) — BIGINT — Foreign key → attendee.attendee_id — NOT NULL
  • line_id — BIGINT — Foreign key → line.line_id — NOT NULL
  • user_id — BIGINT — Foreign key → users.user_id — NOT NULL
  • previous_id — BIGINT — Foreign key → queue.queue_id
  • next_id — BIGINT — Foreign key → queue.queue_id
  • status — VARCHAR(20) — NOT NULL
  • created_at — TIMESTAMP — NOT NULL
  • updated_at — TIMESTAMP — NOT NULL

users

  • user_id — BIGINT — Primary key — NOT NULL
  • name — VARCHAR(255)
  • email — VARCHAR(255)
  • picture — VARCHAR(255)
  • role — ENUM('USER', 'ADMIN')
  • password — VARCHAR(50)
  • isOAuthLogin — Boolean
  • isVerified — Boolean
  • verificationToken — VARCHAR(255)
  • created_date — TIMESTAMP
  • updated_date — TIMESTAMP