You are here

function farm_modules in farmOS 2.x

Same name and namespace in other branches
  1. 7 farm.install \farm_modules()

Define farmOS modules that can be installed.

Return value

array Returns an array with three sub-arrays: 'base', 'default' and 'optional'. Base modules will always be installed, but can be uninstalled. Default and optional modules will appear as options during farmOS installation and in a form available to admins. During initial farmOS installation, default modules will be selected by default, and optional modules will require the user to select them for installation.

1 call to farm_modules()
farm_install_modules in ./farm.install
Installs farmOS modules via a batch process.

File

./farm.profile, line 19
General functions for the farmOS installation profile.

Code

function farm_modules() {
  return [
    'base' => [
      'farm_api' => t('farmOS API'),
      'farm_login' => t('Login with username or email.'),
      'farm_settings' => t('farmOS Settings forms'),
      'farm_ui' => t('farmOS UI'),
      'farm_update' => t('farmOS Update'),
    ],
    'default' => [
      'farm_land' => t('Land assets'),
      'farm_plant' => t('Plant assets'),
      'farm_animal' => t('Animal assets'),
      'farm_equipment' => t('Equipment assets'),
      'farm_material' => t('Material assets'),
      'farm_structure' => t('Structure assets'),
      'farm_water' => t('Water assets'),
      'farm_activity' => t('Activity logs'),
      'farm_observation' => t('Observation logs'),
      'farm_seeding' => t('Seeding logs'),
      'farm_input' => t('Input logs'),
      'farm_harvest' => t('Harvest logs'),
      'farm_maintenance' => t('Maintenance logs'),
      'farm_quantity_standard' => t('Standard quantity type'),
      'farm_role_roles' => t('Default roles: Manager, Worker, Viewer'),
      'farm_land_types' => t('Default land types: Property, Field, Bed, Paddock, Landmark'),
      'farm_structure_types' => t('Default structure types: Building, Greenhouse'),
    ],
    'optional' => [
      'farm_inventory' => t('Inventory management'),
      'farm_seed' => t('Seed assets'),
      'farm_sensor' => t('Sensor assets'),
      'farm_compost' => t('Compost assets'),
      'farm_group' => t('Group assets'),
      'farm_transplanting' => t('Transplanting logs'),
      'farm_lab_test' => t('Lab test logs'),
      'farm_birth' => t('Birth logs'),
      'farm_medical' => t('Medical logs'),
      'farm_kml' => t('KML export features'),
      'farm_import_kml' => t('KML asset importer'),
      'farm_client' => t('Field Kit integration'),
    ],
  ];
}