diff --git a/htdocs/comm/propal/document.php b/htdocs/comm/propal/document.php index 3a9f3a98e26..ba373c78f44 100644 --- a/htdocs/comm/propal/document.php +++ b/htdocs/comm/propal/document.php @@ -4,6 +4,7 @@ * Copyright (C) 2005 Marc Barilley / Ocebo * Copyright (C) 2005-2012 Regis Houssin * Copyright (C) 2013 Cédric Salvador + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -31,6 +32,9 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/propal.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/images.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load('compta'); $langs->load('other'); diff --git a/htdocs/comm/propal/info.php b/htdocs/comm/propal/info.php index a94eeaa092c..67cc8210402 100644 --- a/htdocs/comm/propal/info.php +++ b/htdocs/comm/propal/info.php @@ -2,6 +2,7 @@ /* Copyright (C) 2004 Rodolphe Quiedeville * Copyright (C) 2004-2006 Laurent Destailleur * Copyright (C) 2005-2012 Regis Houssin + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -27,6 +28,9 @@ require '../../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php'; require_once DOL_DOCUMENT_ROOT.'/comm/propal/class/propal.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/propal.lib.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load('propal'); $langs->load('compta'); diff --git a/htdocs/comm/propal/note.php b/htdocs/comm/propal/note.php index 29fc43b0899..17e53b89948 100644 --- a/htdocs/comm/propal/note.php +++ b/htdocs/comm/propal/note.php @@ -4,6 +4,7 @@ * Copyright (C) 2004 Eric Seigne * Copyright (C) 2005-2012 Regis Houssin * Copyright (C) 2013 Florian Henry + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -28,6 +29,9 @@ require '../../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/comm/propal/class/propal.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/propal.lib.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load('propal'); $langs->load('compta'); diff --git a/htdocs/commande/document.php b/htdocs/commande/document.php index d69ec07360a..ee688bed307 100644 --- a/htdocs/commande/document.php +++ b/htdocs/commande/document.php @@ -4,6 +4,7 @@ * Copyright (C) 2005 Marc Barilley / Ocebo * Copyright (C) 2005-2012 Regis Houssin * Copyright (C) 2013 Cédric Salvador + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -31,6 +32,9 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/images.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php'; require_once DOL_DOCUMENT_ROOT .'/commande/class/commande.class.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load('companies'); diff --git a/htdocs/commande/info.php b/htdocs/commande/info.php index 05adc9def54..518ab856474 100644 --- a/htdocs/commande/info.php +++ b/htdocs/commande/info.php @@ -1,6 +1,7 @@ * Copyright (C) 2005-2009 Regis Houssin + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -26,6 +27,9 @@ require '../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php'; require_once DOL_DOCUMENT_ROOT.'/commande/class/commande.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/order.lib.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} if (!$user->rights->commande->lire) accessforbidden(); diff --git a/htdocs/commande/note.php b/htdocs/commande/note.php index 0d42cc69611..6598805490d 100644 --- a/htdocs/commande/note.php +++ b/htdocs/commande/note.php @@ -3,6 +3,7 @@ * Copyright (C) 2004-2016 Laurent Destailleur * Copyright (C) 2005-2012 Regis Houssin * Copyright (C) 2013 Florian Henry + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -27,6 +28,9 @@ require '../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/order.lib.php'; require_once DOL_DOCUMENT_ROOT .'/commande/class/commande.class.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load("companies"); diff --git a/htdocs/compta/facture/contact.php b/htdocs/compta/facture/contact.php index 5ac71ef03ca..2c95366f9a9 100644 --- a/htdocs/compta/facture/contact.php +++ b/htdocs/compta/facture/contact.php @@ -3,6 +3,7 @@ * Copyright (C) 2005-2009 Destailleur Laurent * Copyright (C) 2005-2012 Regis Houssin * Copyright (C) 2011-2015 Philippe Grand + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -30,6 +31,9 @@ require_once DOL_DOCUMENT_ROOT.'/contact/class/contact.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/discount.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/invoice.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formcompany.class.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load("bills"); $langs->load("companies"); diff --git a/htdocs/compta/facture/document.php b/htdocs/compta/facture/document.php index c25c6efd688..8b76f9b167f 100644 --- a/htdocs/compta/facture/document.php +++ b/htdocs/compta/facture/document.php @@ -4,6 +4,7 @@ * Copyright (C) 2005 Marc Barilley / Ocebo * Copyright (C) 2005-2011 Regis Houssin * Copyright (C) 2013 Cédric Salvador + * Copyright (C) 2017 Ferran Marcet * Copyright (C) 2017 Frédéric France * * This program is free software; you can redistribute it and/or modify @@ -33,6 +34,9 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/invoice.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/images.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load('propal'); $langs->load('compta'); diff --git a/htdocs/compta/facture/info.php b/htdocs/compta/facture/info.php index 49e5e77e7be..00272fee9b3 100644 --- a/htdocs/compta/facture/info.php +++ b/htdocs/compta/facture/info.php @@ -1,6 +1,7 @@ * Copyright (C) 2004-2005 Laurent Destailleur + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -27,6 +28,9 @@ require_once DOL_DOCUMENT_ROOT.'/compta/facture/class/facture.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/discount.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/invoice.lib.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load("companies"); $langs->load("bills"); diff --git a/htdocs/compta/facture/note.php b/htdocs/compta/facture/note.php index 3428ccddd4b..755ac413743 100644 --- a/htdocs/compta/facture/note.php +++ b/htdocs/compta/facture/note.php @@ -3,6 +3,7 @@ * Copyright (C) 2004-2016 Laurent Destailleur * Copyright (C) 2005-2012 Regis Houssin * Copyright (C) 2013 Florian Henry + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -28,6 +29,9 @@ require '../../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/compta/facture/class/facture.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/discount.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/invoice.lib.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load("companies"); $langs->load("bills"); diff --git a/htdocs/compta/facture/prelevement.php b/htdocs/compta/facture/prelevement.php index cdeda46b768..e4a4c69168b 100644 --- a/htdocs/compta/facture/prelevement.php +++ b/htdocs/compta/facture/prelevement.php @@ -4,6 +4,7 @@ * Copyright (C) 2004-2016 Laurent Destailleur * Copyright (C) 2005-2012 Regis Houssin * Copyright (C) 2010-2014 Juanjo Menent + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -30,6 +31,9 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/invoice.lib.php'; require_once DOL_DOCUMENT_ROOT.'/compta/facture/class/facture.class.php'; require_once DOL_DOCUMENT_ROOT.'/compta/prelevement/class/bonprelevement.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/discount.class.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} if (!$user->rights->facture->lire) accessforbidden(); diff --git a/htdocs/compta/paiement.php b/htdocs/compta/paiement.php index dcfb85af954..f2e1352cdbb 100644 --- a/htdocs/compta/paiement.php +++ b/htdocs/compta/paiement.php @@ -102,7 +102,7 @@ if (empty($reshook)) $tmpinvoice=new Facture($db); foreach ($_POST as $key => $value) { - if (substr($key,0,7) == 'amount_') + if (substr($key,0,7) == 'amount_' && GETPOST($key) != '') { $cursorfacid = substr($key,7); $amounts[$cursorfacid] = price2num(trim(GETPOST($key))); diff --git a/htdocs/contact/list.php b/htdocs/contact/list.php index dc3ec1c458b..4ef343c3c02 100644 --- a/htdocs/contact/list.php +++ b/htdocs/contact/list.php @@ -49,27 +49,30 @@ $result = restrictedArea($user, 'contact', $contactid,''); $sall=trim((GETPOST('search_all', 'alphanohtml')!='')?GETPOST('search_all', 'alphanohtml'):GETPOST('sall', 'alphanohtml')); $search_cti=preg_replace('/^0+/', '', preg_replace('/[^0-9]/', '', GETPOST('search_cti', 'alphanohtml'))); // Phone number without any special chars -$search_phone=GETPOST("search_phone"); +$search_phone=GETPOST("search_phone",'alpha'); $search_id=trim(GETPOST("search_id","int")); -$search_firstlast_only=GETPOST("search_firstlast_only"); -$search_lastname=GETPOST("search_lastname"); -$search_firstname=GETPOST("search_firstname"); -$search_societe=GETPOST("search_societe"); -$search_poste=GETPOST("search_poste"); -$search_phone_perso=GETPOST("search_phone_perso"); -$search_phone_pro=GETPOST("search_phone_pro"); -$search_phone_mobile=GETPOST("search_phone_mobile"); -$search_fax=GETPOST("search_fax"); -$search_email=GETPOST("search_email"); -$search_skype=GETPOST("search_skype"); -$search_priv=GETPOST("search_priv"); +$search_firstlast_only=GETPOST("search_firstlast_only",'alpha'); +$search_lastname=GETPOST("search_lastname",'alpha'); +$search_firstname=GETPOST("search_firstname",'alpha'); +$search_societe=GETPOST("search_societe",'alpha'); +$search_poste=GETPOST("search_poste",'alpha'); +$search_phone_perso=GETPOST("search_phone_perso",'alpha'); +$search_phone_pro=GETPOST("search_phone_pro",'alpha'); +$search_phone_mobile=GETPOST("search_phone_mobile",'alpha'); +$search_fax=GETPOST("search_fax",'alpha'); +$search_email=GETPOST("search_email",'alpha'); +$search_skype=GETPOST("search_skype",'alpha'); +$search_priv=GETPOST("search_priv",'alpha'); $search_categ=GETPOST("search_categ",'int'); $search_categ_thirdparty=GETPOST("search_categ_thirdparty",'int'); $search_categ_supplier=GETPOST("search_categ_supplier",'int'); $search_status=GETPOST("search_status",'int'); $search_type=GETPOST('search_type','alpha'); -$search_import_key = GETPOST("search_import_key","alpha"); +$search_zip=GETPOST('search_zip','alpha'); +$search_town=GETPOST('search_town','alpha'); +$search_import_key=GETPOST("search_import_key","alpha"); + if ($search_status=='') $search_status=1; // always display activ customer first $optioncss = GETPOST('optioncss','alpha'); @@ -89,8 +92,6 @@ if (! $sortfield) $sortfield="p.lastname"; if (empty($page) || $page < 0) { $page = 0; } $offset = $limit * $page; -$langs->load("companies"); - $contextpage='contactlist'; $titre = (! empty($conf->global->SOCIETE_ADDRESSES_MANAGEMENT) ? $langs->trans("ListOfContacts") : $langs->trans("ListOfContactsAddresses")); if ($type == "p") @@ -296,7 +297,7 @@ if (strlen($search_poste)) $sql.= natural_search('p.poste', $search_pos if (strlen($search_phone_perso)) $sql.= natural_search('p.phone_perso', $search_phone_perso); if (strlen($search_phone_pro)) $sql.= natural_search('p.phone', $search_phone); if (strlen($search_phone_mobile)) $sql.= natural_search('p.phone_mobile', $search_phone_mobile); -if (strlen($search_fax)) $sql.= natural_search('p.phone_fax', $search_fax); +if (strlen($search_fax)) $sql.= natural_search('p.fax', $search_fax); if (strlen($search_skype)) $sql.= natural_search('p.skype', $search_skype); if (strlen($search_email)) $sql.= natural_search('p.email', $search_email); if ($search_status != '' && $search_status >= 0) $sql.= " AND p.statut = ".$db->escape($search_status); @@ -394,6 +395,7 @@ if ($search_status != '') $param.='&search_status='.urlencode($search_status if ($search_priv == '0' || $search_priv == '1') $param.="&search_priv=".urlencode($search_priv); if ($search_import_key != '') $param.='&search_import_key='.urlencode($search_import_key); if ($optioncss != '') $param.='&optioncss='.$optioncss; + // Add $param from extra fields include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_list_search_param.tpl.php'; @@ -496,12 +498,15 @@ if (! empty($arrayfields['p.firstname']['checked'])) print ''; print ''; } +<<<<<<< HEAD if (! empty($arrayfields['p.poste']['checked'])) { print ''; print ''; print ''; } +======= +>>>>>>> branch '6.0' of git@github.com:Dolibarr/dolibarr.git if (! empty($arrayfields['p.zip']['checked'])) { print ''; @@ -514,6 +519,12 @@ if (! empty($arrayfields['p.town']['checked'])) print ''; print ''; } +if (! empty($arrayfields['p.poste']['checked'])) +{ + print ''; + print ''; + print ''; +} if (! empty($arrayfields['p.phone']['checked'])) { print ''; diff --git a/htdocs/contrat/card.php b/htdocs/contrat/card.php index fb0bfe01d33..21324613bdf 100644 --- a/htdocs/contrat/card.php +++ b/htdocs/contrat/card.php @@ -1842,7 +1842,7 @@ else { $tmpaction='unactivateline'; $tmpactionpicto='playstop'; - $tmpactiontext=$langs->trans("Unactivate"); + $tmpactiontext=$langs->trans("Disable"); } if (($tmpaction=='activateline' && $user->rights->contrat->activer) || ($tmpaction=='unactivateline' && $user->rights->contrat->desactiver)) { @@ -1984,7 +1984,7 @@ else print ''; print ''.$langs->trans("Comment").''; print ''; - print '   '; + print '   '; print ''; print ''; print ''; diff --git a/htdocs/contrat/contact.php b/htdocs/contrat/contact.php index aeb433cf455..64050c3512d 100644 --- a/htdocs/contrat/contact.php +++ b/htdocs/contrat/contact.php @@ -2,6 +2,7 @@ /* Copyright (C) 2005 Patrick Rouillon * Copyright (C) 2005-2009 Destailleur Laurent * Copyright (C) 2005-2012 Regis Houssin + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -28,6 +29,9 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/contract.lib.php'; require_once DOL_DOCUMENT_ROOT.'/contrat/class/contrat.class.php'; require_once DOL_DOCUMENT_ROOT.'/contact/class/contact.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formcompany.class.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load("contracts"); diff --git a/htdocs/contrat/document.php b/htdocs/contrat/document.php index 351bdc74a46..32fcd5a64bd 100644 --- a/htdocs/contrat/document.php +++ b/htdocs/contrat/document.php @@ -5,6 +5,7 @@ * Copyright (C) 2005-2012 Regis Houssin * Copyright (C) 2005 Simon TOSSER * Copyright (C) 2013 Cédric Salvador + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -32,6 +33,9 @@ require_once DOL_DOCUMENT_ROOT.'/contrat/class/contrat.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/images.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load("other"); $langs->load("products"); diff --git a/htdocs/contrat/info.php b/htdocs/contrat/info.php index 7f5d0c103fa..10f31ac1612 100644 --- a/htdocs/contrat/info.php +++ b/htdocs/contrat/info.php @@ -1,5 +1,6 @@ + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -25,6 +26,9 @@ require ("../main.inc.php"); require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/contract.lib.php'; require_once DOL_DOCUMENT_ROOT.'/contrat/class/contrat.class.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load("contracts"); diff --git a/htdocs/contrat/note.php b/htdocs/contrat/note.php index ff0df34de67..9a6d28dd4c9 100644 --- a/htdocs/contrat/note.php +++ b/htdocs/contrat/note.php @@ -2,6 +2,7 @@ /* Copyright (C) 2004 Rodolphe Quiedeville * Copyright (C) 2004-2016 Laurent Destailleur * Copyright (C) 2005-2012 Regis Houssin + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -26,6 +27,9 @@ require ("../main.inc.php"); require_once DOL_DOCUMENT_ROOT.'/core/lib/contract.lib.php'; require_once DOL_DOCUMENT_ROOT.'/contrat/class/contrat.class.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load("companies"); $langs->load("contracts"); diff --git a/htdocs/fichinter/document.php b/htdocs/fichinter/document.php index 33db56a6e78..c869387b211 100644 --- a/htdocs/fichinter/document.php +++ b/htdocs/fichinter/document.php @@ -6,6 +6,7 @@ * Copyright (C) 2005 Simon TOSSER * Copyright (C) 2011-2012 Juanjo Menent * Copyright (C) 2013 Cédric Salvador + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -33,6 +34,9 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/images.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/fichinter.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load("other"); $langs->load("fichinter"); diff --git a/htdocs/fichinter/info.php b/htdocs/fichinter/info.php index c8520a6645f..0a685999afe 100644 --- a/htdocs/fichinter/info.php +++ b/htdocs/fichinter/info.php @@ -2,6 +2,7 @@ /* Copyright (C) 2005-2009 Regis Houssin * Copyright (C) 2009-2016 Laurent Destailleur * Copyright (C) 2011 Juanjo Menent + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -27,6 +28,9 @@ require '../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php'; require_once DOL_DOCUMENT_ROOT.'/fichinter/class/fichinter.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/fichinter.lib.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load('companies'); $langs->load("interventions"); diff --git a/htdocs/fichinter/note.php b/htdocs/fichinter/note.php index a5a9675eb43..cf15841dce9 100644 --- a/htdocs/fichinter/note.php +++ b/htdocs/fichinter/note.php @@ -2,6 +2,7 @@ /* Copyright (C) 2005-2012 Regis Houssin * Copyright (C) 2011-2012 Juanjo Menent * Copyright (C) 2013 Florian Henry + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -26,6 +27,9 @@ require '../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/fichinter/class/fichinter.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/fichinter.lib.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load('companies'); $langs->load("interventions"); diff --git a/htdocs/fourn/commande/contact.php b/htdocs/fourn/commande/contact.php index 564057d991a..ce9ce39ac4a 100644 --- a/htdocs/fourn/commande/contact.php +++ b/htdocs/fourn/commande/contact.php @@ -2,6 +2,7 @@ /* Copyright (C) 2005 Patrick Rouillon * Copyright (C) 2005-2009 Destailleur Laurent * Copyright (C) 2005-2012 Regis Houssin + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -28,6 +29,9 @@ require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.commande.class.php'; require_once DOL_DOCUMENT_ROOT.'/contact/class/contact.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/fourn.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formcompany.class.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load("facture"); $langs->load("orders"); diff --git a/htdocs/fourn/commande/document.php b/htdocs/fourn/commande/document.php index 49d739be811..d04e21dc654 100644 --- a/htdocs/fourn/commande/document.php +++ b/htdocs/fourn/commande/document.php @@ -5,6 +5,7 @@ * Copyright (C) 2005-2012 Regis Houssin * Copyright (C) 2012 Marcos García * Copyright (C) 2013 Cédric Salvador + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -33,6 +34,9 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/images.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/fourn.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php'; require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.commande.class.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load('orders'); $langs->load('other'); diff --git a/htdocs/fourn/commande/info.php b/htdocs/fourn/commande/info.php index bd92039eb1c..44e37dc952a 100644 --- a/htdocs/fourn/commande/info.php +++ b/htdocs/fourn/commande/info.php @@ -2,6 +2,7 @@ /* Copyright (C) 2003-2005 Rodolphe Quiedeville * Copyright (C) 2004-2016 Laurent Destailleur * Copyright (C) 2005-2012 Regis Houssin + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -28,6 +29,9 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/fourn.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php'; require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.commande.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/company.lib.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load("orders"); $langs->load("suppliers"); diff --git a/htdocs/fourn/commande/note.php b/htdocs/fourn/commande/note.php index 45e4bd80e3a..85c7094265b 100644 --- a/htdocs/fourn/commande/note.php +++ b/htdocs/fourn/commande/note.php @@ -3,6 +3,7 @@ * Copyright (C) 2004-2016 Laurent Destailleur * Copyright (C) 2005-2009 Regis Houssin * Copyright (C) 2012 Marcos García + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -27,6 +28,9 @@ require '../../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/fourn.lib.php'; require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.commande.class.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load("orders"); $langs->load("suppliers"); diff --git a/htdocs/fourn/facture/contact.php b/htdocs/fourn/facture/contact.php index ffc58195e26..6b54e28987f 100644 --- a/htdocs/fourn/facture/contact.php +++ b/htdocs/fourn/facture/contact.php @@ -2,6 +2,7 @@ /* Copyright (C) 2005 Patrick Rouillon * Copyright (C) 2005-2015 Laurent Destailleur * Copyright (C) 2005-2012 Regis Houssin + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -29,6 +30,9 @@ require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.facture.class.php'; require_once DOL_DOCUMENT_ROOT.'/contact/class/contact.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/fourn.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formcompany.class.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load("bills"); $langs->load('other'); diff --git a/htdocs/fourn/facture/document.php b/htdocs/fourn/facture/document.php index c46f3de647e..113f262e2a9 100644 --- a/htdocs/fourn/facture/document.php +++ b/htdocs/fourn/facture/document.php @@ -5,6 +5,7 @@ * Copyright (C) 2005-2012 Regis Houssin * Copyright (C) 2013 Cédric Salvador * Copyright (C) 2016 Alexandre Spangaro + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -33,6 +34,9 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/fourn.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/images.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load('bills'); $langs->load('other'); diff --git a/htdocs/fourn/facture/info.php b/htdocs/fourn/facture/info.php index d2241b9841a..1297c44037b 100644 --- a/htdocs/fourn/facture/info.php +++ b/htdocs/fourn/facture/info.php @@ -3,6 +3,7 @@ * Copyright (C) 2004-2006 Laurent Destailleur * Copyright (C) 2005-2009 Regis Houssin * Copyright (C) 2016 Alexandre Spangaro + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -29,6 +30,9 @@ require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.class.php'; require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.facture.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/fourn.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load('companies'); $langs->load('bills'); diff --git a/htdocs/fourn/facture/note.php b/htdocs/fourn/facture/note.php index 6afe9f37c8c..11d59d1170c 100644 --- a/htdocs/fourn/facture/note.php +++ b/htdocs/fourn/facture/note.php @@ -3,6 +3,7 @@ * Copyright (C) 2004-2011 Laurent Destailleur * Copyright (C) 2005-2012 Regis Houssin * Copyright (C) 2013 Florian Henry + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -28,6 +29,9 @@ require '../../main.inc.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'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load('bills'); $langs->load("companies"); diff --git a/htdocs/langs/fr_FR/other.lang b/htdocs/langs/fr_FR/other.lang index 231c2f382e7..3087e752479 100644 --- a/htdocs/langs/fr_FR/other.lang +++ b/htdocs/langs/fr_FR/other.lang @@ -178,7 +178,7 @@ NumberOfSupplierOrders=Nombre de commandes fournisseurs NumberOfSupplierInvoices=Nombre de factures fournisseurs NumberOfUnitsProposals=Quantités présentes dans les propositions commerciales NumberOfUnitsCustomerOrders=Quantités présentes dans les commandes clients -NumberOfUnitsCustomerInvoices=Quantités présentes dans les factures fournisseurs +NumberOfUnitsCustomerInvoices=Quantités présentes dans les factures clients NumberOfUnitsSupplierProposals=Quantités présentes dans les demande de prix NumberOfUnitsSupplierOrders=Quantités présentes dans les commandes fournisseurs NumberOfUnitsSupplierInvoices=Quantités présentes dans les factures fournisseurs diff --git a/htdocs/loan/document.php b/htdocs/loan/document.php index b43261d2b9d..30f1efc69f7 100644 --- a/htdocs/loan/document.php +++ b/htdocs/loan/document.php @@ -1,5 +1,6 @@ + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -27,6 +28,9 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/images.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/loan.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load("other"); $langs->load("companies"); diff --git a/htdocs/loan/info.php b/htdocs/loan/info.php index 64987afa8b5..ea7237cdd34 100644 --- a/htdocs/loan/info.php +++ b/htdocs/loan/info.php @@ -1,5 +1,6 @@ + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -25,6 +26,9 @@ require '../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/loan/class/loan.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/loan.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load("compta"); $langs->load("bills"); diff --git a/htdocs/loan/note.php b/htdocs/loan/note.php index 5f435444f32..8f64036f819 100644 --- a/htdocs/loan/note.php +++ b/htdocs/loan/note.php @@ -5,6 +5,7 @@ * Copyright (C) 2013 Florian Henry * Copyright (C) 2015 Frederic France * Copyright (C) 2016 Alexandre Spangaro + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -29,6 +30,9 @@ require '../main.inc.php'; require_once(DOL_DOCUMENT_ROOT.'/loan/class/loan.class.php'); require_once DOL_DOCUMENT_ROOT.'/core/lib/loan.lib.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $action = GETPOST('action','aZ09'); diff --git a/htdocs/supplier_proposal/document.php b/htdocs/supplier_proposal/document.php index 9bb7db0222b..36c1df7329c 100644 --- a/htdocs/supplier_proposal/document.php +++ b/htdocs/supplier_proposal/document.php @@ -4,6 +4,7 @@ * Copyright (C) 2005 Marc Barilley / Ocebo * Copyright (C) 2005-2012 Regis Houssin * Copyright (C) 2013 Cédric Salvador + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -31,6 +32,9 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/supplier_proposal.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/images.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load('compta'); $langs->load('other'); diff --git a/htdocs/supplier_proposal/info.php b/htdocs/supplier_proposal/info.php index 9f134b332ae..9724e86b1d5 100644 --- a/htdocs/supplier_proposal/info.php +++ b/htdocs/supplier_proposal/info.php @@ -2,6 +2,7 @@ /* Copyright (C) 2004 Rodolphe Quiedeville * Copyright (C) 2004-2006 Laurent Destailleur * Copyright (C) 2005-2012 Regis Houssin + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -27,6 +28,9 @@ require '../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php'; require_once DOL_DOCUMENT_ROOT.'/supplier_proposal/class/supplier_proposal.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/supplier_proposal.lib.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load('supplier_proposal'); $langs->load('compta'); diff --git a/htdocs/supplier_proposal/note.php b/htdocs/supplier_proposal/note.php index 997cb67db2f..57c6fbed502 100644 --- a/htdocs/supplier_proposal/note.php +++ b/htdocs/supplier_proposal/note.php @@ -4,6 +4,7 @@ * Copyright (C) 2004 Eric Seigne * Copyright (C) 2005-2012 Regis Houssin * Copyright (C) 2013 Florian Henry + * Copyright (C) 2017 Ferran Marcet * * 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 @@ -28,6 +29,9 @@ require '../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/supplier_proposal/class/supplier_proposal.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/supplier_proposal.lib.php'; +if (! empty($conf->projet->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} $langs->load('supplier_proposal'); $langs->load('compta');