34 global $langs,
$conf, $user;
39 $head[$h][0] = DOL_URL_ROOT.
'/product/stock/card.php?id='.
$object->id;
40 $head[$h][1] = $langs->trans(
"Warehouse");
41 $head[$h][2] =
'card';
44 if ($user->hasRight(
'stock',
'mouvement',
'lire')) {
45 $head[$h][0] = DOL_URL_ROOT.
'/product/stock/movement_list.php?id='.
$object->id;
46 $head[$h][1] = $langs->trans(
"StockMovements");
47 $head[$h][2] =
'movements';
75 $head[$h][0] = DOL_URL_ROOT.
'/product/stock/info.php?id='.
$object->id;
76 $head[$h][1] = $langs->trans(
"Info");
77 $head[$h][2] =
'info';
94 global $langs,
$conf, $user, $extrafields;
96 $extrafields->fetch_name_optionals_label(
'entrepot');
97 $extrafields->fetch_name_optionals_label(
'stock_mouvement');
98 $extrafields->fetch_name_optionals_label(
'inventory');
103 $head[$h][0] = DOL_URL_ROOT.
'/admin/stock.php';
104 $head[$h][1] = $langs->trans(
"Miscellaneous");
105 $head[$h][2] =
'general';
112 $head[$h][0] = DOL_URL_ROOT.
'/admin/inventory.php';
113 $head[$h][1] = $langs->trans(
"Inventory");
114 $head[$h][2] =
'inventory';
119 $head[$h][0] =
dolBuildUrl(DOL_URL_ROOT.
'/admin/extrafields.php', array(
'elementtype' =>
'entrepot'));
120 $head[$h][1] = $langs->trans(
"StockSetupExtraFields");
121 $nbExtrafields = $extrafields->attributes[
'entrepot'][
'count'];
122 if ($nbExtrafields > 0) {
123 $head[$h][1] .=
'<span class="badge marginleftonlyshort">'.$nbExtrafields.
'</span>';
125 $head[$h][2] =
'attributes';
128 $head[$h][0] =
dolBuildUrl(DOL_URL_ROOT.
'/admin/extrafields.php', array(
'elementtype' =>
'stock_mouvement'));
129 $head[$h][1] = $langs->trans(
"StockMouvementExtraFields");
130 $nbExtrafields = $extrafields->attributes[
'stock_mouvement'][
'count'];
131 if ($nbExtrafields > 0) {
132 $head[$h][1] .=
'<span class="badge marginleftonlyshort">'.$nbExtrafields.
'</span>';
134 $head[$h][2] =
'stockMouvementAttributes';
137 $head[$h][0] =
dolBuildUrl(DOL_URL_ROOT.
'/admin/extrafields.php', array(
'elementtype' =>
'inventory'));
138 $head[$h][1] = $langs->trans(
"InventoryExtraFields");
139 $nbExtrafields = $extrafields->attributes[
'inventory'][
'count'];
140 if ($nbExtrafields > 0) {
141 $head[$h][1] .=
'<span class="badge marginleftonlyshort">'.$nbExtrafields.
'</span>';
143 $head[$h][2] =
'inventoryAttributes';
if(! $sortfield) if(! $sortorder) $object
dolBuildUrl($url, $params=[], $addtoken=false, $anchor='')
Return path of url.
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).
stock_admin_prepare_head()
Return array head with list of tabs to view object information.
stock_prepare_head($object)
Prepare array with list of tabs.