task #9747: Can show content of external calendar (ical) into agenda
This commit is contained in:
parent
7ae2b6e35b
commit
e813448bb9
@ -74,12 +74,6 @@ if ($actionsave)
|
|||||||
if (! $res > 0) $error++;
|
if (! $res > 0) $error++;
|
||||||
$i++;
|
$i++;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Save timezone
|
|
||||||
$timezone=trim(GETPOST("agenda_ext_timezone"));
|
|
||||||
if ($timezone=='-1') $timezone='';
|
|
||||||
$res=dolibarr_set_const($db,'AGENDA_EXT_TIMEZONE',$timezone,'chaine',0);
|
|
||||||
if (! $res > 0) $error++;
|
|
||||||
// Save nb of agenda
|
// Save nb of agenda
|
||||||
$res=dolibarr_set_const($db,'AGENDA_EXT_NB',trim(GETPOST("AGENDA_EXT_NB")),'chaine',0);
|
$res=dolibarr_set_const($db,'AGENDA_EXT_NB',trim(GETPOST("AGENDA_EXT_NB")),'chaine',0);
|
||||||
if (! $res > 0) $error++;
|
if (! $res > 0) $error++;
|
||||||
@ -131,14 +125,6 @@ print '<td width="180">'.$langs->trans("Parameter")."</td>";
|
|||||||
print "<td>".$langs->trans("Value")."</td>";
|
print "<td>".$langs->trans("Value")."</td>";
|
||||||
print "</tr>";
|
print "</tr>";
|
||||||
|
|
||||||
// Timezone
|
|
||||||
print "<tr ".$bc[$var].">";
|
|
||||||
print "<td>".$langs->trans("ClientTZ")."</td>";
|
|
||||||
print "<td>";
|
|
||||||
print $formadmin->select_timezone($conf->global->AGENDA_EXT_TIMEZONE,'agenda_ext_timezone');
|
|
||||||
print "</td>";
|
|
||||||
print "</tr>";
|
|
||||||
|
|
||||||
// Nb of agenda
|
// Nb of agenda
|
||||||
$var=!$var;
|
$var=!$var;
|
||||||
print "<tr ".$bc[$var].">";
|
print "<tr ".$bc[$var].">";
|
||||||
|
|||||||
@ -511,8 +511,9 @@ if ($conf->global->ENABLE_AGENDA_EXT==1 && $conf->global->AGENDA_EXT_NB>0)
|
|||||||
$event->id=$icalevent[UID];
|
$event->id=$icalevent[UID];
|
||||||
$event->icalname=$namecal;
|
$event->icalname=$namecal;
|
||||||
$event->icalcolor=$colorcal;
|
$event->icalcolor=$colorcal;
|
||||||
$event->datep=$icalevent[DTSTART];
|
$usertime=($_SESSION['dol_tz']*60*60)+($_SESSION['dol_dst']*60*60);
|
||||||
$event->datef=$icalevent[DTEND];
|
$event->datep=$icalevent[DTSTART]+$usertime;
|
||||||
|
$event->datef=$icalevent[DTEND]+$usertime;
|
||||||
$event->type_code="ICALEVENT";
|
$event->type_code="ICALEVENT";
|
||||||
$event->libelle='<b>'.$icalevent[SUMMARY].'</b><br>'.str_replace("\\n", "<br>", "$icalevent[DESCRIPTION]");
|
$event->libelle='<b>'.$icalevent[SUMMARY].'</b><br>'.str_replace("\\n", "<br>", "$icalevent[DESCRIPTION]");
|
||||||
//$event->fulldayevent=$obj->fulldayevent;
|
//$event->fulldayevent=$obj->fulldayevent;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user