model

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Nov 14, 2022 License: BSD-2-Clause Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Banner struct {
	JetimobBannerId int          `json:"id_banner"`
	JetimobImageId  int          `json:"id_imagem"`
	URL             null.String  `json:"link"`
	Order           int          `json:"ordem"`
	Title           null.String  `json:"titulo"`
	Description     null.String  `json:"descricao"`
	HrefTarget      string       `json:"abrir_em"`
	IsVideo         json.IntBool `json:"is_video"`
	VideoUrl        string       `json:"video"`
	ImageUrl        string       `json:"imagem"`
}

func (Banner) Identifier

func (b Banner) Identifier() int

func (Banner) IdentityColumn

func (b Banner) IdentityColumn() string

type Broker

type Broker struct {
	JetimobBrokerId         int           `json:"id"`
	Name                    string        `json:"nome"`
	Creci                   string        `json:"creci"`
	Avatar                  null.String   `json:"avatar"`
	Biography               null.String   `json:"biografia"`
	JobPosition             null.String   `json:"cargo"`
	Birthday                null.String   `json:"data_nascimento"`
	CityName                null.String   `json:"cidade"`
	StateAbbrev             null.String   `json:"estado"`
	IsBroker                bool          `json:"corretor"`
	Email                   null.String   `json:"email"`
	PrimaryPhoneNumber      null.String   `json:"telefone"`
	AltPhoneNumber          null.String   `json:"telefone2"`
	PrimaryPhoneHasWhatsapp null.Bool     `json:"telefone_whatsapp"`
	AltPhoneHasWhatsapp     null.Bool     `json:"telefone2_whatsapp"`
	TwitterUrl              null.String   `json:"twitter"`
	FacebookUrl             null.String   `json:"facebook"`
	LinkedinUrl             null.String   `json:"linkedin"`
	SkypeUrl                null.String   `json:"skype"`
	InstagramUrl            null.String   `json:"instagram"`
	PersonalWebsiteUrl      null.String   `json:"website"`
	ShowPersonalWebsite     bool          `json:"mostrar_site"`
	Testimonials            json.StrSlice `json:"depoimentos"`
}

func (Broker) Identifier

func (b Broker) Identifier() int

func (Broker) IdentityColumn

func (b Broker) IdentityColumn() string

type Condominium

type Condominium struct {
	Type                     string             `json:"tipo"`
	JetimobCoverImageId      null.Int           `json:"id_imagem"`
	JetimobCondominiumId     int                `json:"id_condominio"`
	Name                     string             `json:"nome"`
	Featured                 bool               `json:"destaque"`
	Launch                   bool               `json:"lancamento"`
	Gated                    bool               `json:"fechado"`
	ConstructionPercentage   null.Int           `json:"acabamentos"`
	BrickPercentage          null.Int           `json:"alvenaria"`
	StructurePercentage      null.Int           `json:"estruturas"`
	FoundationPercentage     null.Int           `json:"fundacoes"`
	InstallationsPercentage  null.Int           `json:"intalacoes"`
	LandscapingPercentage    null.Int           `json:"paisagismo"`
	ProjectPercentage        null.Int           `json:"projetos"`
	GroundLevelingPercentage null.Int           `json:"terraplanagem"`
	Latitude                 float32            `json:"latitude"`
	Longitude                float32            `json:"longitue"`
	Notes                    string             `json:"observacoes"`
	IncorporationRecord      null.String        `json:"registro_incorporacao"`
	JetimobNeighborhoodId    int                `json:"id_bairro"`
	JetimobCityId            int                `json:"id_cidade"`
	JetimobStateId           int                `json:"id_estado"`
	AddressZipcode           string             `json:"endereco_cep"`
	AddressStreet            string             `json:"endereco_logradouro"`
	AddressNeighborhood      string             `json:"endereco_bairro"`
	AddressNumber            string             `json:"endereco_numero"`
	CityName                 string             `json:"endereco_cidade"`
	StateName                string             `json:"endereco_estado"`
	Status                   string             `json:"situacao"`
	DeliveryMonth            null.Int           `json:"entrega_mes"`
	DeliveryYear             null.Int           `json:"entrega_ano"`
	AdministeringCompanyName null.String        `json:"administradora"`
	BuildingCompanyName      null.String        `json:"construtora"`
	RealStateDeveloperName   null.String        `json:"incorporadora"`
	ArchitectName            null.String        `json:"projeto_arquitetonico"`
	LandscaperName           null.String        `json:"projeto_paisagismo"`
	DecoratorName            null.String        `json:"projeto_decoracao"`
	CoverImage               string             `json:"logotipo"`
	AvailableProperties      int                `json:"total_imoveis_disponiveis"`
	Infrastructures          json.CommaStrSlice `json:"infraestruturas"`
	Labels                   json.CommaStrSlice `json:"etiquetas"`
	Videos                   VideoArray         `json:"videos"`
	Images                   MediaArray         `json:"imagens"`
	Blueprints               MediaArray         `json:"plantas"`
	ArTour                   json.StrSlice      `json:"tour360"`
	CreatedAt                json.JTime         `json:"data_cadastro"`
	UpdatedAt                json.JTime         `json:"data_update"`
}

func (Condominium) Identifier

func (c Condominium) Identifier() int

func (Condominium) IdentityColumn

func (c Condominium) IdentityColumn() string

type MappedMedia

type MappedMedia struct {
	Url   string      `json:"url"`
	Title null.String `json:"title"`
}

type MappedVideo

type MappedVideo struct {
	Url   string      `json:"url"`
	Title null.String `json:"title"`
}

type Media

type Media struct {
	Url   string      `json:"link"`
	Title null.String `json:"titulo"`
}

func (Media) MarshalJSON

func (m Media) MarshalJSON() ([]byte, error)

func (Media) Value

func (m Media) Value() (driver.Value, error)

type MediaArray

type MediaArray []Media

func (MediaArray) Value

func (ma MediaArray) Value() (driver.Value, error)

type Model

type Model interface {
	Identifier() int
	IdentityColumn() string
}

type PaginatedResponse

type PaginatedResponse[T any] struct {
	Total      int `json:"total"`
	Page       int `json:"page"`
	PageSize   int `json:"pageSize"`
	TotalPages int `json:"totalPages"`
	Data       T   `json:"data"`
}

PaginatedResponse é o modelo base de qualquer resposta da rota de webservice da jetimob.

func (PaginatedResponse[T]) MaxPages

func (pr PaginatedResponse[T]) MaxPages() int

type Property

type Property struct {
	Type                       string              `json:"tipo"`
	JetimobPropertyId          int                 `json:"id_imovel"`
	JetimobCondominiumId       null.Int            `json:"id_condominio"`
	JetimobBrokerId            int                 `json:"id_corretor"`
	JetimobStateId             int                 `json:"id_estado"`
	JetimobCityId              int                 `json:"id_cidade"`
	JetimobNeighborhoodId      int                 `json:"id_bairro"`
	IdentifierCode             string              `json:"codigo"`
	Contracts                  json.CommaStrSlice  `json:"contrato"`
	Subtype                    string              `json:"subtipo"`
	Notes                      string              `json:"observacoes"`
	BuildingType               null.String         `json:"tipo_construcao"`
	DeliveryYear               null.Int            `json:"entrega_ano"`
	DeliveryMonth              null.Int            `json:"entrega_mes"`
	Furnished                  int                 `json:"mobiliado"`
	Suites                     int                 `json:"suites"`
	Bathrooms                  int                 `json:"banheiros"`
	Garages                    int                 `json:"garagens"`
	Financeable                int                 `json:"financiavel"`
	HasExclusivity             bool                `json:"exclusividade"`
	TotalArea                  null.Float          `json:"area_total"`
	PrivateArea                null.Float          `json:"area_privativa"`
	UsefulArea                 null.Float          `json:"area_util"`
	MeasurementType            string              `json:"medida"`
	FloorTypes                 json.CommaStrSlice  `json:"tipo_piso"`
	TerrainWidthFront          null.Float          `json:"terreno_frente"`
	TerrainWidthBack           null.Float          `json:"terreno_fundos"`
	TerrainLengthLeft          null.Float          `json:"terreno_esquerdo"`
	TerrainLengthRight         null.Float          `json:"terreno_direita"`
	TerrainArea                null.Float          `json:"terreno_total"`
	CreatedAt                  json.JTime          `json:"data_cadastro"`
	BuildingStatus             string              `json:"status"`
	ShowCondominiumValue       bool                `json:"valor_condominio_visivel"`
	CondominiumValue           null.Float          `json:"valor_condominio"`
	ShowSaleValue              bool                `json:"valor_venda_visivel"`
	SaleValue                  null.Float          `json:"valor_venda"`
	ShowRentalValue            bool                `json:"valor_locacao_visivel"`
	RentalValue                null.Float          `json:"valor_locacao"`
	ShowSeasonalValue          bool                `json:"valor_temporada_visivel"`
	SeasonalValue              null.Float          `json:"valor_temporada"`
	IptuFrequency              null.String         `json:"periodicidade_iptu"`
	IptuValueExempt            string              `json:"valor_iptu_isento"`
	ShowIptuValue              bool                `json:"valor_iptu_visivel"`
	IptuValue                  null.Float          `json:"valor_iptu"`
	SeasonCalendar             SeasonCalendarArray `json:"calendario_temporada"`
	RuralActivities            json.CommaStrSlice  `json:"rural.atividade_rural"`
	RuralHeadquarters          null.Int            `json:"rural.rural_sedes"`
	ArableArea                 null.String         `json:"rural.rural_area_aravel"`
	AllowedGuests              null.Int            `json:"numero_pessoas"`
	MetaTitle                  string              `json:"meta_title"`
	MetaDescription            string              `json:"meta_description"`
	FireInsuranceValue         null.Float          `json:"valor_seguro_incendio"`
	CleaningFeeValue           null.Float          `json:"valor_taxa_limpeza"`
	Position                   null.String         `json:"posicao"`
	SolarPositions             json.CommaStrSlice  `json:"posicao_solar"`
	SeaDistance                null.Int            `json:"distancia_mar"`
	AcceptExchange             bool                `json:"permuta"`
	Latitude                   null.Float          `json:"latitude"`
	Longitude                  null.Float          `json:"longitude"`
	OccupancyStatus            string              `json:"situacao"`
	Featured                   string              `json:"destaque"`
	FeatureUntil               null.Time           `json:"destaque_fim"`
	CondominiumType            null.String         `json:"condominio_tipo"`
	CondominiumName            null.String         `json:"condominio_nome"`
	GatedCondominium           null.Bool           `json:"condominio_fechado"`
	ShowFullAddress            bool                `json:"endereco_completamente_visivel"`
	ShowAddressState           bool                `json:"endereco_estado_visivel"`
	ShowAddressCity            bool                `json:"endereco_cidade_visivel"`
	ShowAddressNeighborhood    bool                `json:"endereco_bairro_visivel"`
	ShowAddressStreet          bool                `json:"endereco_logradouro_visivel"`
	ShowAddressReference       bool                `json:"endereco_referencia_visivel"`
	ShowAddressNumber          bool                `json:"endereco_numero_visivel"`
	ShowAddressFloor           bool                `json:"andar_visivel"`
	AddressState               string              `json:"endereco_estado"`
	AddressCity                string              `json:"endereco_cidade"`
	AddressNeighborhood        string              `json:"endereco_bairro"`
	AddressStreet              string              `json:"endereco_logradouro"`
	AddressZipcode             null.String         `json:"endereco_cep"`
	AddressReference           string              `json:"endereco_referencia"`
	AddressNumber              string              `json:"endereco_numero"`
	AddressFloor               null.Int            `json:"andar"`
	GeopositionVisibility      int                 `json:"geoposicionamento_visivel"`
	AdTitle                    string              `json:"titulo_anuncio"`
	AdDescription              string              `json:"descricao_anuncio"`
	Labels                     json.CommaStrSlice  `json:"tags"`
	SuretyInsurance            null.Bool           `json:"seguro_fianca"`
	PropertyInfrastructures    json.CommaStrSlice  `json:"imovel_comodidades"`
	CondominiumInfrastructures json.CommaStrSlice  `json:"condominio_comodidades"`
	UpdatedAt                  json.JTime          `json:"updated_at"`
	ValidatedAt                json.JTime          `json:"data_atualizacao"`
	Videos                     VideoArray          `json:"videos"`
	Blueprints                 MediaArray          `json:"plantas"`
	Images                     MediaArray          `json:"imagens"`
	ArTour                     json.StrSlice       `json:"tour360"`
}

func (Property) Identifier

func (p Property) Identifier() int

func (Property) IdentityColumn

func (p Property) IdentityColumn() string

func (*Property) UnmarshalJSON

func (p *Property) UnmarshalJSON(data []byte) error

type ResponseWithPagination

type ResponseWithPagination interface {
	MaxPages() int
}

type Rural

type Rural struct {
	Activities   json.CommaStrSlice `json:"atividade_rural"`
	Headquarters null.Int           `json:"rural_sedes"`
	ArableArea   null.String        `json:"rural_area_aravel"`
}

type SeasonCalendar

type SeasonCalendar struct {
	Name               null.String `json:"nome"`
	StartDate          json.JTime  `json:"inicio"`
	EndDate            json.JTime  `json:"fim"`
	DailyRate          null.Float  `json:"valor_diaria"`
	MinimumDailyRental null.Int    `json:"minimo_diarias"`
}

type SeasonCalendarArray

type SeasonCalendarArray []SeasonCalendar

func (SeasonCalendarArray) Value

func (sc SeasonCalendarArray) Value() (driver.Value, error)

type Video

type Video struct {
	Url   string      `json:"href"`
	Title null.String `json:"title"`
}

func (Video) MarshalJSON

func (v Video) MarshalJSON() ([]byte, error)

func (Video) Value

func (v Video) Value() (driver.Value, error)

type VideoArray

type VideoArray []Video

func (VideoArray) Value

func (v VideoArray) Value() (driver.Value, error)

Jump to

Keyboard shortcuts

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