diff --git a/htdocs/comm/action/class/actioncomm.class.php b/htdocs/comm/action/class/actioncomm.class.php index 119f76b8ece..761e81b641c 100644 --- a/htdocs/comm/action/class/actioncomm.class.php +++ b/htdocs/comm/action/class/actioncomm.class.php @@ -277,6 +277,7 @@ class ActionComm extends CommonObject $this->priority = $obj->priority; $this->location = $obj->location; + $this->socid = $obj->fk_soc; // To have fetch_thirdparty method working $this->societe->id = $obj->fk_soc; $this->contact->id = $obj->fk_contact; $this->fk_project = $obj->fk_project; diff --git a/htdocs/commande/fiche.php b/htdocs/commande/fiche.php index 18aa95f5720..8634fffb47f 100644 --- a/htdocs/commande/fiche.php +++ b/htdocs/commande/fiche.php @@ -395,7 +395,7 @@ if ($_POST['action'] == 'addline' && $user->rights->commande->creer) $prod->fetch($_POST['idprod']); $tva_tx = get_default_tva($mysoc,$commande->client,$prod->tva_tx); - + // multiprix if ($conf->global->PRODUIT_MULTIPRICES && $commande->client->price_level) { @@ -437,11 +437,11 @@ if ($_POST['action'] == 'addline' && $user->rights->commande->creer) $desc=$_POST['dp_desc']; $type=$_POST["type"]; } - + // Local Taxes $localtax1_tx= get_localtax($tva_tx, 1, $commande->client); $localtax2_tx= get_localtax($tva_tx, 2, $commande->client); - + $desc=dol_htmlcleanlastbr($desc); $info_bits=0; @@ -1038,7 +1038,7 @@ if ($_GET['action'] == 'create' && $user->rights->commande->creer) print ''; // Reference - print ''; + print ''; // Reference client print ''; // Client - print ''; + print ''; /* * Contact de la commande @@ -1601,6 +1601,7 @@ else if ($_GET['action'] != 'classer') print ''; print '
'.$langs->trans('Ref').''.$langs->trans("Draft").'
'.$langs->trans('Ref').''.$langs->trans("Draft").'
'.$langs->trans('RefCustomer').''; @@ -1046,7 +1046,7 @@ if ($_GET['action'] == 'create' && $user->rights->commande->creer) print '
'.$langs->trans('Customer').''.$soc->getNomUrl(1).'
'.$langs->trans('Customer').''.$soc->getNomUrl(1).'
'.img_edit($langs->trans('SetProject')).'
'; print ''; + //print "$commande->id, $commande->socid, $commande->fk_project"; if ($_GET['action'] == 'classer') { $html->form_project($_SERVER['PHP_SELF'].'?id='.$commande->id, $commande->socid, $commande->fk_project, 'projectid'); diff --git a/htdocs/compta/deplacement/class/deplacement.class.php b/htdocs/compta/deplacement/class/deplacement.class.php index 31241c68302..6c7d4d2be64 100644 --- a/htdocs/compta/deplacement/class/deplacement.class.php +++ b/htdocs/compta/deplacement/class/deplacement.class.php @@ -305,7 +305,7 @@ class Deplacement extends CommonObject $result=''; - $lien = ''; + $lien = ''; $lienfin=''; $picto='trip'; diff --git a/htdocs/core/class/html.form.class.php b/htdocs/core/class/html.form.class.php index d74b6bfa7f0..09a0c6bac49 100644 --- a/htdocs/core/class/html.form.class.php +++ b/htdocs/core/class/html.form.class.php @@ -1802,6 +1802,7 @@ class Form print ''; print ''; print ''; print ''; diff --git a/htdocs/fourn/commande/fiche.php b/htdocs/fourn/commande/fiche.php index cdf5a63ea22..5a8050478f1 100644 --- a/htdocs/fourn/commande/fiche.php +++ b/htdocs/fourn/commande/fiche.php @@ -816,7 +816,6 @@ if ($id > 0 || ! empty($ref)) } /* * Confirmation de la desapprobation - * */ if ($_GET['action'] == 'refuse') { @@ -907,12 +906,12 @@ if ($id > 0 || ! empty($ref)) } } - // Auteur + // Author print ''; print ''; print ''; - // Projet + // Project if ($conf->projet->enabled) { $langs->load('projects'); @@ -923,6 +922,7 @@ if ($id > 0 || ! empty($ref)) if ($_GET['action'] != 'classer') print ''; print '
'; + //print "$socid,$selected,$htmlname"; select_projects($socid,$selected,$htmlname); print '
'.$langs->trans("AuthorRequest").''.$author->getNomUrl(1).'
'.img_edit($langs->trans('SetProject')).'
'; print ''; + //print "$commande->id, $commande->socid, $commande->fk_project"; if ($_GET['action'] == 'classer') { $html->form_project($_SERVER['PHP_SELF'].'?id='.$commande->id, $commande->socid, $commande->fk_project, 'projectid'); diff --git a/htdocs/fourn/facture/fiche.php b/htdocs/fourn/facture/fiche.php index 960fa9935fe..d3422b90691 100644 --- a/htdocs/fourn/facture/fiche.php +++ b/htdocs/fourn/facture/fiche.php @@ -505,10 +505,10 @@ if ($_GET['action'] == 'create') print ''; // Third party - print ''; + print ''; print ''; print ''; - print ''; + // Ref supplier + print ''; print ''; + // Label print ''; // Date invoice - print ''; @@ -598,7 +600,7 @@ else print '
'.$langs->trans('Company').'
'.$langs->trans('Company').''; - if ($_GET['socid']) + if ($_REQUEST['socid'] > 0) { print $societe->getNomUrl(1); print ''; @@ -520,13 +520,15 @@ if ($_GET['action'] == 'create') print ''.$langs->trans('NotePublic').'
'.$langs->trans('RefSupplier').'
'.$langs->trans('RefSupplier').'
'.$langs->trans('Label').'
'.$langs->trans('DateInvoice').''; + print '
'.$langs->trans('DateInvoice').''; $html->select_date($dateinvoice,'','','','',"add",1,1); print '
'; - print ''; + print ''; print ''; print ''; print ''; @@ -612,14 +614,17 @@ else print $fac->note; print ''; - print ''; print ''; + // Label print ''; - print ''; diff --git a/htdocs/projet/class/project.class.php b/htdocs/projet/class/project.class.php index bc5d49110f9..78058b02216 100644 --- a/htdocs/projet/class/project.class.php +++ b/htdocs/projet/class/project.class.php @@ -319,6 +319,7 @@ class Project extends CommonObject if ($type == 'agenda') $sql = "SELECT id as rowid FROM ".MAIN_DB_PREFIX."actioncomm WHERE fk_project=".$this->id; if (! $sql) return -1; + //print $sql; dol_syslog("Project::get_element_list sql=".$sql); $result=$this->db->query($sql); if ($result) diff --git a/htdocs/projet/element.php b/htdocs/projet/element.php index 873b9672415..dbc54a9d50f 100644 --- a/htdocs/projet/element.php +++ b/htdocs/projet/element.php @@ -1,6 +1,6 @@ - * Copyright (C) 2004-2009 Laurent Destailleur + * Copyright (C) 2004-2010 Laurent Destailleur * Copyright (C) 2005-2010 Regis Houssin * * This program is free software; you can redistribute it and/or modify @@ -118,7 +118,7 @@ print ''; /* - * Factures + * Referers types */ $listofreferent=array( @@ -180,8 +180,9 @@ foreach ($listofreferent as $key => $value) print '
'.$langs->trans('Company').'
'.$langs->trans('Company').''.$societe->getNomUrl(1).''.$langs->trans('NotePublic').'
'.$langs->trans('RefSupplier').''; + // Ref supplier + print '
'.$langs->trans('RefSupplier').''; print '
'.$langs->trans('Label').''; print '
'.$langs->trans('DateInvoice').''; + // Date invoice + print '
'.$langs->trans('DateInvoice').''; $html->select_date($fac->datep,'','','','',"update",1,1); print '
'; print ''; - print ''; - print ''; + print ''; + print ''; + print ''; if (empty($value['disableamount'])) print ''; print ''; print ''; @@ -194,12 +195,14 @@ foreach ($listofreferent as $key => $value) { $element = new $classname($db); $element->fetch($elementarray[$i]); + $element->fetch_client(); + //print $classname; $var=!$var; print ""; // Ref - print "\n"; @@ -207,9 +210,14 @@ foreach ($listofreferent as $key => $value) $date=$element->date; if (empty($date)) $date=$element->datep; if (empty($date)) $date=$element->date_contrat; - print ''; + print ''; - // Amount + // Third party + print ''; + + // Amount if (empty($value['disableamount'])) print ''; // Status @@ -220,7 +228,7 @@ foreach ($listofreferent as $key => $value) $total = $total + $element->total_ht; } - print ''; + print ''; if (empty($value['disableamount'])) print ''; print ''; print '';
'.$langs->trans("Ref").''.$langs->trans("Date").''.$langs->trans("Ref").''.$langs->trans("Date").''.$langs->trans("ThirdParty").''.$langs->trans("Amount").''.$langs->trans("Status").'
"; + print ''; print $element->getNomUrl(1); print "'.dol_print_date($date,'day').''.dol_print_date($date,'day').''; + if (is_object($element->client)) print $element->client->getNomUrl(1); + print ''.(isset($element->total_ht)?price($element->total_ht):' ').'
'.$langs->trans("Number").': '.$i.'
'.$langs->trans("Number").': '.$i.''.$langs->trans("TotalHT").' : '.price($total).'