model

package
v0.0.11 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 8, 2021 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Article

type Article struct {
	ArticleID              ID           `json:"ArticleID"`
	ArticleNumber          int          `json:"ArticleNumber"`
	Attachments            []Attachment `json:"Attachment"`
	Bcc                    string       `json:"Bcc"`
	Body                   string       `json:"Body"`
	Cc                     string       `json:"Cc"`
	ChangeBy               ID           `json:"ChangeBy"`
	ChangeTime             string       `json:"ChangeTime"`
	Charset                string       `json:"Charset"`
	CommunicationChannelID string       `json:"CommunicationChannelID"`
	ContentCharset         string       `json:"ContentCharset"`
	ContentType            string       `json:"ContentType"`
	CreateBy               ID           `json:"CreateBy"`
	CreateTime             ID           `json:"CreateTime"`
	From                   string       `json:"From"`
	InReplyTo              string       `json:"InReplyTo"`
	IncomingTime           string       `json:"IncomingTime"`
	IsVisibleForCustomer   string       `json:"IsVisibleForCustomer"`
	MessageID              string       `json:"MessageID"`
	MimeType               string       `json:"MimeType"`
	References             string       `json:"References"`
	ReplyTo                string       `json:"ReplyTo"`
	SenderType             string       `json:"SenderType"`
	SenderTypeID           string       `json:"SenderTypeID"`
	Subject                string       `json:"Subject"`
	TicketID               ID           `json:"TicketID"`
	TimeUnit               int          `json:"TimeUnit"`
	To                     string       `json:"To"`
}

type ArticleUpdate

type ArticleUpdate struct {
	CommunicationChannelID string `json:"CommunicationChannelID"`
	Subject                string `json:"Subject"`
	Body                   string `json:"Body"`
	MimeType               string `json:"MimeType"`
	Charset                string `json:"Charset"`

	ArticleID            ID           `json:"ArticleID,omitempty"`
	ArticleNumber        int          `json:"ArticleNumber,omitempty"`
	Attachments          []Attachment `json:"Attachment,omitempty"`
	Bcc                  string       `json:"Bcc,omitempty"`
	Cc                   string       `json:"Cc,omitempty"`
	ChangeBy             ID           `json:"ChangeBy,omitempty"`
	ChangeTime           string       `json:"ChangeTime,omitempty"`
	ContentCharset       string       `json:"ContentCharset,omitempty"`
	ContentType          string       `json:"ContentType,omitempty"`
	CreateBy             ID           `json:"CreateBy,omitempty"`
	CreateTime           ID           `json:"CreateTime,omitempty"`
	From                 string       `json:"From,omitempty"`
	InReplyTo            string       `json:"InReplyTo,omitempty"`
	IncomingTime         string       `json:"IncomingTime,omitempty"`
	IsVisibleForCustomer string       `json:"IsVisibleForCustomer,omitempty"`
	MessageID            string       `json:"MessageID,omitempty"`
	References           string       `json:"References,omitempty"`
	ReplyTo              string       `json:"ReplyTo,omitempty"`
	SenderType           string       `json:"SenderType,omitempty"`
	SenderTypeID         string       `json:"SenderTypeID,omitempty"`
	TicketID             ID           `json:"TicketID,omitempty"`
	TimeUnit             int          `json:"TimeUnit,omitempty"`
	To                   string       `json:"To,omitempty"`
	// contains filtered or unexported fields
}

func (*ArticleUpdate) SetBodyHTML

func (au *ArticleUpdate) SetBodyHTML(to string) *ArticleUpdate

SetBodyHTML set Body as HTML

func (*ArticleUpdate) SetBodyText

func (au *ArticleUpdate) SetBodyText(to string) *ArticleUpdate

SetBodyText Set Body as Text

func (*ArticleUpdate) SetCommunicationChannelID

func (au *ArticleUpdate) SetCommunicationChannelID(to string) *ArticleUpdate

SetCommunicationChannelID set CommunicationChannelID

func (*ArticleUpdate) SetSubject

func (au *ArticleUpdate) SetSubject(to string) *ArticleUpdate

SetSubject Set Subject

type Attachment

type Attachment struct {
	Content            []byte `json:"Content"`
	ContentAlternative []byte `json:"ContentAlternative"`
	ContentID          string `json:"ContentID"`
	ContentType        string `json:"ContentType"`
	Disposition        string `json:"Disposition"`
	FileID             ID     `json:"FileID"`
	Filename           string `json:"Filename"`
	FilesizeRaw        int    `json:"FilesizeRaw"`
}

type DynamicField

type DynamicField struct {
	Name  string      `json:"Name"`
	Value interface{} `json:"Value"`
}

type Error

type Error struct {
	ErrorCode    string `json:"ErrorCode"`
	ErrorMessage string `json:"ErrorMessage"`
}

type ID

type ID int64

func StringID

func StringID(s string) (ID, error)

func (ID) Int64

func (id ID) Int64() int64

func (ID) String

func (id ID) String() string

func (*ID) UnmarshalJSON

func (id *ID) UnmarshalJSON(b []byte) (err error)

type PendingTime

type PendingTime struct {
	Diff int `json:"Diff"`
}

type Ticket

type Ticket struct {
	Age                       int            `json:"Age"`
	ArchiveFlag               string         `json:"ArchiveFlag"`
	Articles                  []Article      `json:"Article"`
	ChangeBy                  ID             `json:"ChangeBy"`
	CreateBy                  ID             `json:"CreateBy"`
	Changed                   string         `json:"Changed"`
	Created                   string         `json:"Created"`
	CustomerID                *string        `json:"CustomerID"`
	CustomerUser              string         `json:"CustomerUser"`
	CustomerUserID            *string        `json:"CustomerUserID"`
	DynamicFields             []DynamicField `json:"DynamicField"`
	EscalationDestinationDate string         `json:"EscalationDestinationDate"`
	EscalationDestinationIn   string         `json:"EscalationDestinationIn"`
	EscalationDestinationTime string         `json:"EscalationDestinationTime"`
	EscalationResponseTime    string         `json:"EscalationResponseTime"`
	EscalationSolutionTime    string         `json:"EscalationSolutionTime"`
	EscalationTime            int            `json:"EscalationTime"`
	EscalationTimeWorkingTime int            `json:"EscalationTimeWorkingTime"`
	EscalationUpdateTime      string         `json:"EscalationUpdateTime"`
	GroupID                   ID             `json:"GroupID"`
	Lock                      string         `json:"Lock"`
	LockID                    ID             `json:"LockID"`
	Owner                     string         `json:"Owner"`
	OwnerID                   ID             `json:"OwnerID"`
	Priority                  string         `json:"Priority"`
	PriorityID                ID             `json:"PriorityID"`

	Queue   string `json:"Queue"`
	QueueID ID     `json:"QueueID"`

	RealTillTimeNotUsed string `json:"RealTillTimeNotUsed"`

	Responsible   string `json:"Responsible"`
	ResponsibleID ID     `json:"ResponsibleID"`

	SLA   string `json:"SLA"`
	SLAID ID     `json:"SLAID"`

	Service   string `json:"Service"`
	ServiceID ID     `json:"ServiceID"`

	SolutionTime int `json:"SolutionTime"`

	SolutionTimeDestinationDate *string `json:"SolutionTimeDestinationDate"`
	SolutionTimeDestinationTime *Time   `json:"SolutionTimeDestinationTime"`
	SolutionTimeWorkingTime     int     `json:"SolutionTimeWorkingTime"`

	State   string `json:"State"`
	StateID ID     `json:"StateID"`

	TicketID     ID     `json:"TicketID"`
	TicketNumber string `json:"TicketNumber"`

	TimeUnit int    `json:"TimeUnit"`
	Title    string `json:"Title"`

	Type   string `json:"Type"`
	TypeID ID     `json:"TypeID"`

	UnlockTimeout string `json:"UnlockTimeout"`
	UntilTime     int    `json:"UntilTime"`
}

type TicketUpdate

type TicketUpdate struct {
	Title string `json:"Title"`

	QueueID       *ID          `json:"QueueID,omitempty"`
	Queue         *string      `json:"Queue,omitempty"`
	Lock          *string      `json:"Lock,omitempty"`
	StateID       *ID          `json:"StateID,omitempty"`
	Priority      *string      `json:"Priority,omitempty"`
	SLAID         *ID          `json:"SLAID,omitempty"`
	State         *string      `json:"State,omitempty"`
	Responsible   *string      `json:"Responsible,omitempty"`
	TypeID        *ID          `json:"TypeID,omitempty"`
	ServiceID     *ID          `json:"ServiceID,omitempty"`
	Owner         *string      `json:"Owner,omitempty"`
	ResponsibleID *ID          `json:"ResponsibleID,omitempty"`
	OwnerID       *ID          `json:"OwnerID,omitempty"`
	CustomerUser  *string      `json:"CustomerUser,omitempty"`
	LockID        *ID          `json:"LockID,omitempty"`
	Type          *string      `json:"Type,omitempty"`
	Service       *string      `json:"Service,omitempty"`
	SLA           *string      `json:"SLA,omitempty"`
	PriorityID    *ID          `json:"PriorityID,omitempty"`
	PendingTime   *PendingTime `json:"PendingTime,omitempty"`
	// contains filtered or unexported fields
}

func (*TicketUpdate) SetPendingTime

func (TicketUpdate *TicketUpdate) SetPendingTime(to *PendingTime) *TicketUpdate

SetPendingTime set PendingTime

type Time added in v0.0.8

type Time int

func (*Time) UnmarshalJSON added in v0.0.8

func (t *Time) UnmarshalJSON(b []byte) (err error)

type Update

type Update struct {
	UserLogin     *string        `json:"UserLogin,omitempty"`
	Password      *string        `json:"Password,omitempty"`
	TicketID      *string        `json:"TicketID,omitempty"`
	TicketNumber  *string        `json:"TicketNumber,omitempty"`
	Ticket        *Ticket        `json:"Ticket,omitempty"`
	Article       *ArticleUpdate `json:"Article,omitempty"`
	DynamicFields []DynamicField `json:"DynamicField,omitempty"`
	Attachments   []Attachment   `json:"Attachment,omitempty"`
}

func (*Update) AddUpdateDynamicField added in v0.0.11

func (Update *Update) AddUpdateDynamicField(name string, value interface{})

func (Update) ReaderCloser

func (Update Update) ReaderCloser() io.ReadCloser

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL