diff --git a/htdocs/actioncomm.class.php b/htdocs/actioncomm.class.php index 1e47756923b..1b2862b6042 100644 --- a/htdocs/actioncomm.class.php +++ b/htdocs/actioncomm.class.php @@ -552,7 +552,7 @@ class ActionComm $filename=$format.'.'.$extension; } - create_exdir($conf->agenda->dir_temp); + $result=create_exdir($conf->agenda->dir_temp); $outputfile=$conf->agenda->dir_temp.'/'.$filename; $result=0; @@ -583,7 +583,12 @@ class ActionComm $sql.= " c.id as type_id, c.code as type_code, c.libelle"; $sql.= " FROM ".MAIN_DB_PREFIX."actioncomm as a, ".MAIN_DB_PREFIX."c_actioncomm as c"; $sql.= " WHERE a.fk_action=c.id"; - $sql.= " order by datec"; + foreach($filters as $key => $value) + { + if ($key == 'year') $sql.=' AND '; + if ($key == 'idaction') $sql.=' AND a.id='.$value; + } + $sql.= " ORDER by datec"; dolibarr_syslog("ActionComm::build_vcal select events sql=".$sql); $resql=$this->db->query($sql); @@ -620,6 +625,7 @@ class ActionComm } else { + $this->error=$this->db->lasterror(); dolibarr_syslog("ActionComm::build_calfile ".$this->db->lasterror(), LOG_ERR); return -1; } diff --git a/htdocs/comm/action/agendaexport.php b/htdocs/comm/action/agendaexport.php new file mode 100644 index 00000000000..c804c232404 --- /dev/null +++ b/htdocs/comm/action/agendaexport.php @@ -0,0 +1,86 @@ + + * + * 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 + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + */ + +/** \file htdocs/comm/action/agendaexport.php + \ingroup agenda + \brief Page export agenda + \version $Id$ +*/ + +// This is to make Dolibarr working with Plesk +set_include_path($_SERVER['DOCUMENT_ROOT'].'/htdocs'); + +require("../../master.inc.php"); +require_once(DOL_DOCUMENT_ROOT.'/actioncomm.class.php'); + + +// C'est un wrapper, donc header vierge +function llxHeader() { print '
| '; + print dolibarr_trunc($obj->label,12); + print ' | '; + print ''; print dolibarr_print_date($obj->dp,"day"); $late=0; @@ -274,11 +279,6 @@ if ($resql) print dolibarr_print_date($obj->da2,"day"); print ' | '; - // Titre - print ''; - print dolibarr_trunc($obj->label,10); - print ' | '; - // Société print ''; $societestatic->id=$obj->socid; diff --git a/htdocs/langs/fr_FR/agenda.lang b/htdocs/langs/fr_FR/agenda.lang index 3085ba35d61..98795281b97 100644 --- a/htdocs/langs/fr_FR/agenda.lang +++ b/htdocs/langs/fr_FR/agenda.lang @@ -23,5 +23,5 @@ ViewList=Voir liste ViewCal=Voir calendrier ViewWithPredefinedFilters=Vues avec filtres prédéfinis AutoActions=Création automatiques des actions -AgendaAutoActionDesc=Définissez dans cet onglet, les actions pour lesquels dolibarr créera automatique une tache dans l'agenda. Si aucune case n'est cochée (par défaut), seules les actions manuelles seront incluses dans l'agenda. +AgendaAutoActionDesc=Définissez dans cet onglet, les actions pour lesquels dolibarr créera automatiquement une tache dans l'agenda. Si aucune case n'est cochée (par défaut), seules les actions manuelles seront incluses dans l'agenda. AgendaSetupOtherDesc=Cette page permet de configurer les autres paramètres. \ No newline at end of file diff --git a/htdocs/lib/images.lib.php b/htdocs/lib/images.lib.php index b1bc33a3dc7..d32095635c5 100644 --- a/htdocs/lib/images.lib.php +++ b/htdocs/lib/images.lib.php @@ -26,15 +26,16 @@ -/* - * \brief Création de 2 vignettes a partir d'un fichier image (une small et un mini) - * \brief Les extension prise en compte sont jpg et png - * \param file Chemin du fichier image a redimensionner - * \param maxWidth Largeur maximum que dois faire la miniature (160 par défaut) - * \param maxHeight Hauteur maximum que dois faire l'image (120 par défaut) - * \param extName Extension pour différencier le nom de la vignette - * \param quality Qualité de compression (0=worst, 100=best) - * \return string Chemin de la vignette +/** + * \brief Create a thumbnail from an image file (une small et un mini) + * \brief Les extensions prises en compte sont jpg et png + * \param file Chemin du fichier image a redimensionner + * \param maxWidth Largeur maximum que dois faire la miniature (160 par défaut) + * \param maxHeight Hauteur maximum que dois faire l'image (120 par défaut) + * \param extName Extension pour différencier le nom de la vignette + * \param quality Qualité de compression (0=worst, 100=best) + * \return string Full path of thumb + * \remarks With file=myfile.jpg -> myfile_small.jpg */ function vignette($file, $maxWidth = 160, $maxHeight = 120, $extName='_small', $quality=50) { |