mirror of
https://github.com/cheveguerra/whaticket-community.git
synced 2026-04-19 04:09:26 +00:00
improvement: moved vcard parse logic to backend
This commit is contained in:
@@ -10,6 +10,7 @@ import {
|
||||
BelongsTo,
|
||||
ForeignKey
|
||||
} from "sequelize-typescript";
|
||||
import Contact from "./Contact";
|
||||
import Ticket from "./Ticket";
|
||||
|
||||
@Table
|
||||
@@ -64,6 +65,20 @@ class Message extends Model<Message> {
|
||||
|
||||
@BelongsTo(() => Ticket)
|
||||
ticket: Ticket;
|
||||
|
||||
@ForeignKey(() => Contact)
|
||||
@Column
|
||||
contactId: number;
|
||||
|
||||
@BelongsTo(() => Contact, "contactId")
|
||||
contact: Contact;
|
||||
|
||||
@ForeignKey(() => Contact)
|
||||
@Column
|
||||
vcardContactId: number;
|
||||
|
||||
@BelongsTo(() => Contact, "vcardContactId")
|
||||
vcardContact: Contact;
|
||||
}
|
||||
|
||||
export default Message;
|
||||
|
||||
Reference in New Issue
Block a user