Better use of breadcrumbs in SuiteDesk

This commit is contained in:
Manuel Cillero 2017-09-01 06:58:16 +02:00
parent 6c766c0cfb
commit b3f2e096e1
29 changed files with 62 additions and 57 deletions

View file

@ -237,10 +237,9 @@ function stormteam_storm_rewrite_where_sql($query, $primary_table, $account) {
* Implementation of hook_form().
*/
function stormteam_form(&$node) {
$breadcrumb = array(
l(t('SuiteDesk'), 'dashboard'),
l(t('Teams'), 'teams'),
);
$breadcrumb = array();
$breadcrumb[] = l(t('Home'), '<front>');
$breadcrumb[] = l(t('Teams'), 'teams');
drupal_set_breadcrumb($breadcrumb);
$type = node_get_types('type', $node);
@ -347,10 +346,9 @@ function stormteam_load($node) {
* Implementation of hook_view().
*/
function stormteam_view($node, $teaser, $page) {
$breadcrumb = array(
l(t('SuiteDesk'), 'dashboard'),
l(t('Teams'), 'teams'),
);
$breadcrumb = array();
$breadcrumb[] = l(t('Home'), '<front>');
$breadcrumb[] = l(t('Teams'), 'teams');
drupal_set_breadcrumb($breadcrumb);
return theme('stormteam_view', $node, $teaser, $page);
@ -498,9 +496,8 @@ function stormteam_list() {
// Add SuiteDesk generic CSS
drupal_add_css(drupal_get_path('module', 'storm') .'/storm.css', 'module');
$breadcrumb = array(
l(t('SuiteDesk'), 'dashboard'),
);
$breadcrumb = array();
$breadcrumb[] = l(t('Home'), '<front>');
drupal_set_breadcrumb($breadcrumb);
if (array_key_exists('name', $_GET)) {