Organizations

This package contains all data models related to organizations: Contact, Location and Organization.

Contact

class integreat_compass.cms.models.organizations.contact.Contact(*args, **kwargs)

Bases: AbstractBaseModel

Data model representing an Offer Contact.

Parameters:
  • id (BigAutoField) – Primary key: ID

  • name (CharField) – Name. Name of the responsible contact person

  • email (EmailField) – Email. Email address of the responsible contact person

  • phone (CharField) – Phone number. Phone numbner of the responsible contact person

Relationship fields:

Parameters:

creator (ForeignKey to User) – Creator (related name: offer_contact)

Reverse relationships:

Parameters:

offer (Reverse ForeignKey from Offer) – All offers of this offer contact (related name of offer_contact)

exception DoesNotExist

Bases: ObjectDoesNotExist

exception MultipleObjectsReturned

Bases: MultipleObjectsReturned

creator

Type: ForeignKey to User

Creator (related name: offer_contact)

creator_id

Internal field, use creator instead.

email

Type: EmailField

Email. Email address of the responsible contact person

get_repr()

This overwrites the default Django __repr__() method which would return <Contact: Contact object (id)>. It is used for logging.

Returns:

The canonical string representation of the page

Return type:

str

id

Type: BigAutoField

Primary key: ID

name

Type: CharField

Name. Name of the responsible contact person

objects = <django.db.models.Manager object>
offer_set

Type: Reverse ForeignKey from Offer

All offers of this offer contact (related name of offer_contact)

phone

Type: CharField

Phone number. Phone numbner of the responsible contact person

Location

class integreat_compass.cms.models.organizations.location.Location(*args, **kwargs)

Bases: AbstractBaseModel

Data model representing a Location.

Parameters:

Reverse relationships:

Parameters:

offer (Reverse ForeignKey from Offer) – All offers of this location (related name of location)

exception DoesNotExist

Bases: ObjectDoesNotExist

exception MultipleObjectsReturned

Bases: MultipleObjectsReturned

address

Type: TextField

Address. Physical location where the offer takes place

get_repr()

This overwrites the default Django __repr__() method which would return <Location: Location object (id)>. It is used for logging.

Returns:

The canonical string representation of the page

Return type:

str

id

Type: BigAutoField

Primary key: ID

lat

Type: DecimalField

Latitude

long

Type: DecimalField

Longitude

objects = <django.db.models.Manager object>
offer_set

Type: Reverse ForeignKey from Offer

All offers of this location (related name of location)

Organization

class integreat_compass.cms.models.organizations.organization.Organization(*args, **kwargs)

Bases: AbstractBaseModel

Data model representing an Organization (Offer Provider).

Parameters:
  • id (BigAutoField) – Primary key: ID

  • name (CharField) – Organization name. Name of the organization

  • web_address (URLField) – Website. URL of the website or social media of the organization

Relationship fields:

Parameters:

creator (ForeignKey to User) – Creator (related name: organization)

Reverse relationships:

Parameters:

offer (Reverse ForeignKey from Offer) – All offers of this organization (related name of organization)

exception DoesNotExist

Bases: ObjectDoesNotExist

exception MultipleObjectsReturned

Bases: MultipleObjectsReturned

creator

Type: ForeignKey to User

Creator (related name: organization)

creator_id

Internal field, use creator instead.

get_repr()

This overwrites the default Django __repr__() method which would return <Organization: Organization object (id)>. It is used for logging.

Returns:

The canonical string representation of the page

Return type:

str

id

Type: BigAutoField

Primary key: ID

name

Type: CharField

Organization name. Name of the organization

objects = <django.db.models.Manager object>
offer_set

Type: Reverse ForeignKey from Offer

All offers of this organization (related name of organization)

web_address

Type: URLField

Website. URL of the website or social media of the organization