normalize code
This commit is contained in:
parent
ea077e959b
commit
e21e08717e
@ -29,6 +29,7 @@
|
||||
|
||||
require '../main.inc.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/fourn.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.facture.class.php';
|
||||
|
||||
@ -197,20 +198,9 @@ print_fiche_titre($langs->trans("SuppliersSetup"),$linkback,'setup');
|
||||
|
||||
print "<br>";
|
||||
|
||||
$h = 0;
|
||||
$head = supplierorder_admin_prepare_head(null);
|
||||
|
||||
$head[$h][0] = DOL_URL_ROOT."/admin/supplier_order.php";
|
||||
$head[$h][1] = $langs->trans("SupplierOrder");
|
||||
$head[$h][2] = 'Order';
|
||||
$h++;
|
||||
|
||||
$head[$h][0] = DOL_URL_ROOT."/admin/supplier_invoice.php";
|
||||
$head[$h][1] = $langs->trans("SuppliersInvoice");
|
||||
$head[$h][2] = 'Invoice';
|
||||
$hselected=$h;
|
||||
$h++;
|
||||
|
||||
dol_fiche_head($head, $hselected, $langs->trans("ModuleSetup"));
|
||||
dol_fiche_head($head, 'invoice', $langs->trans("ModuleSetup"));
|
||||
|
||||
|
||||
// Supplier invoice numbering module
|
||||
|
||||
@ -29,6 +29,7 @@
|
||||
|
||||
require '../main.inc.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/fourn.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.commande.class.php';
|
||||
|
||||
@ -197,21 +198,9 @@ print_fiche_titre($langs->trans("SuppliersSetup"),$linkback,'setup');
|
||||
|
||||
print "<br>";
|
||||
|
||||
$h = 0;
|
||||
$head = supplierorder_admin_prepare_head(null);
|
||||
|
||||
$head[$h][0] = DOL_URL_ROOT."/admin/supplier_order.php";
|
||||
$head[$h][1] = $langs->trans("SupplierOrder");
|
||||
$head[$h][2] = 'Order';
|
||||
$hselected=$h;
|
||||
$h++;
|
||||
|
||||
$head[$h][0] = DOL_URL_ROOT."/admin/supplier_invoice.php";
|
||||
$head[$h][1] = $langs->trans("SuppliersInvoice");
|
||||
$head[$h][2] = 'Invoice';
|
||||
|
||||
$h++;
|
||||
|
||||
dol_fiche_head($head, $hselected, $langs->trans("ModuleSetup"));
|
||||
dol_fiche_head($head, 'order', $langs->trans("ModuleSetup"));
|
||||
|
||||
|
||||
// Supplier order numbering module
|
||||
|
||||
@ -2,6 +2,7 @@
|
||||
/* Copyright (C) 2005-2009 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@capnetworks.com>
|
||||
* Copyright (C) 2006 Marc Barilley <marc@ocebo.com>
|
||||
* Copyright (C) 2011-2013 Philippe Grand <philippe.grand@atoo-net.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@ -148,5 +149,35 @@ function ordersupplier_prepare_head($object)
|
||||
return $head;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return array head with list of tabs to view object informations.
|
||||
*
|
||||
* @param Object $object order
|
||||
* @return array head array with tabs
|
||||
*/
|
||||
function supplierorder_admin_prepare_head($object)
|
||||
{
|
||||
global $langs, $conf, $user;
|
||||
|
||||
$h = 0;
|
||||
$head = array();
|
||||
|
||||
$head[$h][0] = DOL_URL_ROOT."/admin/supplier_order.php";
|
||||
$head[$h][1] = $langs->trans("SupplierOrder");
|
||||
$head[$h][2] = 'order';
|
||||
$h++;
|
||||
|
||||
complete_head_from_modules($conf,$langs,$object,$head,$h,'supplierorder_admin');
|
||||
|
||||
$head[$h][0] = DOL_URL_ROOT."/admin/supplier_invoice.php";
|
||||
$head[$h][1] = $langs->trans("SuppliersInvoice");
|
||||
$head[$h][2] = 'invoice';
|
||||
$h++;
|
||||
|
||||
complete_head_from_modules($conf,$langs,$object,$head,$h,'supplierorder_admin','remove');
|
||||
|
||||
return $head;
|
||||
}
|
||||
|
||||
|
||||
?>
|
||||
Loading…
Reference in New Issue
Block a user