amo/leads/leads.go

80 lines
2.1 KiB
Go
Raw Normal View History

2024-01-15 00:04:00 +03:00
package leads
2024-05-19 21:00:41 +03:00
import "surdeus.su/core/amo/common"
2024-01-15 00:04:00 +03:00
type Lead struct {
ID int `json:"id"`
2024-05-30 11:43:10 +03:00
Name string `json:"name,omitempty"`
Price int `json:"price,omitempty"`
ResponsibleUserID int `json:"responsible_user_id,omitempty"`
GroupID int `json:"group_id,omitempty"`
StatusID int `json:"status_id,omitempty"`
PipelineID int `json:"pipeline_id,omitempty"`
LossReasonID int `json:"loss_reason_id,omitempty"`
SourceID interface{} `json:"source_id,omitempty"`
2024-05-30 11:43:10 +03:00
CreatedBy int `json:"created_by,omitempty"`
UpdatedBy int `json:"updated_by,omitempty"`
CreatedAt int `json:"created_at,omitempty"`
UpdatedAt int `json:"updated_at,omitempty"`
ClosedAt int `json:"closed_at,omitempty"`
ClosestTaskAt interface{} `json:"closest_task_at,omitempty"`
IsDeleted bool `json:"is_deleted,omitempty"`
CustomFieldsValues common.CustomFieldsValues `json:"custom_fields_values,omitempty"`
2024-05-30 11:43:10 +03:00
Score interface{} `json:"score,omitempty"`
AccountID int `json:"account_id,omitempty"`
2024-05-30 11:43:10 +03:00
IsPriceModifiedByRobot bool `json:"is_price_modified_by_robot,omitempty"`
Links Links `json:"_links,omitempty"`
Embedded Embedded `json:"_embedded,omitempty"`
2024-01-15 00:04:00 +03:00
}
type Self struct {
Href string `json:"href"`
}
type Links struct {
Self Self `json:"self"`
}
type Tags struct {
ID int `json:"id"`
2024-01-15 00:04:00 +03:00
Name string `json:"name"`
}
type Metadata struct {
2024-05-30 11:43:10 +03:00
Quantity int `json:"quantity"`
CatalogID int `json:"catalog_id"`
2024-01-15 00:04:00 +03:00
}
type CatalogElements struct {
ID int `json:"id"`
2024-01-15 00:04:00 +03:00
Metadata Metadata `json:"metadata"`
}
type LossReason struct {
ID int `json:"id"`
2024-05-30 11:43:10 +03:00
Name string `json:"name"`
Sort int `json:"sort"`
CreatedAt int `json:"created_at"`
UpdatedAt int `json:"updated_at"`
Links Links `json:"_links"`
2024-01-15 00:04:00 +03:00
}
type Companies struct {
ID int `json:"id"`
2024-01-15 00:04:00 +03:00
Links Links `json:"_links"`
}
type Contacts struct {
ID int `json:"id"`
2024-05-30 11:43:10 +03:00
IsMain bool `json:"is_main"`
Links Links `json:"_links"`
2024-01-15 00:04:00 +03:00
}
type Embedded struct {
2024-05-30 11:43:10 +03:00
Tags []*Tags `json:"tags"`
2024-01-15 00:04:00 +03:00
CatalogElements []*CatalogElements `json:"catalog_elements"`
2024-05-30 11:43:10 +03:00
LossReason []*LossReason `json:"loss_reason"`
Companies []*Companies `json:"companies"`
Contacts []*Contacts `json:"contacts"`
2024-01-15 00:04:00 +03:00
}