Fix: le lien vers la fiche commande change en fonction de son statut
This commit is contained in:
parent
2fb73a14ee
commit
9b9613b486
@ -2138,16 +2138,19 @@ class Commande extends CommonObject
|
||||
/**
|
||||
\brief Renvoie nom clicable (avec eventuellement le picto)
|
||||
\param withpicto 0=Pas de picto, 1=Inclut le picto dans le lien, 2=Picto seul
|
||||
\param option Sur quoi pointe le lien
|
||||
\param option Sur quoi pointe le lien: 0,1,2,4,-1 fiche commande, 3 fiche compta commande
|
||||
\return string Chaine avec URL
|
||||
*/
|
||||
function getNomUrl($withpicto=0,$option='')
|
||||
function getNomUrl($withpicto=0,$option=0)
|
||||
{
|
||||
global $langs;
|
||||
|
||||
$result='';
|
||||
$urlOption='';
|
||||
|
||||
$lien = '<a href="'.DOL_URL_ROOT.'/compta/commande/fiche.php?id='.$this->id.'">';
|
||||
if ($option == 3) $urlOption = '/compta';
|
||||
|
||||
$lien = '<a href="'.DOL_URL_ROOT.$urlOption.'/commande/fiche.php?id='.$this->id.'">';
|
||||
$lienfin='</a>';
|
||||
|
||||
$picto='order';
|
||||
|
||||
@ -2,6 +2,7 @@
|
||||
/* Copyright (C) 2001-2005 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||
* Copyright (C) 2004-2006 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2005 Marc Barilley / Ocebo <marc@ocebo.com>
|
||||
* Copyright (C) 2005-2007 Regis Houssin <regis@dolibarr.fr>
|
||||
*
|
||||
* 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
|
||||
@ -18,7 +19,6 @@
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
* $Id$
|
||||
* $Source$
|
||||
*/
|
||||
|
||||
/**
|
||||
@ -188,7 +188,7 @@ if ($resql)
|
||||
|
||||
print '<table class="nobordernopadding"><tr class="nocellnopadd">';
|
||||
print '<td width="90" class="nobordernopadding" nowrap="nowrap">';
|
||||
print $generic_commande->getNomUrl(1);
|
||||
print $generic_commande->getNomUrl(1,$objp->fk_statut);
|
||||
print '</td>';
|
||||
|
||||
print '<td width="20" class="nobordernopadding" nowrap="nowrap">';
|
||||
|
||||
Loading…
Reference in New Issue
Block a user