27require
'../../../main.inc.php';
28require_once DOL_DOCUMENT_ROOT.
'/product/stock/stocktransfer/class/stocktransfer.class.php';
29require_once DOL_DOCUMENT_ROOT.
'/product/stock/stocktransfer/lib/stocktransfer_stocktransfer.lib.php';
40$langs->loadLangs(array(
"stocks",
"companies"));
45$action =
GETPOST(
'action',
'alpha');
47$backtopage =
GETPOST(
'backtopage',
'alpha');
52$diroutputmassaction =
$conf->stocktransfer->dir_output.
'/temp/massgeneration/'.$user->id;
53$hookmanager->initHooks(array(
'stocktransfernote',
'globalcard'));
55$extrafields->fetch_name_optionals_label(
$object->table_element);
58include DOL_DOCUMENT_ROOT.
'/core/actions_fetchobject.inc.php';
59if ($id > 0 || !empty($ref)) {
63$permissiontoread = $user->hasRight(
'stocktransfer',
'stocktransfer',
'read');
64$permissionnote = $user->hasRight(
'stocktransfer',
'stocktransfer',
'write');
65$permissiontoadd = $user->hasRight(
'stocktransfer',
'stocktransfer',
'write');
68restrictedArea($user,
'stocktransfer',
$object->id,
'stocktransfer_stocktransfer',
'stocktransfer',
'fk_soc',
'rowid');
69if (!$permissiontoread) {
79include DOL_DOCUMENT_ROOT.
'/core/actions_setnotes.inc.php';
90llxHeader(
'', $langs->trans(
'ModuleStockTransferName'), $help_url,
'', 0, 0,
'',
'',
'',
'mod-product page-stock-stocktransfer_stocktransfer_note');
92if ($id > 0 || !empty($ref)) {
101 $linkback =
'<a href="'.dol_buildpath(
'/stocktransfer/stocktransfer_list.php', 1).
'?restore_lastsearch_values=1'.(!empty($socid) ?
'&socid='.$socid :
'').
'">'.$langs->trans(
"BackToList").
'</a>';
103 $morehtmlref =
'<div class="refidno">';
141 $morehtmlref .=
'</div>';
144 dol_banner_tab($object,
'ref', $linkback, 1,
'ref',
'ref', $morehtmlref);
147 print
'<div class="fichecenter">';
148 print
'<div class="underbanner clearboth"></div>';
151 $cssclass =
"titlefield";
152 include DOL_DOCUMENT_ROOT.
'/core/tpl/notes.tpl.php';
$id
Support class for third parties, contacts, members, users or resources.
if(! $sortfield) if(! $sortorder) $object
llxFooter($comment='', $zone='private', $disabledoutputofmessages=0)
Empty footer.
if(!defined('NOREQUIRESOC')) if(!defined( 'NOREQUIRETRAN')) if(!defined('NOTOKENRENEWAL')) if(!defined( 'NOREQUIREMENU')) if(!defined('NOREQUIREHTML')) if(!defined( 'NOREQUIREAJAX')) llxHeader($head='', $title='', $help_url='', $target='', $disablejs=0, $disablehead=0, $arrayofjs='', $arrayofcss='', $morequerystring='', $morecssonbody='', $replacemainareaby='', $disablenofollow=0, $disablenoindex=0)
Empty header.
dol_get_fiche_head($links=array(), $active='', $title='', $notab=0, $picto='', $pictoisfullpath=0, $morehtmlright='', $morecss='', $limittoshow=0, $moretabssuffix='', $dragdropfile=0, $morecssdiv='')
Show tabs of a record.
dol_get_fiche_end($notab=0)
Return tab footer of a card.
GETPOST($paramname, $check='alphanohtml', $method=0, $filter=null, $options=null, $noreplace=0, $nodefault=0)
Return value of a param into GET or POST supervariable.
GETPOSTINT($paramname, $method=0, $nodefault=0)
Return the value of a $_GET or $_POST supervariable, converted into integer.
restrictedArea(User $user, $features, $object=0, $tableandshare='', $feature2='', $dbt_keyfield='fk_soc', $dbt_select='rowid', $isdraft=0, $mode=0)
Check permissions of a user to show a page and an object.
accessforbidden($message='', $printheader=1, $printfooter=1, $showonlymessage=0, $params=null)
Show a message to say access is forbidden and stop program.
stocktransferPrepareHead($object)
Prepare array of tabs for StockTransfer.