3
0
Fork 0
mirror of https://github.com/farmOS/farmOS.git synced 2024-02-23 11:37:38 +01:00

Add asset/log/plan action links to farm.dashboard.

This commit is contained in:
Michael Stenta 2020-12-31 10:14:28 -05:00
parent bdb067cf47
commit d10c757bfd

View file

@ -49,6 +49,11 @@ class FarmActions extends DeriverBase {
}
}
// Add it to farm.dashboard, if the farm_dashboard module is enabled.
if (\Drupal::moduleHandler()->moduleExists('farm_dashboard')) {
$this->derivatives[$name]['appears_on'][] = 'farm.dashboard';
}
// Generate a link to [entity-type]/add/[bundle].
$name = 'farm.add.' . $type . '.bundle';
$this->derivatives[$name] = $base_plugin_definition;