Skip to content
This repository has been archived by the owner on Aug 8, 2018. It is now read-only.

Backends customization workflow

otar edited this page Jun 7, 2018 · 8 revisions

How to add new custom module

  • Custom Drupal modules can be added under backend-donations and backend-gifts services.
  • Custom Drupal modules must be added under web/modules/custom/ directory of backend services.

Instructions

Generate custom Druapl module for backend-donations service using Drupal concole

  1. Go to project's root directory.
  2. Run docker-compose exec be_donations ./vendor/bin/drupal generate:module --module-path="modules/custom" and follow the interactive prompt.

Generate custom Druapl module for backend-gifts service using Drupal concole

Go to project's root directory.

Run docker-compose exec be_gifts ./vendor/bin/drupal generate:module --module-path="modules/custom" and follow the interactive prompt.

Drupal console documentation can be checked here

How to add new contrib module

Needs to be defined

How to alter existing Falcon backend logic

Falcon related modules reside in modules/falcon directory and developer must never edit and customize code in it. All Falcon related modules provide (should be providing) standard Drupal API ways of overriding existing functionality, logic or features.

Instructions

  1. Find the piece of code you would like to alter under modules/falcon directory.
  2. Identify how it is implemented and find relevant ways to override/alter the implementation.
  3. Create new or edit existing custom Drupal module under modules/custom directory to override and implement your custom implementation of existing Falcon code.

Also there are many ways to override existing Drupal module implementations, here is short list of common APIs used to override different parts of the system:

How to work with Drupal configs

All Falcon based projects might have different configurations and in order to manage those configurations and prevent conflicting with Falcon's default configuration all developers should use config_split module. Config split module gives us ability to define custom/project specific configurations and export/import them safely.

Instructions

Donations Service

Clone this wiki locally