34 global $langs, $conf, $user;
37 $langs->loadLangs(array(
'categories',
'products'));
42 $head[$h][0] = DOL_URL_ROOT.
'/categories/viewcat.php?id='.
$object->id.
'&type='.$type;
43 $head[$h][1] = $langs->trans(
"Category");
44 $head[$h][2] =
'card';
47 $head[$h][0] = DOL_URL_ROOT.
'/categories/photos.php?id='.
$object->id.
'&type='.$type;
48 $head[$h][1] = $langs->trans(
"Photos");
49 $head[$h][2] =
'photos';
53 $head[$h][0] = DOL_URL_ROOT.
'/categories/traduction.php?id='.
$object->id.
'&type='.$type;
54 $head[$h][1] = $langs->trans(
"Translation");
55 $head[$h][2] =
'translation';
59 $head[$h][0] = DOL_URL_ROOT.
'/categories/info.php?id='.
$object->id.
'&type='.$type;
60 $head[$h][1] = $langs->trans(
"Info");
61 $head[$h][2] =
'info';
83 global $langs, $conf, $user, $db;
86 $extrafields->fetch_name_optionals_label(
'categorie');
88 $langs->load(
"categories");
93 $head[$h][0] = DOL_URL_ROOT.
'/categories/admin/categorie.php';
94 $head[$h][1] = $langs->trans(
"Setup");
95 $head[$h][2] =
'setup';
98 $head[$h][0] = DOL_URL_ROOT.
'/categories/admin/categorie_extrafields.php';
99 $head[$h][1] = $langs->trans(
"ExtraFieldsCategories");
100 $nbExtrafields = $extrafields->attributes[
'categorie'][
'count'];
101 if ($nbExtrafields > 0) {
102 $head[$h][1] .=
'<span class="badge marginleftonlyshort">'.$nbExtrafields.
'</span>';
104 $head[$h][2] =
'attributes_categories';
if( $user->socid > 0) if(! $user->hasRight('accounting', 'chartofaccount')) $object
categories_prepare_head(Categorie $object, $type)
Prepare array with list of tabs.
categoriesadmin_prepare_head()
Prepare array with list of tabs.
Class to manage categories.
getDolGlobalInt($key, $default=0)
Return a Dolibarr global constant int value.
complete_head_from_modules($conf, $langs, $object, &$head, &$h, $type, $mode='add', $filterorigmodule='')
Complete or removed entries into a head array (used to build tabs).