diff --git a/ChangeLog b/ChangeLog index 6a076df6cfcba2f9a89d24f19c54e4d0dce5d393..34ac811e0b0dbf81b9b0f1bedac167541674b563 100644 --- a/ChangeLog +++ b/ChangeLog @@ -5,6 +5,7 @@ English Dolibarr ChangeLog ***** ChangeLog for 3.7 compared to 3.6.* ***** For users: +- New: Add proposals into referer page of thirdparty. - New: On contact list can set filter on both active and not active (no more exclusive select). - New: Each user can include its own external ics calendar into dolibarr agenda view. - New: Intervention documents are now available in ECM module. diff --git a/htdocs/societe/consumption.php b/htdocs/societe/consumption.php index 776ea1fd3555ecc624459ce4941dce16c1a7af16..91453c877a70dac7ed0a5777ae611870a30b3094 100644 --- a/htdocs/societe/consumption.php +++ b/htdocs/societe/consumption.php @@ -131,8 +131,9 @@ if ($object->client) $obj = $db->fetch_object($resql); $nbFactsClient = $obj->nb; $thirdTypeArray['customer']=$langs->trans("customer"); - if($conf->facture->enabled && $user->rights->facture->lire) $elementTypeArray['invoice']=$langs->trans('Invoices'); if ($conf->commande->enabled && $user->rights->commande->lire) $elementTypeArray['order']=$langs->trans('Orders'); + if ($conf->propal->enabled && $user->rights->propal->lire) $elementTypeArray['propal']=$langs->trans('Proposals'); + if ($conf->facture->enabled && $user->rights->facture->lire) $elementTypeArray['invoice']=$langs->trans('Invoices'); } if ($object->fournisseur) @@ -177,6 +178,19 @@ if ($type_element == 'invoice') $doc_number='f.facnumber'; $thirdTypeSelect='customer'; } +if ($type_element == 'propal') +{ + require_once DOL_DOCUMENT_ROOT.'/comm/propal/class/propal.class.php'; + $documentstatic=new Propal($db); + $sql_select = 'SELECT c.rowid as doc_id, c.ref as doc_number, \'1\' as doc_type, c.datep as datePrint, '; + $tables_from = MAIN_DB_PREFIX."propal as c,".MAIN_DB_PREFIX."propaldet as d"; + $where = " WHERE c.fk_soc = s.rowid AND s.rowid = ".$socid; + $where.= " AND d.fk_propal = c.rowid"; + $where.= " AND c.entity = ".$conf->entity; + $datePrint = 'c.datep'; + $doc_number='c.ref'; + $thirdTypeSelect='customer'; +} if ($type_element == 'order') { require_once DOL_DOCUMENT_ROOT.'/commande/class/commande.class.php';