kdf;dfldfl

This commit is contained in:
cangui 2025-05-09 16:20:29 +02:00
parent 6c4a1aa2b2
commit 0a3c0d219b
2 changed files with 5 additions and 4 deletions

View File

@ -333,7 +333,7 @@ func WebhookReceiveHandler(db *gorm.DB) http.HandlerFunc {
messages := value["messages"].([]interface{})
if len(messages) > 0 {
msg := messages[0].(map[string]interface{})
from := msg["from"].(string)
//from := msg["from"].(string)
msgType := msg["type"].(string)
msgID := msg["id"].(string)
@ -354,7 +354,7 @@ func WebhookReceiveHandler(db *gorm.DB) http.HandlerFunc {
conv := models.Conversation{
UserID: user.ID,
From: from,
From: user.NameClient,
To: recipientID,
MessageID: msgID,
Type: msgType,

View File

@ -20,6 +20,7 @@ type User struct {
UpdatedAt time.Time
DeletedAt gorm.DeletedAt `gorm:"index"`
NameClient string `gorm:"not null"`
Password string `gorm:"not null"` // hashé avec bcrypt
Email string `gorm:"uniqueIndex;not null"`
SSOID string `gorm:"uniqueIndex;not null"`