diff --git a/htdocs/comm/action/class/actioncomm.class.php b/htdocs/comm/action/class/actioncomm.class.php index 34e88dd893e..56fb713ae0c 100644 --- a/htdocs/comm/action/class/actioncomm.class.php +++ b/htdocs/comm/action/class/actioncomm.class.php @@ -57,7 +57,7 @@ class ActionComm extends CommonObject var $datef; // Date action end (datep2) var $durationp = -1; // -1=Unkown duration // deprecated var $fulldayevent = 0; // 1=Event on full day - var $punctual = 1; // Milestone // TODO Not sure we need this. Milestone is already event with end date = start date + var $punctual = 1; // Milestone // deprecated. Milestone is already event with end date = start date var $percentage; // Percentage var $location; // Location diff --git a/htdocs/comm/action/listactions.php b/htdocs/comm/action/listactions.php index 245902013a1..7fa67695860 100644 --- a/htdocs/comm/action/listactions.php +++ b/htdocs/comm/action/listactions.php @@ -180,7 +180,7 @@ $sql.= " LEFT JOIN ".MAIN_DB_PREFIX."user as ut ON a.fk_user_action = ut.rowid"; if ($usergroup > 0) $sql.= ", ".MAIN_DB_PREFIX."usergroup_user as ugu"; $sql.= " WHERE c.id = a.fk_action"; $sql.= ' AND a.fk_user_author = u.rowid'; -$sql.= ' AND a.entity IN ('.getEntity('agenda', 1).')'; // To limit to entity +$sql.= ' AND a.entity IN ('.getEntity('agenda', 1).')'; if ($actioncode) $sql.=" AND c.code='".$db->escape($actioncode)."'"; if ($pid) $sql.=" AND a.fk_project=".$db->escape($pid); if (! $user->rights->societe->client->voir && ! $socid) $sql.= " AND (a.fk_soc IS NULL OR sc.fk_user = " .$user->id . ")"; diff --git a/htdocs/comm/action/peruser.php b/htdocs/comm/action/peruser.php index dcebefbcbb7..22cf8841c02 100644 --- a/htdocs/comm/action/peruser.php +++ b/htdocs/comm/action/peruser.php @@ -610,7 +610,7 @@ else $sql = "SELECT u.rowid, u.lastname as lastname, u.firstname, u.statut, u.login, u.admin, u.entity"; $sql.= " FROM ".MAIN_DB_PREFIX."user as u"; if ($usergroup > 0) $sql.= " LEFT JOIN ".MAIN_DB_PREFIX."usergroup_user as ug ON u.rowid = ug.fk_user"; - $sql.= " WHERE u.entity IN (".getEntity('user').")"; + $sql.= " WHERE u.entity IN (".getEntity('user',1).")"; if ($usergroup > 0) $sql.= " AND ug.fk_usergroup = ".$usergroup; if (GETPOST("usertodo","int",3) > 0) $sql.=" AND u.rowid = ".GETPOST("usertodo","int",3); //print $sql; diff --git a/htdocs/comm/action/rapport/index.php b/htdocs/comm/action/rapport/index.php index a9a19f57a9e..24eb117684f 100644 --- a/htdocs/comm/action/rapport/index.php +++ b/htdocs/comm/action/rapport/index.php @@ -1,7 +1,7 @@ * Copyright (C) 2003 Eric Seigne - * Copyright (C) 2004-2009 Laurent Destailleur + * Copyright (C) 2004-2014 Laurent Destailleur * Copyright (C) 2005-2012 Regis Houssin * * This program is free software; you can redistribute it and/or modify @@ -55,6 +55,7 @@ $result = restrictedArea($user, 'agenda', $socid, '', 'myactions'); /* * Actions */ + if ($action == 'builddoc') { $cat = new CommActionRapport($db, $month, $year); @@ -79,7 +80,7 @@ $sql.= " date_format(a.datep, '%Y') as year"; $sql.= " FROM ".MAIN_DB_PREFIX."actioncomm as a,"; $sql.= " ".MAIN_DB_PREFIX."user as u"; $sql.= " WHERE a.fk_user_author = u.rowid"; -$sql.= " AND a.entity = ".$conf->entity; +$sql.= ' AND a.entity IN ('.getEntity('agenda', 1).')'; //$sql.= " AND percent = 100"; $sql.= " GROUP BY year, month, df"; $sql.= " ORDER BY year DESC, month DESC, df DESC"; diff --git a/htdocs/contact/canvas/default/tpl/contactcard_create.tpl.php b/htdocs/contact/canvas/default/tpl/contactcard_create.tpl.php index a0605d3656e..70d6b41bf35 100644 --- a/htdocs/contact/canvas/default/tpl/contactcard_create.tpl.php +++ b/htdocs/contact/canvas/default/tpl/contactcard_create.tpl.php @@ -50,7 +50,7 @@ echo $this->control->tpl['ajax_selectcountry']; ?> - trans("Company"); ?> + trans("ThirdParty"); ?> control->tpl['company']; ?> diff --git a/htdocs/contact/canvas/default/tpl/contactcard_edit.tpl.php b/htdocs/contact/canvas/default/tpl/contactcard_edit.tpl.php index a445444e42c..3be1d16bc8d 100644 --- a/htdocs/contact/canvas/default/tpl/contactcard_edit.tpl.php +++ b/htdocs/contact/canvas/default/tpl/contactcard_edit.tpl.php @@ -59,7 +59,7 @@ echo $this->control->tpl['ajax_selectcountry']; - trans("Company"); ?> + trans("ThirdParty"); ?> control->tpl['company']; ?> diff --git a/htdocs/contact/canvas/default/tpl/contactcard_view.tpl.php b/htdocs/contact/canvas/default/tpl/contactcard_view.tpl.php index 623fad27e77..0b4b8a07fcb 100644 --- a/htdocs/contact/canvas/default/tpl/contactcard_view.tpl.php +++ b/htdocs/contact/canvas/default/tpl/contactcard_view.tpl.php @@ -44,7 +44,7 @@ dol_htmloutput_errors($this->control->tpl['error'],$this->control->tpl['errors'] - trans("Company"); ?> + trans("ThirdParty"); ?> control->tpl['company']; ?> diff --git a/htdocs/contact/card.php b/htdocs/contact/card.php index bcdea083c3f..a1030a68292 100644 --- a/htdocs/contact/card.php +++ b/htdocs/contact/card.php @@ -456,7 +456,7 @@ else { if ($socid > 0) { - print ''; + print ''; print ''; print $objsoc->getNomUrl(1); print ''; @@ -464,7 +464,7 @@ else print ''; } else { - print ''; + print ''; print $form->select_company($socid,'socid','',1); print ''; } @@ -690,7 +690,7 @@ else // Company if (empty($conf->global->SOCIETE_DISABLE_CONTACTS)) { - print ''; + print ''; print ''; print $form->select_company(GETPOST('socid','int')?GETPOST('socid','int'):($object->socid?$object->socid:-1),'socid','',1); print ''; @@ -924,7 +924,7 @@ else // Company if (empty($conf->global->SOCIETE_DISABLE_CONTACTS)) { - print ''.$langs->trans("Company").''; + print ''.$langs->trans("ThirdParty").''; if ($object->socid > 0) { $objsoc->fetch($object->socid); diff --git a/htdocs/contact/exportimport.php b/htdocs/contact/exportimport.php index bcb3b9c2be0..e9e9c70966c 100644 --- a/htdocs/contact/exportimport.php +++ b/htdocs/contact/exportimport.php @@ -77,11 +77,11 @@ if (empty($conf->global->SOCIETE_DISABLE_CONTACTS)) $objsoc = new Societe($db); $objsoc->fetch($contact->socid); - print ''.$langs->trans("Company").''.$objsoc->getNomUrl(1).''; + print ''.$langs->trans("ThirdParty").''.$objsoc->getNomUrl(1).''; } else { - print ''.$langs->trans("Company").''; + print ''.$langs->trans("ThirdParty").''; print $langs->trans("ContactNotLinkedToCompany"); print ''; } diff --git a/htdocs/contact/ldap.php b/htdocs/contact/ldap.php index fe3098eaa9a..170ed039904 100644 --- a/htdocs/contact/ldap.php +++ b/htdocs/contact/ldap.php @@ -105,11 +105,11 @@ if ($contact->socid > 0) $objsoc = new Societe($db); $objsoc->fetch($contact->socid); - print ''.$langs->trans("Company").''.$objsoc->getNomUrl(1).''; + print ''.$langs->trans("ThirdParty").''.$objsoc->getNomUrl(1).''; } else { - print ''.$langs->trans("Company").''; + print ''.$langs->trans("ThirdParty").''; print $langs->trans("ContactNotLinkedToCompany"); print ''; } diff --git a/htdocs/contact/list.php b/htdocs/contact/list.php index eab4369ac21..4413b721fc9 100644 --- a/htdocs/contact/list.php +++ b/htdocs/contact/list.php @@ -300,7 +300,7 @@ if ($result) print_liste_field_titre($langs->trans("Lastname"),$_SERVER["PHP_SELF"],"p.lastname", $begin, $param, '', $sortfield,$sortorder); print_liste_field_titre($langs->trans("Firstname"),$_SERVER["PHP_SELF"],"p.firstname", $begin, $param, '', $sortfield,$sortorder); print_liste_field_titre($langs->trans("PostOrFunction"),$_SERVER["PHP_SELF"],"p.poste", $begin, $param, '', $sortfield,$sortorder); - if (empty($conf->global->SOCIETE_DISABLE_CONTACTS)) print_liste_field_titre($langs->trans("Company"),$_SERVER["PHP_SELF"],"s.nom", $begin, $param, '', $sortfield,$sortorder); + if (empty($conf->global->SOCIETE_DISABLE_CONTACTS)) print_liste_field_titre($langs->trans("ThirdParty"),$_SERVER["PHP_SELF"],"s.nom", $begin, $param, '', $sortfield,$sortorder); print_liste_field_titre($langs->trans("Phone"),$_SERVER["PHP_SELF"],"p.phone", $begin, $param, '', $sortfield,$sortorder); print_liste_field_titre($langs->trans("PhoneMobile"),$_SERVER["PHP_SELF"],"p.phone_mobile", $begin, $param, '', $sortfield,$sortorder); print_liste_field_titre($langs->trans("Fax"),$_SERVER["PHP_SELF"],"p.fax", $begin, $param, '', $sortfield,$sortorder); diff --git a/htdocs/contact/note.php b/htdocs/contact/note.php index 73b0f513db9..ab8101dd739 100644 --- a/htdocs/contact/note.php +++ b/htdocs/contact/note.php @@ -98,12 +98,12 @@ if ($id > 0) $objsoc = new Societe($db); $objsoc->fetch($object->socid); - print ''.$langs->trans("Company").''.$objsoc->getNomUrl(1).''; + print ''.$langs->trans("ThirdParty").''.$objsoc->getNomUrl(1).''; } else { - print ''.$langs->trans("Company").''; + print ''.$langs->trans("ThirdParty").''; print $langs->trans("ContactNotLinkedToCompany"); print ''; } diff --git a/htdocs/contact/perso.php b/htdocs/contact/perso.php index 19644fe5bf5..173ccbcb265 100644 --- a/htdocs/contact/perso.php +++ b/htdocs/contact/perso.php @@ -111,11 +111,11 @@ if ($action == 'edit') $objsoc = new Societe($db); $objsoc->fetch($object->socid); - print ''.$langs->trans("Company").''.$objsoc->getNomUrl(1).''; + print ''.$langs->trans("ThirdParty").''.$objsoc->getNomUrl(1).''; } else { - print ''.$langs->trans("Company").''; + print ''.$langs->trans("ThirdParty").''; print $langs->trans("ContactNotLinkedToCompany"); print ''; } @@ -179,12 +179,12 @@ else $objsoc = new Societe($db); $objsoc->fetch($object->socid); - print ''.$langs->trans("Company").''.$objsoc->getNomUrl(1).''; + print ''.$langs->trans("ThirdParty").''.$objsoc->getNomUrl(1).''; } else { - print ''.$langs->trans("Company").''; + print ''.$langs->trans("ThirdParty").''; print $langs->trans("ContactNotLinkedToCompany"); print ''; } diff --git a/htdocs/core/class/html.form.class.php b/htdocs/core/class/html.form.class.php index 14b7c78cc7d..9feca9a7061 100755 --- a/htdocs/core/class/html.form.class.php +++ b/htdocs/core/class/html.form.class.php @@ -827,7 +827,7 @@ class Form { if (count($events)) // Add management of event { - print '