For Developers

Events

There are a few events provided which mainly happen before postings or applications are being assigned to the view.

You can simply find them by taking a look into ITXJobapplicationsEvent. If you think you need more events than are already provided feel free to contact us via GitHub or E-Mail.

Custom Filters

If you want to have custom filters you can do that by performing three steps.

  1. Configure every filter you want in TypoScript settings, like the default config:

    filter {
       repositoryConfiguration {
          division {  // Relation name: This is the name you should assign the form element property and the constraint property
             relation = division // Define the relation a la Repository query e.g.: posting.contact.email
             relationType = equals // choose equals, contains or in. This depends on the given relation
          }
    
          careerLevel {
             relation = careerLevel
             relationType = equals
          }
    
          employmentType {
             relation = employmentType
             relationType = contains
          }
    
          location {
             relation = location
             relationType = contains
          }
       }
    }
    
  2. Override the Constraint model, add your custom properties with getters and setters

  3. Override the PostingController, by extending the Default one and override the function getFilterOptions() This function defines what the filterOptions are. You can write queries to find the options automatically or supply constant ones. The data generated by this function gets cached, so perfomance wont be a problem. Also remember to clear all caches after changing something in the filter options.

    // Function returns an array, matching the configured filters from above
    public function getFilterOptions($categories): array
    {
       return [
          'division' => $this->postingRepository->findAllDivisions($categories),
          'careerLevel' => $this->postingRepository->findAllCareerLevels($categories),
          'employmentType' => $this->postingRepository->findAllEmploymentTypes($categories),
          'location' => $this->locationRepository->findAll($categories)->toArray(),
       ];
    }
    
  4. Last but not least you have to edit the frontend template, so it includes your new filters. You can take the default filters as an example, but basically you have access to the filter options and the user selected filter options in variable called constraint. The controller is also preconfigured to work with both single- and multiselects.