diff --git a/models/ticket.go b/models/ticket.go index 4afccd6..8da75e3 100644 --- a/models/ticket.go +++ b/models/ticket.go @@ -2,6 +2,73 @@ package models import "time" +type DBTicket struct { + AccountId int + ApprovalCount int + Assignee string `gorm:"type:json"` + AssigneeId int + AttachmentCount int + Category string + CF string `gorm:"type:json"` + Channel string + ChannelCode string + ChannelRelatedInfo string + Classification string + ClosedTime *time.Time + CommentCount int + Contact string `gorm:"type:json"` + ContactId int + CreatedBy int + CreatedTime time.Time + CustomerResponseTime time.Time + DepartmentId int + DescAttachments string `gorm:"type:json"` + Description string + DueDate *time.Time + Email string + EntitySkills string `gorm:"type:json"` + FirstThread string `gorm:"type:json"` + FollowerCount int + Id string `gorm:"primaryKey"` + IsArchived bool + IsDeleted bool + IsEscalated bool + IsOverdue bool + IsResponseOverdue bool + IsSpam bool + IsTrashed bool + Language string + LayoutDetails string `gorm:"type:json"` + LayoutId int + ModifiedBy int + ModifiedTime time.Time + OnHoldTime *time.Time + Phone string + Priority string + ProductId string + Resolution string + ResponseDueDate *time.Time + SecondaryContacts string `gorm:"type:json"` + Sentiment string + SharedDepartments string `gorm:"type:json"` + Source string `gorm:"type:json"` + Status string + StatusType string + SubCategory string + Subject string + TagCount int + TaskCount int + TeamId int + ThreadCount int + TicketNumber int + TimeEntryCount int + WebUrl string +} + +func (DBTicket) TableName() string { + return "zoho_live_tickets" +} + type Ticket struct { TicketID string `gorm:"primaryKey;column:ticket_id" json:"ticket_id"` TicketReferenceID *string `gorm:"column:ticket_reference_id" json:"ticket_reference_id"`