Features Models in SailPilot

The Features models in SailPilot’s backend are central to the mapping and navigational features of the application. These models store and manage data related to navigational points of interest, attributes, and categorization.

AttributeGroups Model

The AttributeGroups model categorizes different attributes that can be assigned to navigational points. It includes fields for names in different languages and a sort order.

  • Fields: name_en, name_el for English and Greek names, and sort_order.

  • Database Table: Uses a custom database table attribute_groups.

Attributes Model

The Attributes model represents specific attributes that can be associated with navigational points. It is linked to AttributeGroups for categorization purposes.

  • Fields: Includes attribute_group, code, name_en, name_el, and sort_order.

  • Relation: Has a foreign key relationship with the AttributeGroups model.

  • Database Table: Uses a custom database table attributes.

TypeCategories Model

The TypeCategories model organizes different types of navigational points into categories.

  • Fields: name_en, name_el for English and Greek names, and sort_order.

  • Database Table: Uses a custom database table type_categories.

FeatureTypes Model

The FeatureTypes model defines various types of navigational features, each associated with a category from TypeCategories.

  • Fields: Includes category, name_en, name_el, icon, is_base, and is_free.

  • Relation: Linked to TypeCategories via a foreign key.

  • Database Table: Uses a custom database table feature_types.

TypeAttributeGroups Model

The TypeAttributeGroups model links FeatureTypes with AttributeGroups, defining which attributes are applicable to specific point types.

  • Relation: Connects FeatureTypes and AttributeGroups via foreign keys.

  • Database Table: Uses a custom database table type_attribute_groups.

Features Model

The Features model is key to storing navigational point data like coordinates and associated information.

  • Fields: Includes title, type, geographical coordinates, and timestamps.

  • Relation: Linked to FeatureTypes for categorizing points.

  • Database Table: Uses a custom database table features.

FeatureTranslations Model

The FeatureTranslations model stores translations for navigational features, facilitating multilingual support.

  • Fields: feature, language, and translations for various textual fields.

  • Relation: Linked to Features via a foreign key.

  • Database Table: Uses a custom database table feature_translations.

FeatureAttributes Model

The FeatureAttributes model associates specific attributes from Attributes with navigational features.

  • Relation: Connects Features with Attributes.

  • Database Table: Uses a custom database table feature_attributes.

FeatureLibraries Model

The FeatureLibraries model manages the storage details for navigational features, including file paths and versioning.

  • Fields: Includes name, version, file_path, and metadata about the stored data.

  • Database Table: Uses a custom database table feature_libraries.

Indices and tables