Base de données

Schéma public de la base werise sur 127.0.0.1. Lu en direct : cette page suit toute évolution du schéma.

admin_werise

9 champs · 2 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('admin_werise_id_seq'::regclass) PK
email text
password text
token text oui
token_expires_at timestamp oui
refresh_token text oui
refresh_token_expires_at timestamp oui
created_at timestamp CURRENT_TIMESTAMP
updated_at timestamp CURRENT_TIMESTAMP
3 index
  • admin_werise_email_key (unique)
  • admin_werise_refresh_token_key (unique)
  • admin_werise_token_key (unique)

article_likes

4 champs · 12 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('article_likes_id_seq'::regclass… PK
articleId integer → articles.id
userProfileId text → user_profiles.id
createdAt timestamp CURRENT_TIMESTAMP
3 index
  • article_likes_articleId_idx
  • article_likes_articleId_userProfileId_key (unique)
  • article_likes_userProfileId_idx

article_photos

4 champs · 91 539 lignes

Champ Type Null Défaut Clé / relation
url text
createdAt timestamp CURRENT_TIMESTAMP
id integer nextval('article_photos_id_seq'::regclas… PK
articleId integer → articles.id
1 index
  • article_photos_articleId_idx

articles

16 champs · 91 533 lignes

Champ Type Null Défaut Clé / relation
name text
price float8
description text oui
is_active boolean true
createdAt timestamp CURRENT_TIMESTAMP
updatedAt timestamp
tradeId integer → trades.id
id integer nextval('articles_id_seq'::regclass) PK
stock integer oui
totalCost float8 oui
remainingStock integer oui
remainingStockValue float8 oui
totalSales float8
totalItemSold integer
deliveryFee integer
payByMobile integer oui
3 index
  • articles_is_active_idx
  • articles_name_idx
  • articles_tradeId_idx

automatisations_werise

10 champs · 6 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('automatisations_werise_id_seq':… PK
cle varchar(64)
libelle varchar(191)
description text oui
actif boolean false
parametres jsonb '{}'
derniere_execution_le timestamp oui
dernier_resume varchar(255) oui
created_at timestamp oui
updated_at timestamp oui
1 index
  • automatisations_werise_cle_unique (unique)

campagne_envois_werise

11 champs · 50 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('campagne_envois_werise_id_seq':… PK
campagne_id integer → campagnes_werise.id
canal varchar(20) 'email'
type_destinataire varchar(20)
user_profile_id varchar(64) oui
trade_id integer oui
destinataire varchar(190)
nom varchar(190) oui
statut varchar(20) 'envoye'
erreur text oui
envoye_le timestamp oui CURRENT_TIMESTAMP
3 index
  • campagne_envois_werise_campagne_idx
  • campagne_envois_werise_envoye_le_idx
  • campagne_envois_werise_file_idx

campagnes_werise

17 champs · 12 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('campagnes_werise_id_seq'::regcl… PK
type varchar(20) 'email'
cible varchar(20) 'les_deux'
objet varchar(190)
message text
planifie_le timestamp oui
statut varchar(20) 'planifiee'
total_destinataires integer
total_envoyes integer
total_echecs integer
demarree_le timestamp oui
terminee_le timestamp oui
erreur text oui
cree_par varchar(190) oui
created_at timestamp oui
updated_at timestamp oui
liste_prete boolean false
1 index
  • campagnes_werise_file_idx

categories

8 champs · 20 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('categories_id_seq'::regclass) PK
name text
deletedAt timestamp oui
createdAt timestamp CURRENT_TIMESTAMP
updatedAt timestamp CURRENT_TIMESTAMP
is_active boolean true
color varchar(255) oui
icon varchar(255) oui
3 index
  • categories_deletedAt_idx
  • categories_is_active_idx
  • categories_name_is_active_idx

commentaires_signales_werise

12 champs · 0 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('commentaires_signales_werise_id… PK
avis_id integer oui
commerce_id integer oui
commerce_nom text oui
utilisateur_id text oui
auteur text oui
note integer oui
commentaire text oui
publie_le timestamp oui
motif text oui
signale_par text
signale_le timestamp CURRENT_TIMESTAMP
2 index
  • commentaires_signales_werise_commerce_idx
  • commentaires_signales_werise_date_idx

conditions_utilisation_werise

6 champs · 1 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('conditions_utilisation_werise_i… PK
version integer
contenu text
publiee boolean false
modifiee_par text oui
creee_le timestamp CURRENT_TIMESTAMP
2 index
  • conditions_utilisation_werise_publiee_idx
  • conditions_utilisation_werise_version_key (unique)

contenu_site_werise

7 champs · 10 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('contenu_site_werise_id_seq'::re… PK
cle varchar(40)
contenu jsonb
actif boolean true
ordre integer
modifie_par text oui
mis_a_jour_le timestamp CURRENT_TIMESTAMP
2 index
  • contenu_site_werise_cle_unique (unique)
  • contenu_site_werise_ordre_idx

deliverer_photos

4 champs · 10 lignes

Champ Type Null Défaut Clé / relation
id text PK
delivererId text → deliverers.id
url varchar(500)
createdAt timestamp CURRENT_TIMESTAMP
1 index
  • deliverer_photos_delivererId_idx

deliverer_schedules

8 champs · 0 lignes

Champ Type Null Défaut Clé / relation
id text PK
delivererId text → deliverers.id
weekday integer
startTime varchar(5)
endTime varchar(5)
isActive boolean true
createdAt timestamp CURRENT_TIMESTAMP
updatedAt timestamp
2 index
  • deliverer_schedules_delivererId_idx
  • deliverer_schedules_delivererId_weekday_startTime_key (unique)

deliverers

22 champs · 2 lignes

Champ Type Null Défaut Clé / relation
id text PK
userProfileId text → user_profiles.id
status DelivererStatus 'EN_COURS_DE_VALIDATION'::"DelivererStat…
rejectionReason varchar(500) oui
validatedAt timestamp oui
vehicleType VehicleType
vehiclePlate varchar(32) oui
idCardFrontUrl varchar(500) oui
idCardBackUrl varchar(500) oui
drivingLicenseUrl varchar(500) oui
vehiclePhotoUrl varchar(500) oui
photoUrl varchar(500) oui
isOnline boolean false
currentLatitude float8 oui
currentLongitude float8 oui
positionUpdatedAt timestamp oui
ratingAvg float8
ratingCount integer
totalDeliveries integer
deletedAt timestamp oui
createdAt timestamp CURRENT_TIMESTAMP
updatedAt timestamp
3 index
  • deliverers_currentLatitude_currentLongitude_idx
  • deliverers_isOnline_status_idx
  • deliverers_userProfileId_key (unique)

deliveries

25 champs · 0 lignes

Champ Type Null Défaut Clé / relation
id text PK
orderId integer → orders.id
delivererId text oui → deliverers.id
status DeliveryStatus
pickupCodeTrade varchar(6)
pickupCodeCourier varchar(6)
dropCodeClient varchar(6)
dropCodeCourier varchar(6)
pickupScannedBy ScanActor oui
dropScannedBy ScanActor oui
pickupPhotoUrl varchar(500) oui
dropPhotoUrl varchar(500) oui
pickupLatitude float8 oui
pickupLongitude float8 oui
dropLatitude float8 oui
dropLongitude float8 oui
fee integer
distanceKm float8 oui
acceptedAt timestamp oui
pickedUpAt timestamp oui
deliveredAt timestamp oui
cancelledAt timestamp oui
failureReason varchar(500) oui
createdAt timestamp CURRENT_TIMESTAMP
updatedAt timestamp
3 index
  • deliveries_delivererId_status_idx
  • deliveries_orderId_idx
  • deliveries_status_createdAt_idx

delivery_addresses

10 champs · 1 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('delivery_addresses_id_seq'::reg… PK
userProfileId text → user_profiles.id
city varchar(100) oui
neighborhood varchar(100) oui
latitude float8 oui
longitude float8 oui
description text oui
isDefault boolean false
createdAt timestamp CURRENT_TIMESTAMP
updatedAt timestamp
1 index
  • adresses_livraison_userProfileId_idx

delivery_offers

7 champs · 0 lignes

Champ Type Null Défaut Clé / relation
id text PK
orderId integer → orders.id
delivererId text → deliverers.id
status OfferStatus 'EN_ATTENTE'::"OfferStatus"
expiresAt timestamp
createdAt timestamp CURRENT_TIMESTAMP
updatedAt timestamp
2 index
  • delivery_offers_delivererId_status_idx
  • delivery_offers_orderId_delivererId_key (unique)

discussion_pinned_articles

5 champs · 0 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('discussion_pinned_articles_id_s… PK
discussionId integer → discussions.id
articleId integer → articles.id
pinnedById text → users.id
createdAt timestamp CURRENT_TIMESTAMP
3 index
  • discussion_pinned_articles_articleId_idx
  • discussion_pinned_articles_discussionId_articleId_key (unique)
  • discussion_pinned_articles_discussionId_idx

discussions

11 champs · 7 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('discussions_id_seq'::regclass) PK
tradeId integer oui → trades.id
clientId text oui → users.id
lastMessageAt timestamp oui
lastMessageText text oui
clientLastReadAt timestamp oui
merchantLastReadAt timestamp oui
createdAt timestamp CURRENT_TIMESTAMP
updatedAt timestamp
tradeBLastReadAt timestamp oui
tradeIdB integer oui → trades.id
5 index
  • discussions_clientId_idx
  • discussions_tradeIdB_idx
  • discussions_tradeId_clientId_key (unique)
  • discussions_tradeId_idx
  • discussions_tradeId_tradeIdB_key (unique)

email_admin

11 champs · 2 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('email_admin_id_seq'::regclass) PK
email varchar(255)
nom varchar(120) oui
prenom varchar(120) oui
fonction varchar(160) oui
evenements jsonb '[]'
resume_quotidien boolean true
actif boolean true
created_at timestamptz now()
updated_at timestamptz now()
notifications_vues_le timestamptz oui
2 index
  • email_admin_actif_idx
  • email_admin_email_key (unique)

executions_cron_werise

10 champs · 10 243 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('executions_cron_werise_id_seq':… PK
commande varchar(120)
statut varchar(20) 'en_cours'
demarree_le timestamp CURRENT_TIMESTAMP
terminee_le timestamp oui
duree_ms integer oui
resume varchar(255) oui
details jsonb oui
erreur text oui
hote varchar(120) oui
2 index
  • executions_cron_werise_commande_idx
  • executions_cron_werise_statut_idx

invoices

8 champs · 10 lignes

Champ Type Null Défaut Clé / relation
id text PK
amount float8
currency text 'XOF'
paymentMethod text oui
subscriptionId text → subscriptions.id
createdAt timestamp CURRENT_TIMESTAMP
is_active text 'paye'
reference text oui
1 index
  • invoices_reference_key (unique)

locations

6 champs · 0 lignes

Champ Type Null Défaut Clé / relation
id text PK
address text oui
city text oui
neighborhood text oui
latitude float8 oui
longitude float8 oui
1 index
  • locations_latitude_longitude_idx

messages

9 champs · 73 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('messages_id_seq'::regclass) PK
discussionId integer → discussions.id
senderId text oui → users.id
texte text oui
pieceJointes jsonb oui
editedAt timestamp oui
deletedAt timestamp oui
createdAt timestamp CURRENT_TIMESTAMP
idAdminWerise integer oui
1 index
  • messages_discussionId_createdAt_idx

migrations

3 champs · 0 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('migrations_id_seq'::regclass) PK
migration varchar(255)
batch integer

migrations_cron_werise

3 champs · 11 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('migrations_cron_werise_id_seq':… PK
migration varchar(255)
batch integer

notifications

7 champs · 93 lignes

Champ Type Null Défaut Clé / relation
id text PK
title text
body text
type text
isRead boolean false
userId text → users.id
createdAt timestamp CURRENT_TIMESTAMP

order_items

6 champs · 48 lignes

Champ Type Null Défaut Clé / relation
id text PK
orderId integer → orders.id
articleId integer → articles.id
quantity integer
unitPrice integer
subtotal integer
2 index
  • order_items_articleId_idx
  • order_items_orderId_idx

orders

20 champs · 41 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('orders_id_seq'::regclass) PK
orderNumber text
userProfileId text → user_profiles.id
tradeId integer → trades.id
totalItems integer
totalAmount integer
isDelivery boolean true
deliveryFee integer
paymentMethodId integer oui → payment_methods.id
deliveryAddressId integer oui → delivery_addresses.id
deliveryLatitude float8 oui
deliveryLongitude float8 oui
note text oui
status OrderStatus 'PENDING'::"OrderStatus"
statusUpdatedById text oui → user_profiles.id
statusUpdatedAt timestamp oui
cancelledByClient boolean false
cancelledByTrade boolean false
createdAt timestamp CURRENT_TIMESTAMP
updatedAt timestamp
8 index
  • commandes_createdAt_idx
  • commandes_statut_idx
  • commandes_tradeId_idx
  • commandes_tradeId_statut_createdAt_idx
  • commandes_tradeId_statut_updatedAt_idx
  • commandes_userProfileId_idx
  • commandes_userProfileId_statut_createdAt_idx
  • orders_orderNumber_key (unique)

otp_attempts

4 champs · 1 lignes

Champ Type Null Défaut Clé / relation
id text PK
identifier text
attempts integer
lockoutUntil timestamp oui
1 index
  • otp_attempts_identifier_key (unique)

otp_codes

9 champs · 0 lignes

Champ Type Null Défaut Clé / relation
id text PK
code text
identifier text
expiresAt timestamp
isUsed boolean false
userId text oui
resendOtp boolean
tempData jsonb oui
createdAt timestamp CURRENT_TIMESTAMP
1 index
  • otp_codes_identifier_idx

payment_methods

7 champs · 6 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('payment_methods_id_seq'::regcla… PK
name text
slug varchar(255) oui
photo varchar(255) oui
createdAt timestamp CURRENT_TIMESTAMP
updatedAt timestamp
key varchar(50) oui
3 index
  • payment_methods_key_key (unique)
  • payment_methods_name_key (unique)
  • payment_methods_slug_idx

plans

10 champs · 6 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('plans_id_seq'::regclass) PK
formule text oui
description jsonb oui
price integer
status boolean
discount float8 oui
periodicite text oui
deletedAt timestamp oui
createdAt timestamp CURRENT_TIMESTAMP
updatedAt timestamp
3 index
  • plans_formule_idx
  • plans_price_idx
  • plans_status_idx

purges_planifiees_werise

15 champs · 8 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('purges_planifiees_werise_id_seq… PK
cle varchar(64)
libelle varchar(191)
description text oui
actif boolean true
duree integer 7
unite varchar(16) 'jour'
supprimer_medias boolean true
taille_lot integer 200
derniere_execution_le timestamp oui
dernier_total_supprime integer
created_at timestamp oui
updated_at timestamp oui
table_cible varchar(64) oui
colonne_date varchar(64) oui
1 index
  • purges_planifiees_werise_cle_unique (unique)

push_notifications

11 champs · 22 lignes

Champ Type Null Défaut Clé / relation
id bigint nextval('push_notifications_id_seq'::reg… PK
titre varchar(255)
message text
audience varchar(255) 'all'
statut varchar(255) 'envoye'
erreur text oui
envoye_le timestamp now()
zone_lat float8 oui
zone_lng float8 oui
zone_rayon integer oui
cibles integer oui

rappels_werise

16 champs · 4 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('rappels_werise_id_seq'::regclas… PK
user_profile_id varchar(64) → user_profiles.id
trade_id integer oui → trades.id
titre varchar(190)
note text oui
rappel_le timestamp
recurrence varchar(20) 'aucune'
canal_notification boolean true
canal_email boolean false
email varchar(190) oui
statut varchar(20) 'actif'
derniere_notification_le timestamp oui
total_envois integer
erreur text oui
created_at timestamp CURRENT_TIMESTAMP
updated_at timestamp
3 index
  • rappels_werise_file_idx
  • rappels_werise_profil_idx
  • rappels_werise_trade_id_idx

receipt_configs

14 champs · 0 lignes

Champ Type Null Défaut Clé / relation
id text PK
tradeId integer → trades.id
slogan varchar(255) oui
ligneInfo varchar(255) oui
messagePied varchar(255) oui
afficherEmbleme boolean false
detailTaxes boolean false
tamponPaye boolean false
afficherLigneInfo boolean false
prixTTC boolean true
taxes jsonb oui
logoUrl varchar(500) oui
createdAt timestamp CURRENT_TIMESTAMP
updatedAt timestamp
1 index
  • receipt_configs_tradeId_key (unique)

refresh_tokens

7 champs · 70 lignes

Champ Type Null Défaut Clé / relation
id text PK
tokenHash text
expiresAt timestamp
revokedAt timestamp oui
isRevoked boolean false
userId text → users.id
createdAt timestamp CURRENT_TIMESTAMP
1 index
  • refresh_tokens_tokenHash_key (unique)

relances_werise

6 champs · 0 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('relances_werise_id_seq'::regcla… PK
automatisation varchar(64)
cible_type varchar(32)
cible_id varchar(64)
jalon varchar(32)
envoye_le timestamp CURRENT_TIMESTAMP
2 index
  • relances_werise_envoye_le_idx
  • relances_werise_unicite (unique)

reviews

7 champs · 12 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('reviews_id_seq'::regclass) PK
rating integer
comment text oui
userId text → users.id
createdAt timestamp CURRENT_TIMESTAMP
tradeId integer → trades.id
updatedAt timestamp
2 index
  • reviews_tradeId_idx
  • reviews_userId_idx

security_logs

9 champs · 126 lignes

Champ Type Null Défaut Clé / relation
id text PK
identifier text oui
action text
ipAddress text oui
userAgent text oui
send_success boolean true
metadata jsonb oui
createdAt timestamp CURRENT_TIMESTAMP
is_used boolean false

settings

8 champs · 1 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('settings_id_seq'::regclass) PK
logoUrl varchar(500) oui
tiktok varchar(255) oui
whatsapp varchar(255) oui
instagram varchar(255) oui
facebook varchar(255) oui
createdAt timestamp CURRENT_TIMESTAMP
updatedAt timestamp

stories

9 champs · 1 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('stories_id_seq'::regclass) PK
tradeId integer → trades.id
videoUrl text
thumbnailUrl text oui
durationSeconds integer oui
status StoryStatus 'PROCESSING'::"StoryStatus"
createdAt timestamp CURRENT_TIMESTAMP
expiresAt timestamp
mediaType StoryMediaType 'VIDEO'::"StoryMediaType"
3 index
  • stories_expiresAt_idx
  • stories_status_idx
  • stories_tradeId_idx

stories_compteur_werise

4 champs · 4 lignes

Champ Type Null Défaut Clé / relation
trade_id integer PK
total_publiees integer
premiere_le timestamp oui
derniere_le timestamp oui

story_likes

4 champs · 0 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('story_likes_id_seq'::regclass) PK
storyId integer → stories.id
userProfileId text → user_profiles.id
createdAt timestamp CURRENT_TIMESTAMP
3 index
  • story_likes_storyId_idx
  • story_likes_storyId_userProfileId_key (unique)
  • story_likes_userProfileId_idx

story_views

4 champs · 1 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('story_views_id_seq'::regclass) PK
storyId integer → stories.id
userProfileId text → user_profiles.id
createdAt timestamp CURRENT_TIMESTAMP
3 index
  • story_views_storyId_idx
  • story_views_storyId_userProfileId_key (unique)
  • story_views_userProfileId_idx

sub_categories

7 champs · 0 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('sub_categories_id_seq'::regclas… PK
name text
deletedAt timestamp oui
categoryId integer → categories.id
createdAt timestamp CURRENT_TIMESTAMP
updatedAt timestamp CURRENT_TIMESTAMP
is_active boolean true
2 index
  • sub_categories_categoryId_idx
  • sub_categories_is_active_idx

subscription_histories

10 champs · 10 lignes

Champ Type Null Défaut Clé / relation
id text PK
subscriptionId text → subscriptions.id
action text
planId integer → plans.id
startDate timestamp
endDate timestamp
amount float8
currency text 'XOF'
createdAt timestamp CURRENT_TIMESTAMP
paymentMethod text oui
1 index
  • subscription_histories_subscriptionId_idx

subscriptions

6 champs · 7 lignes

Champ Type Null Défaut Clé / relation
id text PK
planId integer → plans.id
startDate timestamp CURRENT_TIMESTAMP
endDate timestamp
userProfileId text → user_profiles.id
is_active boolean true
2 index
  • subscriptions_userProfileId_key (unique)
  • subscriptions_userProfileId_planId_idx

trade_categories

4 champs · 12 833 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('trade_categories_id_seq'::regcl… PK
categoryId integer → categories.id
createdAt timestamp CURRENT_TIMESTAMP
tradeId integer → trades.id
3 index
  • trade_categories_categoryId_idx
  • trade_categories_tradeId_categoryId_key (unique)
  • trade_categories_tradeId_idx

trade_follows

4 champs · 10 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('trade_follows_id_seq'::regclass… PK
tradeId integer → trades.id
userProfileId text → user_profiles.id
createdAt timestamp CURRENT_TIMESTAMP
3 index
  • trade_follows_tradeId_idx
  • trade_follows_tradeId_userProfileId_key (unique)
  • trade_follows_userProfileId_idx

trade_photos

4 champs · 10 017 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('trade_photos_id_seq'::regclass) PK
url text
tradeId integer → trades.id
createdAt timestamp CURRENT_TIMESTAMP
1 index
  • trade_photos_tradeId_idx

trades

19 champs · 10 020 lignes

Champ Type Null Défaut Clé / relation
id integer nextval('trades_id_seq'::regclass) PK
name text
phone text
email text oui
socialLinks jsonb oui
latitude float8 oui
longitude float8 oui
address text
cashBalance float8
deletedAt timestamp oui
createdAt timestamp CURRENT_TIMESTAMP
updatedAt timestamp
userProfileId text → user_profiles.id
is_active boolean true
working_hours jsonb oui
is_local boolean false
logoUrl varchar(500) oui
avgRating float8
reviewCount integer
7 index
  • trades_address_idx
  • trades_avgRating_idx
  • trades_deletedAt_idx
  • trades_is_active_idx
  • trades_latitude_longitude_idx
  • trades_name_idx
  • trades_userProfileId_idx

user_credentials

5 champs · 9 978 lignes

Champ Type Null Défaut Clé / relation
id text PK
passwordHash text
userId text → users.id
createdAt timestamp CURRENT_TIMESTAMP
updatedAt timestamp
1 index
  • user_credentials_userId_key (unique)

user_profiles

13 champs · 9 991 lignes

Champ Type Null Défaut Clé / relation
id text PK
firstName text oui
lastName text oui
email text oui
phone text oui
userId text → users.id
is_active boolean true
createdAt timestamp CURRENT_TIMESTAMP
updatedAt timestamp
googleId text oui
avatar text oui
acceptedTerms boolean false
lastSeen timestamp oui
4 index
  • user_profiles_email_key (unique)
  • user_profiles_googleId_key (unique)
  • user_profiles_phone_key (unique)
  • user_profiles_userId_key (unique)

user_roles

3 champs · 9 990 lignes

Champ Type Null Défaut Clé / relation
id text PK
role text
userId text → users.id
1 index
  • user_roles_userId_role_key (unique)

user_sessions

8 champs · 56 lignes

Champ Type Null Défaut Clé / relation
id text PK
userId text → users.id
ipAddress text oui
location text oui
device text oui
userAgent varchar(500) oui
connectedAt timestamp CURRENT_TIMESTAMP
disconnectedAt timestamp oui
2 index
  • user_sessions_connectedAt_idx
  • user_sessions_userId_idx

users

3 champs · 9 991 lignes

Champ Type Null Défaut Clé / relation
id text PK
createdAt timestamp CURRENT_TIMESTAMP
updatedAt timestamp