Skip to content

Projects

Intro

Projects form part of OPTTs (Objectives Projects Tasks and Targets).

Projects belong to organisations and have a specific owner user and a specific creator user (automatically inferred at creation time). They can run from any date and have a duration of no more than 26 weeks. Other than the date constraints, they are identical to objectives.

Observers

  • When saving a project, its ending_date field is calculated based on the inputted data (starting_date, duration_weeks).
  • When saving a project, its energy_points field is calculated based on duration_weeks and the configured flowcode.energy_points_project_multiplier

Jobs

  • UpdateProjectStatus is a job which updates the status of the project based on whether it's overdue.

Relationships

Projects have several key relationships:

  • Belongs to owner - this is a manually edited required field
  • Belongs to creator - this is automatically inferred by the user creating the project
  • Belongs to organisation - this is automatically inferred by the creator's active organisation

Relationships used for frontend filtering:

  • Belongs to many departments (Department)
  • Belongs to many division (Division)
  • Belongs to owner

Other relationships which are not yet used elsewhere in the app (at the time of writing 03/2023):

These relationships aren't yet used other than to display in the project modal, but may serve some future purposes in the roadmap

  • Belongs to many contributors (User)
  • Has many milestones (Milestone)
  • Has many budgets (Budget)
  • Has many recruitments (Recruitment)
  • Has many risks (Risks)
  • Has many linkedOptts (LinkedOptt)

Relationship to elements. This is used when an OPTT is created on the fly while completing the catalogues:

  • Belongs to many elements (Element)