diff --git a/COPYRIGHT b/COPYRIGHT index a961a442507..519910ea1b1 100644 --- a/COPYRIGHT +++ b/COPYRIGHT @@ -28,10 +28,10 @@ Restler 3.0 LGPL-3+ Yes TCPDF 6.2.6 LGPL-3+ Yes PDF generation JS libraries: -jQuery 1.8.2 MIT License Yes JS library -jQuery UI 1.9.1 GPL and MIT License Yes JS library plugin UI +jQuery 1.11.3 MIT License Yes JS library +jQuery UI 1.11.4 GPL and MIT License Yes JS library plugin UI jQuery select2 3.5.2 GPL and Apache License Yes JS library plugin for sexier multiselect -jQuery blockUI 2.43 GPL and MIT License Yes JS library plugin blockUI (to use ajax popups) +jQuery blockUI 2.70.0 GPL and MIT License Yes JS library plugin blockUI (to use ajax popups) jQuery Colorpicker 1.1 MIT License Yes JS library for color picker for a defined list of colors jQuery DataTables 1.9.4 BSD Yes JS library for tables output jQuery FileUpload 5.0.3 GPL and MIT License Yes JS library to upload files diff --git a/ChangeLog b/ChangeLog index fca13478c08..ed418b08f5c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -34,6 +34,7 @@ For translators: For developers: - New: Function yn can show a visual checkbox. - New: Introduced select2 jquery plugin. +- New: Possibility to add javascript in main login page with "getLoginPageOptions" hook WARNING: Following changes may create regression for some external modules, but was necessary to make Dolibarr better: @@ -42,8 +43,9 @@ Dolibarr better: - Hooks 'printLeftBlock' and 'formConfirm' are now compliant with hook development rules. They are "addreplace" hooks, so you must return content with "->resprints='mycontent'" and not with "return 'mycontent'" - All fields "fk_societe" were renamed into "fk_soc". -- Method select_PriceBaseType and load_PriceBaseType were merged into selectPriceBaseType - +- Method select_PriceBaseType and load_PriceBaseType were merged into selectPriceBaseType. +- The trigger USER_LOGIN* are deprecated. They are still working but you should prefer use the + hook afterLogin or afterLoginFailed instead. ***** ChangeLog for 3.7.2 compared to 3.7.1 ***** FIX [ bug #2855 ] Wrong translation key in localtax report page diff --git a/build/debian/README.howto b/build/debian/README.howto index da7077f1f26..6140412b831 100644 --- a/build/debian/README.howto +++ b/build/debian/README.howto @@ -38,6 +38,15 @@ filter-pristine-tar = True END +# Complete .bashrc with DEBEMAIL and DEBFULLNAME +Example: +export DEBFULLNAME="Laurent Destailleur (eldy)" +export DEBEMAIL=eldy@users.sourceforge.net +Other example: +export DEBFULLNAME="Laurent Destailleur" +export DEBEMAIL="eldy@destailleur.fr" + + # To use Alioth.debian.org * Create an account login * Update your ~/.ssh/config file to add: @@ -111,7 +120,7 @@ severity 123 xxx ##### Update but tracker system To set status of a bug to "pending" -> bts tag 999999 +pending +> bts --smtp-host=yoursmtpserver tag 999999 +pending or replay to email 999999@bugs.debian.org + submitter of bug With a message starting with: diff --git a/build/makepack-dolibarr.pl b/build/makepack-dolibarr.pl index 62ce7345217..a6cca8e2ce2 100755 --- a/build/makepack-dolibarr.pl +++ b/build/makepack-dolibarr.pl @@ -455,13 +455,15 @@ if ($nboftargetok) { $ret=`rm -fr $BUILDROOT/$PROJECT/documents`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/document`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/documents`; + # Removed known external modules to avoid any error when packaging from env where external modules are tested + $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/custom/*`; # For custom we want to keep dir $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/ancotec*`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/cabinetmed*`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/calling*`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/bootstrap*`; - $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/custom*`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/factory*`; + $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/lead*`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/management*`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/multicompany*`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/nltechno*`; diff --git a/dev/skeletons/skeleton_page.php b/dev/skeletons/skeleton_page.php index 653fd617a06..7665ce9986a 100644 --- a/dev/skeletons/skeleton_page.php +++ b/dev/skeletons/skeleton_page.php @@ -218,7 +218,7 @@ jQuery(document).ready(function() { } init_myfunc(); jQuery("#mybutton").click(function() { - init_needroot(); + init_myfunc(); }); }); '; diff --git a/htdocs/.gitignore b/htdocs/.gitignore index bf99a2deebe..bd9c176df9b 100644 --- a/htdocs/.gitignore +++ b/htdocs/.gitignore @@ -10,3 +10,4 @@ /ovh* /pos /ultimatepdf* +/lead diff --git a/htdocs/accountancy/admin/index.php b/htdocs/accountancy/admin/index.php index c1ad179342a..dba04aafa05 100644 --- a/htdocs/accountancy/admin/index.php +++ b/htdocs/accountancy/admin/index.php @@ -1,11 +1,11 @@ * Copyright (C) 2013-2014 Florian Henry - * Copyright (C) 2013-2014 Alexandre Spangaro + * Copyright (C) 2013-2015 Alexandre Spangaro * Copyright (C) 2014 Ari Elbaz (elarifr) * Copyright (C) 2014 Marcos García * Copyright (C) 2014 Juanjo Menent - * Copyright (C) 2015 Jean-François Ferry + * Copyright (C) 2015 Jean-François Ferry * * 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 @@ -56,6 +56,8 @@ $list = array ( 'ACCOUNTING_PRODUCT_SOLD_ACCOUNT', 'ACCOUNTING_SERVICE_BUY_ACCOUNT', 'ACCOUNTING_SERVICE_SOLD_ACCOUNT', + 'ACCOUNTING_VAT_BUY_ACCOUNT', + 'ACCOUNTING_VAT_SOLD_ACCOUNT', 'ACCOUNTING_ACCOUNT_SUSPENSE', 'ACCOUNTING_ACCOUNT_TRANSFER_CASH' ); diff --git a/htdocs/accountancy/bookkeeping/card.php b/htdocs/accountancy/bookkeeping/card.php index e25ceb976ff..3656ae9f929 100644 --- a/htdocs/accountancy/bookkeeping/card.php +++ b/htdocs/accountancy/bookkeeping/card.php @@ -295,8 +295,8 @@ else print_liste_field_titre($langs->trans("Credit")); print_liste_field_titre($langs->trans("Amount")); print_liste_field_titre($langs->trans("Sens")); - - print ''; + print_liste_field_titre(''); + print "\n"; foreach ( $book->linesmvt as $line ) { diff --git a/htdocs/accountancy/bookkeeping/listbyyear.php b/htdocs/accountancy/bookkeeping/listbyyear.php index 26f0469c1a0..0135f073427 100644 --- a/htdocs/accountancy/bookkeeping/listbyyear.php +++ b/htdocs/accountancy/bookkeeping/listbyyear.php @@ -90,7 +90,7 @@ if ($resql) { print_liste_field_titre($langs->trans("Amount"), $_SERVER['PHP_SELF'], "bk.montant", "", "", "", $sortfield, $sortorder); print_liste_field_titre($langs->trans("Sens"), $_SERVER['PHP_SELF'], "bk.sens", "", "", "", $sortfield, $sortorder); print_liste_field_titre($langs->trans("Codejournal"), $_SERVER['PHP_SELF'], "bk.code_journal", "", "", "", $sortfield, $sortorder); - print_liste_field_titre(" "); + print_liste_field_titre(''); print "\n"; $var = True; diff --git a/htdocs/accountancy/journal/purchasesjournal.php b/htdocs/accountancy/journal/purchasesjournal.php index 0a000e01833..862ff92eb4b 100644 --- a/htdocs/accountancy/journal/purchasesjournal.php +++ b/htdocs/accountancy/journal/purchasesjournal.php @@ -112,7 +112,7 @@ if ($result) { $num = $db->num_rows($result); // les variables $cptfour = (! empty($conf->global->ACCOUNTING_ACCOUNT_SUPPLIER)) ? $conf->global->ACCOUNTING_ACCOUNT_SUPPLIER : $langs->trans("CodeNotDef"); - $cpttva = (! empty($conf->global->ACCOUNTING_VAT_ACCOUNT)) ? $conf->global->ACCOUNTING_VAT_ACCOUNT : $langs->trans("CodeNotDef"); + $cpttva = (! empty($conf->global->ACCOUNTING_VAT_SOLD_ACCOUNT)) ? $conf->global->ACCOUNTING_VAT_SOLD_ACCOUNT : $langs->trans("CodeNotDef"); $tabfac = array (); $tabht = array (); diff --git a/htdocs/accountancy/journal/sellsjournal.php b/htdocs/accountancy/journal/sellsjournal.php index db9af17388a..83191f88bf4 100644 --- a/htdocs/accountancy/journal/sellsjournal.php +++ b/htdocs/accountancy/journal/sellsjournal.php @@ -136,7 +136,7 @@ if ($result) { else $compta_prod = (! empty($conf->global->ACCOUNTING_SERVICE_SOLD_ACCOUNT)) ? $conf->global->ACCOUNTING_SERVICE_SOLD_ACCOUNT : $langs->trans("CodeNotDef"); } - $cpttva = (! empty($conf->global->ACCOUNTING_VAT_ACCOUNT)) ? $conf->global->ACCOUNTING_VAT_ACCOUNT : $langs->trans("CodeNotDef"); + $cpttva = (! empty($conf->global->ACCOUNTING_VAT_SOLD_ACCOUNT)) ? $conf->global->ACCOUNTING_VAT_SOLD_ACCOUNT : $langs->trans("CodeNotDef"); $compta_tva = (! empty($obj->account_tva) ? $obj->account_tva : $cpttva); // Situation invoices handling diff --git a/htdocs/adherents/card.php b/htdocs/adherents/card.php index 9a0fecba320..d87729ee0c5 100644 --- a/htdocs/adherents/card.php +++ b/htdocs/adherents/card.php @@ -34,9 +34,10 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/images.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php'; require_once DOL_DOCUMENT_ROOT.'/adherents/class/adherent.class.php'; require_once DOL_DOCUMENT_ROOT.'/adherents/class/adherent_type.class.php'; -require_once DOL_DOCUMENT_ROOT.'/core/class/extrafields.class.php'; require_once DOL_DOCUMENT_ROOT.'/adherents/class/cotisation.class.php'; +require_once DOL_DOCUMENT_ROOT.'/categories/class/categorie.class.php'; require_once DOL_DOCUMENT_ROOT.'/compta/bank/class/account.class.php'; +require_once DOL_DOCUMENT_ROOT.'/core/class/extrafields.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formcompany.class.php'; $langs->load("companies"); @@ -239,7 +240,7 @@ if (empty($reshook)) } } - if ($action == 'update' && $cancel='' && $user->rights->adherent->creer) + if ($action == 'update' && ! $cancel && $user->rights->adherent->creer) { require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; @@ -322,8 +323,29 @@ if (empty($reshook)) } $result=$object->update($user,0,$nosyncuser,$nosyncuserpass); + if ($result >= 0 && ! count($object->errors)) { + // Categories association + // First we delete all categories association + $sql = 'DELETE FROM ' . MAIN_DB_PREFIX . 'categorie_member'; + $sql .= ' WHERE fk_member = ' . $object->id; + $resql = $db->query($sql); + if (! $resql) dol_print_error($db); + + // Then we add the associated categories + $categories = GETPOST('memcats', 'array'); + + if (! empty($categories)) + { + $cat = new Categorie($db); + foreach ($categories as $id_category) + { + $cat->fetch($id_category); + $cat->add_type($object, 'member'); + } + } + // Logo/Photo save $dir= $conf->adherent->dir_output . '/' . get_exdir($object->id,2,0,1,$object,'member').'/photos'; $file_OK = is_uploaded_file($_FILES['photo']['tmp_name']); @@ -536,6 +558,18 @@ if (empty($reshook)) $result=$object->create($user); if ($result > 0) { + // Categories association + $memcats = GETPOST('memcats', 'array'); + if (! empty($memcats)) + { + $cat = new Categorie($db); + foreach ($memcats as $id_category) + { + $cat->fetch($id_category); + $cat->add_type($object, 'member'); + } + } + $db->commit(); $rowid=$object->id; $action=''; @@ -899,6 +933,15 @@ else print $form->selectyesno("public",$object->public,1); print "\n"; + // Categories + if (! empty($conf->categorie->enabled) && ! empty($user->rights->categorie->lire)) + { + print '' . fieldLabel('Categories', 'memcars') . ''; + $cate_arbo = $form->select_all_categories(Categorie::TYPE_MEMBER, null, 'parent', null, null, 1); + print $form->multiselectarray('memcats', $cate_arbo, GETPOST('memcats', 'array'), null, null, null, null, '100%'); + print ""; + } + // Other attributes $parameters=array(); $reshook=$hookmanager->executeHooks('formObjectOptions',$parameters,$object,$action); // Note that $action and $object may have been modified by hook @@ -1024,7 +1067,7 @@ else print ''; // Ref - print ''; + print ''; // Login if (empty($conf->global->ADHERENT_LOGIN_NOT_REQUIRED)) @@ -1070,7 +1113,7 @@ else print ''; // Civility - print ''; print ''; @@ -1144,12 +1187,27 @@ else print $form->selectyesno("public",(isset($_POST["public"])?$_POST["public"]:$object->public),1); print "\n"; + // Categories + if (! empty( $conf->categorie->enabled ) && !empty( $user->rights->categorie->lire )) + { + print ''; + print '"; + } + // Other attributes - $parameters=array(); + $parameters=array("colspan"=>2); $reshook=$hookmanager->executeHooks('formObjectOptions',$parameters,$object,$action); // Note that $action and $object may have been modified by hook if (empty($reshook) && ! empty($extrafields->attribute_label)) { - print $object->showOptionals($extrafields,'edit'); + print $object->showOptionals($extrafields,'edit',$parameters); } // Third party Dolibarr @@ -1291,7 +1349,7 @@ else $helpcontent.=dol_htmlentitiesbr($texttosend)."\n"; $label=$form->textwithpicto($tmp,$helpcontent,1,'help'); - // Cree un tableau formulaire + // Create form popup $formquestion=array(); if ($object->email) $formquestion[]=array('type' => 'checkbox', 'name' => 'send_mail', 'label' => $label, 'value' => ($conf->global->ADHERENT_DEFAULT_SENDINFOBYMAIL?true:false)); if (! empty($conf->mailman->enabled) && ! empty($conf->global->ADHERENT_USE_MAILMAN)) { @@ -1465,12 +1523,21 @@ else // Status print ''; + // Categories + if (! empty($conf->categorie->enabled) && ! empty($user->rights->categorie->lire)) + { + print ''; + print ''; + } + // Other attributes - $parameters=array(); + $parameters=array('colspan'=>2); $reshook=$hookmanager->executeHooks('formObjectOptions',$parameters,$object,$action); // Note that $action and $object may have been modified by hook if (empty($reshook) && ! empty($extrafields->attribute_label)) { - print $object->showOptionals($extrafields); + print $object->showOptionals($extrafields, 'view', $parameters); } // Third party Dolibarr diff --git a/htdocs/adherents/type.php b/htdocs/adherents/type.php index e830254fd97..54a00f04831 100644 --- a/htdocs/adherents/type.php +++ b/htdocs/adherents/type.php @@ -53,6 +53,12 @@ $pagenext = $page + 1; if (! $sortorder) { $sortorder="DESC"; } if (! $sortfield) { $sortfield="d.lastname"; } +$label=GETPOST("libelle","alpha"); +$cotisation=GETPOST("cotisation","int"); +$vote=GETPOST("vote","int"); +$comment=GETPOST("comment"); +$mail_valid=GETPOST("mail_valid"); + // Security check $result=restrictedArea($user,'adherent',$rowid,'adherent_type'); @@ -83,11 +89,11 @@ if ($action == 'add' && $user->rights->adherent->configurer) { $object = new AdherentType($db); - $object->libelle = trim($_POST["libelle"]); - $object->cotisation = trim($_POST["cotisation"]); - $object->note = trim($_POST["comment"]); - $object->mail_valid = trim($_POST["mail_valid"]); - $object->vote = trim($_POST["vote"]); + $object->libelle = trim($label); + $object->cotisation = trim($cotisation); + $object->note = trim($comment); + $object->mail_valid = trim($mail_valid); + $object->vote = trim($vote); // Fill array 'array_options' with data from add form $ret = $extrafields->setOptionalsFromPost($extralabels,$object); @@ -120,12 +126,12 @@ if ($action == 'update' && $user->rights->adherent->configurer) if ($_POST["button"] != $langs->trans("Cancel")) { $object = new AdherentType($db); - $object->id = $_POST["rowid"]; - $object->libelle = trim($_POST["libelle"]); - $object->cotisation = trim($_POST["cotisation"]); - $object->note = trim($_POST["comment"]); - $object->mail_valid = trim($_POST["mail_valid"]); - $object->vote = trim($_POST["vote"]); + $object->id = $rowid; + $object->libelle = trim($label); + $object->cotisation = trim($cotisation); + $object->note = trim($comment); + $object->mail_valid = trim($mail_valid); + $object->vote = trim($vote); // Fill array 'array_options' with data from add form $ret = $extrafields->setOptionalsFromPost($extralabels,$object); @@ -169,6 +175,7 @@ if (! $rowid && $action != 'create' && $action != 'edit') print_fiche_titre($langs->trans("MembersTypes")); + dol_fiche_head(''); $sql = "SELECT d.rowid, d.libelle, d.cotisation, d.vote"; $sql.= " FROM ".MAIN_DB_PREFIX."adherent_type as d"; @@ -197,7 +204,7 @@ if (! $rowid && $action != 'create' && $action != 'edit') $var=!$var; print ""; print ''; - print ''; + print ''; print ''; print ''; print ''; @@ -211,6 +218,7 @@ if (! $rowid && $action != 'create' && $action != 'edit') dol_print_error($db); } + dol_fiche_end(); /* * Hotbar @@ -246,7 +254,7 @@ if ($action == 'create') print '
'.$langs->trans("Ref").''.$object->id.'
'.$langs->trans("Ref").''.$object->id.'
'.$langs->trans("Company").'societe).'">
'.$langs->trans("UserTitle").''; + print '
'.$langs->trans("UserTitle").''; print $formcompany->select_civility(isset($_POST["civility_id"])?$_POST["civility_id"]:$object->civility_id)."\n"; print '
' . fieldLabel('Categories', 'memcats') . ''; + $cate_arbo = $form->select_all_categories(Categorie::TYPE_MEMBER, null, null, null, null, 1); + $c = new Categorie($db); + $cats = $c->containing($object->id, Categorie::TYPE_MEMBER); + foreach ($cats as $cat) { + $arrayselected[] = $cat->id; + } + print $form->multiselectarray('memcats', $cate_arbo, $arrayselected, '', 0, '', 0, '100%'); + print "
'.$langs->trans("Status").''.$object->getLibStatut(4).'
' . $langs->trans("Categories") . ''; + print $form->showCategories($object->id, 'member', 1); + print '
'.img_object($langs->trans("ShowType"),'group').' '.$objp->rowid.''.$objp->libelle.''.dol_escape_htmltag($objp->libelle).''.yn($objp->cotisation).''.yn($objp->vote).'rowid.'">'.img_edit().'
'; print ''; - + print ''; print ''; @@ -277,7 +285,7 @@ if ($action == 'create') } print ''; print "
'.$langs->trans("Label").'
\n"; - + dol_fiche_end(); print '
'; @@ -317,7 +325,7 @@ if ($rowid > 0) print ''; // Label - print ''.$langs->trans("Label").''.$object->libelle.''; + print ''.$langs->trans("Label").''.dol_escape_htmltag($object->libelle).''; print ''.$langs->trans("SubscriptionRequired").''; print yn($object->cotisation); @@ -343,7 +351,9 @@ if ($rowid > 0) } print ''; - print '
'; + + dol_fiche_end(); + /* * Hotbar @@ -493,15 +503,15 @@ if ($rowid > 0) print ''; print ''; - print ''; + print ''; print ''; - print ''; + print ''; print ' '; print ''; - print ''; + print ''; print ' '; @@ -563,7 +573,7 @@ if ($rowid > 0) if ($datefin) { print ''; - if ($datefin < time() && $objp->statut > 0) + if ($datefin < dol_now() && $objp->statut > 0) { print dol_print_date($datefin,'day')." ".img_warning($langs->trans("SubscriptionLate")); } @@ -634,17 +644,18 @@ if ($rowid > 0) $head = member_type_prepare_head($object); - dol_fiche_head($head, 'card', $langs->trans("MemberType"), 0, 'group'); - print '
'; print ''; print ''; print ''; + + dol_fiche_head($head, 'card', $langs->trans("MemberType"), 0, 'group'); + print ''; print ''; - print ''; + print ''; print '
'.$langs->trans("Ref").''.$object->id.'
'.$langs->trans("Label").'
'.$langs->trans("Label").'
'.$langs->trans("SubscriptionRequired").''; print $form->selectyesno("cotisation",$object->cotisation,1); @@ -683,6 +694,8 @@ if ($rowid > 0) print '


'; } + dol_fiche_end(); + print '
'; print ''; print '     '; @@ -693,6 +706,7 @@ if ($rowid > 0) } } -$db->close(); llxFooter(); + +$db->close(); diff --git a/htdocs/admin/agenda.php b/htdocs/admin/agenda.php index 5da5fa621c6..16608a5fae2 100644 --- a/htdocs/admin/agenda.php +++ b/htdocs/admin/agenda.php @@ -1,8 +1,8 @@ +/* Copyright (C) 2008-2015 Laurent Destailleur * Copyright (C) 2011 Regis Houssin * Copyright (C) 2011-2012 Juanjo Menent - * Copyright (C) 2015 Jean-François Ferry + * Copyright (C) 2015 Jean-François Ferry * * 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 @@ -137,6 +137,11 @@ print_fiche_titre($langs->trans("AgendaSetup"),$linkback,'title_setup'); print "
\n"; +print ''; +print ''; +print ''; + + $head=agenda_prepare_head(); dol_fiche_head($head, 'autoactions', $langs->trans("Agenda"), 0, 'action'); @@ -145,10 +150,6 @@ print $langs->trans("AgendaAutoActionDesc")."
\n"; print $langs->trans("OnlyActiveElementsAreShown").'
'; print "
\n"; -print ''; -print ''; -print ''; - $var=true; print ''; print ''; @@ -168,8 +169,9 @@ if (! empty($triggers)) //print 'module='.$module.'
'; if (! empty($conf->$module->enabled)) { - // Discard special case. + // Discard special case: If option FICHINTER_CLASSIFY_BILLED is not set, we discard both trigger FICHINTER_CLASSIFY_BILLED and FICHINTER_CLASSIFY_UNBILLED if ($trigger['code'] == 'FICHINTER_CLASSIFY_BILLED' && empty($conf->global->FICHINTER_CLASSIFY_BILLED)) continue; + if ($trigger['code'] == 'FICHINTER_CLASSIFY_UNBILLED' && empty($conf->global->FICHINTER_CLASSIFY_BILLED)) continue; $var=!$var; print ''; @@ -185,13 +187,14 @@ if (! empty($triggers)) } print '
'; -print '
'; +dol_fiche_end(); + +print '
'; print ''; print "
"; print "\n"; -dol_fiche_end(); print "
"; diff --git a/htdocs/admin/agenda_extsites.php b/htdocs/admin/agenda_extsites.php index c1a9ec3afd2..633b62f2316 100644 --- a/htdocs/admin/agenda_extsites.php +++ b/htdocs/admin/agenda_extsites.php @@ -1,5 +1,5 @@ +/* Copyright (C) 2008-2015 Laurent Destailleur * Copyright (C) 2011-2015 Juanjo Menent * Copyright (C) 2015 Jean-François Ferry * @@ -127,6 +127,10 @@ $linkback=''.$langs->trans("BackToM print_fiche_titre($langs->trans("AgendaSetup"),$linkback,'title_setup'); print '
'; +print '
'; +print ''; +print ''; + $head=agenda_prepare_head(); dol_fiche_head($head, 'extsites', $langs->trans("Agenda"), 0, 'action'); @@ -134,7 +138,6 @@ dol_fiche_head($head, 'extsites', $langs->trans("Agenda"), 0, 'action'); print $langs->trans("AgendaExtSitesDesc")."
\n"; print "
\n"; -print ''; $selectedvalue=$conf->global->AGENDA_DISABLE_EXT; if ($selectedvalue==1) $selectedvalue=0; else $selectedvalue=1; @@ -219,7 +222,8 @@ while ($i <= $MAXAGENDA) } print ''; -print '
'; + +dol_fiche_end(); print '
'; print ''; @@ -227,7 +231,6 @@ print '
'; print "
\n"; -dol_fiche_end(); llxFooter(); diff --git a/htdocs/admin/agenda_other.php b/htdocs/admin/agenda_other.php index f0d9f2ca00d..f892fe7149a 100644 --- a/htdocs/admin/agenda_other.php +++ b/htdocs/admin/agenda_other.php @@ -1,7 +1,7 @@ +/* Copyright (C) 2008-2015 Laurent Destailleur * Copyright (C) 2011 Regis Houssin - * Copyright (C) 2011-2013 Juanjo Menent + * Copyright (C) 2011-2013 Juanjo Menent * Copyright (C) 2015 Jean-François Ferry * * This program is free software; you can redistribute it and/or modify @@ -93,17 +93,16 @@ print_fiche_titre($langs->trans("AgendaSetup"),$linkback,'title_setup'); print "
\n"; + +print '
'; +print ''; + $head=agenda_prepare_head(); dol_fiche_head($head, 'other', $langs->trans("Agenda"), 0, 'action'); -//print_titre($langs->trans("OtherOptions")); - $var=true; -print ''; -print ''; - print ''."\n"; print ''."\n"; print ''."\n"; @@ -158,11 +157,12 @@ print ''."\n"; print '
'.$langs->trans("Parameters").'
'; +dol_fiche_end(); + print '
'; print '
'; -dol_fiche_end(); print "
"; diff --git a/htdocs/admin/agenda_xcal.php b/htdocs/admin/agenda_xcal.php index d196664bdf9..f7abde2280e 100644 --- a/htdocs/admin/agenda_xcal.php +++ b/htdocs/admin/agenda_xcal.php @@ -1,5 +1,5 @@ +/* Copyright (C) 2008-2015 Laurent Destailleur * Copyright (C) 2012-2013 Juanjo Menent * Copyright (C) 2012 Regis Houssin * Copyright (C) 2015 Jean-François Ferry @@ -78,6 +78,9 @@ print_fiche_titre($langs->trans("AgendaSetup"),$linkback,'title_setup'); print '
'; +print '
'; +print ''; + $head=agenda_prepare_head(); dol_fiche_head($head, 'xcal', $langs->trans("Agenda"), 0, 'action'); @@ -85,18 +88,16 @@ dol_fiche_head($head, 'xcal', $langs->trans("Agenda"), 0, 'action'); print $langs->trans("AgendaSetupOtherDesc")."
\n"; print "
\n"; -print ''; -print ''; -print ""; +print '
'; -print ""; +print ''; print ""; print ""; //print ""; print ""; print ""; -print ""; +print ""; print '"; print ''; print ""; print ""; -print ""; +print ""; print ""; print ""; print ""; print ""; -print ""; +print ""; print ""; print ""; print ""; @@ -121,13 +122,13 @@ print '
".$langs->trans("Parameter")."".$langs->trans("Value")."".$langs->trans("Examples")." 
'.$langs->trans("PasswordTogetVCalExport")."'; if (! empty($conf->use_javascript_ajax)) @@ -105,13 +106,13 @@ print ' 
".$langs->trans("PastDelayVCalExport")."global->MAIN_AGENDA_EXPORT_PAST_DELAY) . "\" size=\"10\"> ".$langs->trans("days")." 
".$langs->trans("UseACacheDelay")."global->MAIN_AGENDA_EXPORT_CACHE) . "\" size=\"10\"> 
'; print '
'; -print ""; +print '
'; -print ""; +print ''; print '"; print ""; print ""; -print ""; +print ""; print '"; print ""; print '
'.$langs->trans("Parameter")."".$langs->trans("Value")."
'.$langs->trans("FixTZ").""; print ''; @@ -137,13 +138,14 @@ print "
'; -print '
'; +dol_fiche_end(); + +print '
'; print "trans("Save")."\">"; print "
"; print "\n"; -dol_fiche_end(); clearstatcache(); diff --git a/htdocs/admin/compta.php b/htdocs/admin/compta.php index 48cad667a51..6020cb7947e 100644 --- a/htdocs/admin/compta.php +++ b/htdocs/admin/compta.php @@ -44,7 +44,7 @@ $list = array( 'ACCOUNTING_PRODUCT_SOLD_ACCOUNT', 'ACCOUNTING_SERVICE_BUY_ACCOUNT', 'ACCOUNTING_SERVICE_SOLD_ACCOUNT', - 'ACCOUNTING_VAT_ACCOUNT', + 'ACCOUNTING_VAT_SOLD_ACCOUNT', 'ACCOUNTING_VAT_BUY_ACCOUNT', 'ACCOUNTING_ACCOUNT_CUSTOMER', 'ACCOUNTING_ACCOUNT_SUPPLIER' diff --git a/htdocs/admin/dict.php b/htdocs/admin/dict.php index d13f43a6ed5..3b6fca62005 100644 --- a/htdocs/admin/dict.php +++ b/htdocs/admin/dict.php @@ -70,7 +70,7 @@ $hookmanager->initHooks(array('admin')); // Put here declaration of dictionaries properties // Sort order to show dictionary (0 is space). All other dictionaries (added by modules) will be at end of this. -$taborder=array(9,0,4,3,2,0,1,8,19,16,27,0,5,11,0,6,0,7,17,24,28,0,10,23,12,13,0,14,0,22,20,18,21,0,15,0,25,0,26); +$taborder=array(9,0,4,3,2,0,1,8,19,16,27,0,5,11,0,6,0,29,0,7,17,24,28,0,10,23,12,13,0,14,0,22,20,18,21,0,15,0,25,0,26); // Name of SQL tables of dictionaries $tabname=array(); @@ -102,6 +102,7 @@ $tabname[25]= MAIN_DB_PREFIX."c_email_templates"; $tabname[26]= MAIN_DB_PREFIX."c_units"; $tabname[27]= MAIN_DB_PREFIX."c_stcomm"; $tabname[28]= MAIN_DB_PREFIX."c_holiday_types"; +$tabname[29]= MAIN_DB_PREFIX."c_lead_status"; // Dictionary labels $tablib=array(); @@ -133,6 +134,7 @@ $tablib[25]= "DictionaryEMailTemplates"; $tablib[26]= "DictionaryUnits"; $tablib[27]= "DictionaryProspectStatus"; $tablib[28]= "DictionaryHolidayTypes"; +$tablib[29]= "DictionaryOpportunityStatus"; // Requests to extract data $tabsql=array(); @@ -164,6 +166,7 @@ $tabsql[25]= "SELECT rowid as rowid, label, type_template, private, position, $tabsql[26]= "SELECT rowid as rowid, code, label, short_label, active FROM ".MAIN_DB_PREFIX."c_units"; $tabsql[27]= "SELECT id as rowid, code, libelle, active FROM ".MAIN_DB_PREFIX."c_stcomm"; $tabsql[28]= "SELECT h.rowid as rowid, h.code, h.label, h.delay, h.newByMonth, h.fk_country as country_id, c.code as country_code, c.label as country, h.active FROM ".MAIN_DB_PREFIX."c_holiday_types as h LEFT JOIN ".MAIN_DB_PREFIX."c_country as c ON h.fk_country=c.rowid"; +$tabsql[29]= "SELECT rowid as rowid, code, label, percent, position, active FROM ".MAIN_DB_PREFIX."c_lead_status"; // Criteria to sort dictionaries $tabsqlsort=array(); @@ -195,6 +198,7 @@ $tabsqlsort[25]="label ASC"; $tabsqlsort[26]="code ASC"; $tabsqlsort[27]="code ASC"; $tabsqlsort[28]="country ASC, code ASC"; +$tabsqlsort[29]="position ASC"; // Nom des champs en resultat de select pour affichage du dictionnaire $tabfield=array(); @@ -226,6 +230,7 @@ $tabfield[25]= "label,type_template,private,position,topic,content"; $tabfield[26]= "code,label,short_label"; $tabfield[27]= "code,libelle"; $tabfield[28]= "code,label,delay,newByMonth,country_id,country"; +$tabfield[29]= "code,label,percent,position"; // Nom des champs d'edition pour modification d'un enregistrement $tabfieldvalue=array(); @@ -257,6 +262,7 @@ $tabfieldvalue[25]= "label,type_template,private,position,topic,content"; $tabfieldvalue[26]= "code,label,short_label"; $tabfieldvalue[27]= "code,libelle"; $tabfieldvalue[28]= "code,label,delay,newByMonth,country"; +$tabfieldvalue[29]= "code,label,percent,position"; // Nom des champs dans la table pour insertion d'un enregistrement $tabfieldinsert=array(); @@ -288,6 +294,7 @@ $tabfieldinsert[25]= "label,type_template,private,position,topic,content"; $tabfieldinsert[26]= "code,label,short_label"; $tabfieldinsert[27]= "code,libelle"; $tabfieldinsert[28]= "code,label,delay,newByMonth,fk_country"; +$tabfieldinsert[29]= "code,label,percent,position"; // Nom du rowid si le champ n'est pas de type autoincrement // Example: "" if id field is "rowid" and has autoincrement on @@ -321,6 +328,7 @@ $tabrowid[25]= ""; $tabrowid[26]= ""; $tabrowid[27]= "id"; $tabrowid[28]= ""; +$tabrowid[29]= ""; // Condition to show dictionary in setup page $tabcond=array(); @@ -352,6 +360,7 @@ $tabcond[25]= true; // && ! empty($conf->global->MAIN_EMAIL_EDIT_TEMPLATE_FROM_D $tabcond[26]= ! empty($conf->product->enabled); $tabcond[27]= ! empty($conf->societe->enabled); $tabcond[28]= ! empty($conf->holiday->enabled); +$tabcond[29]= ! empty($conf->projet->enabled); // List of help for fields $tabhelp=array(); @@ -383,6 +392,7 @@ $tabhelp[25] = array(); $tabhelp[26] = array(); $tabhelp[27] = array(); $tabhelp[28] = array(); +$tabhelp[29] = array(); // List of check for fields (NOT USED YET) $tabfieldcheck=array(); @@ -414,6 +424,7 @@ $tabfieldcheck[25] = array(); $tabfieldcheck[26] = array(); $tabfieldcheck[27] = array(); $tabfieldcheck[28] = array(); +$tabfieldcheck[29] = array(); // Complete all arrays with entries found into modules complete_dictionary_with_modules($taborder,$tabname,$tablib,$tabsql,$tabsqlsort,$tabfield,$tabfieldvalue,$tabfieldinsert,$tabrowid,$tabcond,$tabhelp,$tabfieldcheck); diff --git a/htdocs/admin/ihm.php b/htdocs/admin/ihm.php index 28f221131e1..c1baf0bc979 100644 --- a/htdocs/admin/ihm.php +++ b/htdocs/admin/ihm.php @@ -68,7 +68,15 @@ if ($action == 'update') dolibarr_set_const($db, "MAIN_THEME", $_POST["main_theme"],'chaine',0,'',$conf->entity); - dolibarr_set_const($db, "MAIN_SEARCHFORM_CONTACT", $_POST["MAIN_SEARCHFORM_CONTACT"],'chaine',0,'',$conf->entity); + $val=(join(',',(colorStringToArray(GETPOST('THEME_ELDY_TOPMENU_BACK1'),array())))); + if ($val == '') dolibarr_del_const($db, 'THEME_ELDY_TOPMENU_BACK1', $conf->entity); + else dolibarr_set_const($db, 'THEME_ELDY_TOPMENU_BACK1', join(',',colorStringToArray(GETPOST('THEME_ELDY_TOPMENU_BACK1'),array())),'chaine',0,'',$conf->entity); + + $val=(join(',',(colorStringToArray(GETPOST('THEME_ELDY_BACKTITLE1'),array())))); + if ($val == '') dolibarr_del_const($db, 'THEME_ELDY_BACKTITLE1', $conf->entity); + else dolibarr_set_const($db, 'THEME_ELDY_BACKTITLE1', join(',',colorStringToArray(GETPOST('THEME_ELDY_BACKTITLE1'),array())),'chaine',0,'',$conf->entity); + + dolibarr_set_const($db, "MAIN_SEARCHFORM_CONTACT", $_POST["MAIN_SEARCHFORM_CONTACT"],'chaine',0,'',$conf->entity); dolibarr_set_const($db, "MAIN_SEARCHFORM_SOCIETE", $_POST["MAIN_SEARCHFORM_SOCIETE"],'chaine',0,'',$conf->entity); dolibarr_set_const($db, "MAIN_SEARCHFORM_PRODUITSERVICE", $_POST["MAIN_SEARCHFORM_PRODUITSERVICE"],'chaine',0,'',$conf->entity); dolibarr_set_const($db, "MAIN_SEARCHFORM_PRODUITSERVICE_SUPPLIER",$_POST["MAIN_SEARCHFORM_PRODUITSERVICE_SUPPLIER"],'chaine',0,'',$conf->entity); @@ -148,7 +156,7 @@ if ($action == 'edit') // Edit print '
'."\n"; - // Themes + // Themes and themes options show_theme(null,1); print '
'; diff --git a/htdocs/admin/mails.php b/htdocs/admin/mails.php index 53937687b57..148fcf76268 100644 --- a/htdocs/admin/mails.php +++ b/htdocs/admin/mails.php @@ -230,7 +230,6 @@ $linuxlike=1; if (preg_match('/^win/i',PHP_OS)) $linuxlike=0; if (preg_match('/^mac/i',PHP_OS)) $linuxlike=0; - if (empty($conf->global->MAIN_MAIL_SENDMODE)) $conf->global->MAIN_MAIL_SENDMODE='mail'; $port=! empty($conf->global->MAIN_MAIL_SMTP_PORT)?$conf->global->MAIN_MAIL_SMTP_PORT:ini_get('smtp_port'); if (! $port) $port=25; @@ -275,8 +274,21 @@ if ($action == 'edit') '; if ($linuxlike) { - print ' jQuery("#MAIN_MAIL_SMTP_SERVER").prop("disabled", true);'; - print ' jQuery("#MAIN_MAIL_SMTP_PORT").prop("disabled", true);'; + print ' + jQuery("#MAIN_MAIL_SMTP_SERVER").hide(); + jQuery("#MAIN_MAIL_SMTP_PORT").hide(); + jQuery("#smtp_server_mess").show(); + jQuery("#smtp_port_mess").show(); + '; + } + else + { + print ' + jQuery("#MAIN_MAIL_SMTP_SERVER").prop("disabled", true); + jQuery("#MAIN_MAIL_SMTP_PORT").prop("disabled", true); + jQuery("#smtp_server_mess").hide(); + jQuery("#smtp_port_mess").hide(); + '; } print ' } @@ -287,7 +299,11 @@ if ($action == 'edit') jQuery("#MAIN_MAIL_EMAIL_TLS").removeAttr("disabled"); jQuery("#MAIN_MAIL_SMTP_SERVER").removeAttr("disabled"); jQuery("#MAIN_MAIL_SMTP_PORT").removeAttr("disabled"); - } + jQuery("#MAIN_MAIL_SMTP_SERVER").show(); + jQuery("#MAIN_MAIL_SMTP_PORT").show(); + jQuery("#smtp_server_mess").hide(); + jQuery("#smtp_port_mess").hide(); + } } initfields(); jQuery("#MAIN_MAIL_SENDMODE").change(function() { @@ -336,7 +352,7 @@ if ($action == 'edit') } print ''; - // Server + // Host server $var=!$var; print ''; if (! $conf->use_javascript_ajax && $linuxlike && $conf->global->MAIN_MAIL_SENDMODE == 'mail') @@ -357,6 +373,7 @@ if ($action == 'edit') { print ''; print ''; + print ''.$langs->trans("SeeLocalSendMailSetup").''; } else { @@ -389,6 +406,7 @@ if ($action == 'edit') { print ''; print ''; + print ''.$langs->trans("SeeLocalSendMailSetup").''; } else { @@ -509,7 +527,7 @@ else print $text; print ''; - // Server + // Host server $var=!$var; if ($linuxlike && (isset($conf->global->MAIN_MAIL_SENDMODE) && $conf->global->MAIN_MAIL_SENDMODE == 'mail')) { diff --git a/htdocs/admin/tools/listevents.php b/htdocs/admin/tools/listevents.php index 72280ec7220..0ff5e5f1373 100644 --- a/htdocs/admin/tools/listevents.php +++ b/htdocs/admin/tools/listevents.php @@ -190,7 +190,7 @@ if ($result) print_liste_field_titre($langs->trans("IP"),$_SERVER["PHP_SELF"],"e.ip","","",'align="left"',$sortfield,$sortorder); print_liste_field_titre($langs->trans("User"),$_SERVER["PHP_SELF"],"u.login","","",'align="left"',$sortfield,$sortorder); print_liste_field_titre($langs->trans("Description"),$_SERVER["PHP_SELF"],"e.description","","",'align="left"',$sortfield,$sortorder); - print_liste_field_titre('','',''); + print_liste_field_titre(''); print "\n"; diff --git a/htdocs/admin/tools/listsessions.php b/htdocs/admin/tools/listsessions.php index efa3ffb91c0..c313c91a7bd 100644 --- a/htdocs/admin/tools/listsessions.php +++ b/htdocs/admin/tools/listsessions.php @@ -134,7 +134,7 @@ if ($savehandler == 'files') print_liste_field_titre($langs->trans("DateModification"),$_SERVER["PHP_SELF"],"datem","","",'align="left"',$sortfield,$sortorder); print_liste_field_titre($langs->trans("Age"),$_SERVER["PHP_SELF"],"age","","",'align="left"',$sortfield,$sortorder); print_liste_field_titre($langs->trans("Raw"),$_SERVER["PHP_SELF"],"raw","","",'align="left"',$sortfield,$sortorder); - print_liste_field_titre('','',''); + print_liste_field_titre(''); print "\n"; $var=True; diff --git a/htdocs/bookmarks/list.php b/htdocs/bookmarks/list.php index be821f72af9..7512785d78b 100644 --- a/htdocs/bookmarks/list.php +++ b/htdocs/bookmarks/list.php @@ -103,7 +103,7 @@ if ($resql) print_liste_field_titre($langs->trans("Owner"),$_SERVER["PHP_SELF"],"u.lastname","","",'align="center"',$sortfield,$sortorder); print_liste_field_titre($langs->trans("Date"),$_SERVER["PHP_SELF"],"b.dateb","","",'align="center"',$sortfield,$sortorder); print_liste_field_titre($langs->trans("Position"),$_SERVER["PHP_SELF"],"b.position","","",'align="right"',$sortfield,$sortorder); - print_liste_field_titre('','',''); + print_liste_field_titre(''); print "\n"; $var=True; diff --git a/htdocs/comm/action/card.php b/htdocs/comm/action/card.php index 98fe5299a5e..75d18dd8cd5 100644 --- a/htdocs/comm/action/card.php +++ b/htdocs/comm/action/card.php @@ -924,9 +924,66 @@ if ($id > 0) print ''.$langs->trans("DateActionEnd").''; if (GETPOST("afaire") == 1) $form->select_date($datef?$datef:$object->datef,'p2',1,1,1,"action",1,1,0,0,'fulldayend'); else if (GETPOST("afaire") == 2) $form->select_date($datef?$datef:$object->datef,'p2',1,1,1,"action",1,1,0,0,'fulldayend'); + //else $form->select_date($datef?$datef:$object->datef,'p2',1,1,1,"action",1,1,0,0,'fulldayend','ap'); else $form->select_date($datef?$datef:$object->datef,'p2',1,1,1,"action",1,1,0,0,'fulldayend'); print ''; + $userepeatevent=0; // Dev in progress + if ($userepeatevent) + { + // Repeat + print ''.$langs->trans("RepeatEvent").''; + print ''; + $arrayrecurrulefreq=array( + 'no'=>$langs->trans("No"), + 'MONTHLY'=>$langs->trans("EveryMonth"), + 'WEEKLY'=>$langs->trans("EveryWeek"), + //'DAYLY'=>$langs->trans("EveryDay") + ); + $selectedrecurrulefreq='no'; + $selectedrecurrulebymonthday=''; + $selectedrecurrulebyday=''; + if ($object->recurrule && preg_match('/FREQ=([A-Z]+)/i',$object->recurrule,$reg)) $selectedrecurrulefreq=$reg[1]; + if ($object->recurrule && preg_match('/FREQ=MONTHLY.*BYMONTHDAY=(\d+)/i',$object->recurrule,$reg)) $selectedrecurrulebymonthday=$reg[1]; + if ($object->recurrule && preg_match('/FREQ=WEEKLY.*BYDAY(\d+)/i',$object->recurrule,$reg)) $selectedrecurrulebyday=$reg[1]; + print $form->selectarray('recurrulefreq', $arrayrecurrulefreq, $selectedrecurrulefreq); + // If recurrulefreq is MONTHLY + print '
'; + print $langs->trans("DayOfMonth").': '; + print '
'; + // If recurrulefreq is WEEKLY + print '
'; + print $langs->trans("DayOfWeek").': '; + print '
'; + print ''; + print ''; + } + // Status print ''.$langs->trans("Status").' / '.$langs->trans("Percentage").''; $percent=GETPOST("percentage")?GETPOST("percentage"):$object->percentage; @@ -992,7 +1049,7 @@ if ($id > 0) print ''; // Contact - print ''.$langs->trans("Contact").''; + print ''.$langs->trans("Contact").''; $form->select_contacts($object->socid, $object->contactid, 'contactid', 1, '', '', 0, 'minwidth200'); print ''; } @@ -1000,17 +1057,15 @@ if ($id > 0) // Project if (! empty($conf->projet->enabled)) { - $formproject=new FormProjets($db); - // Projet associe $langs->load("project"); print ''.$langs->trans("Project").''; $numprojet=$formproject->select_projects($object->socid,$object->fk_project,'projectid'); if ($numprojet==0) { - print '  
'.$langs->trans("AddProject").''; + print '   '.$langs->trans("AddProject").''; } print ''; } @@ -1065,7 +1120,7 @@ if ($id > 0) if($action == 'clone') { $formconfirm = $form->formconfirm($_SERVER["PHP_SELF"] . '?id=' . GETPOST('id'), $langs->trans('CloneAction'), $langs->trans('ConfirmCloneAction', $object->label), 'confirm_clone', $formquestion, 'yes', 1); - + print $formconfirm; } @@ -1275,7 +1330,7 @@ if ($id > 0) { print ''; } - + if ($user->rights->agenda->allactions->create || (($object->authorid == $user->id || $object->userownerid == $user->id) && $user->rights->agenda->myactions->create)) { @@ -1285,7 +1340,7 @@ if ($id > 0) { print ''; } - + if ($user->rights->agenda->allactions->delete || (($object->authorid == $user->id || $object->userownerid == $user->id) && $user->rights->agenda->myactions->delete)) { diff --git a/htdocs/comm/action/index.php b/htdocs/comm/action/index.php index e5472727aa2..c414d3409d6 100644 --- a/htdocs/comm/action/index.php +++ b/htdocs/comm/action/index.php @@ -341,11 +341,14 @@ dol_fiche_head($head, $tabactive, $langs->trans('Agenda'), 0, 'action'); print_actions_filter($form,$canedit,$status,$year,$month,$day,$showbirthday,0,$filtert,0,$pid,$socid,$action,$listofextcals,$actioncode,$usergroup); dol_fiche_end(); + +// Define the legend/list of calendard to show +$s=''; $link=''; + $showextcals=$listofextcals; -// Legend -if (! empty($conf->use_javascript_ajax)) + +if (! empty($conf->use_javascript_ajax)) // If javascript on { - $s=''; $s.='' . "\n"; + // Local calendar $s.='
' . $langs->trans("LocalAgenda").'  
'; + + // External calendars if (is_array($showextcals) && count($showextcals) > 0) { $s.='