示例#1
0
 /** Diff two date objects. Only full units are returned */
 public static function diff(TimeInterval $interval, Date $date1, Date $date2) : int
 {
     if ($date1->getOffsetInSeconds() != $date2->getOffsetInSeconds()) {
         // Convert date2 to same timezone as date1. To work around PHP bug #45038,
         // not just take the timezone of date1, but construct a new one which will
         // have a timezone ID - which is required for this kind of computation.
         $tz = new TimeZone(timezone_name_from_abbr('', $date1->getOffsetInSeconds(), $date1->toString('I')));
         // Now, convert both dates to the same time (actually we only need to convert the
         // second one, as the first will remain in the same timezone)
         $date2 = $tz->translate($date2);
     }
     // Then cut off timezone, by setting both to GMT
     $date1 = DateUtil::setTimeZone($date1, new TimeZone('GMT'));
     $date2 = DateUtil::setTimeZone($date2, new TimeZone('GMT'));
     switch ($interval) {
         case TimeInterval::$YEAR:
             return -($date1->getYear() - $date2->getYear());
         case TimeInterval::$MONTH:
             return -(($date1->getYear() - $date2->getYear()) * 12 + ($date1->getMonth() - $date2->getMonth()));
         case TimeInterval::$DAY:
             return -(intval($date1->getTime() / 86400) - intval($date2->getTime() / 86400));
         case TimeInterval::$HOURS:
             return -(intval($date1->getTime() / 3600) - intval($date2->getTime() / 3600));
         case TimeInterval::$MINUTES:
             return -(intval($date1->getTime() / 60) - intval($date2->getTime() / 60));
         case TimeInterval::$SECONDS:
             return -($date1->getTime() - $date2->getTime());
     }
 }
 protected function getCriteriaMensajesEntrada()
 {
     $usuario_actual = Usuario::getUsuarioActual();
     $c = new Criteria();
     $c->addJoin(MensajeDestinoPeer::ID_MENSAJE, MensajePeer::ID_MENSAJE);
     $c->add(MensajeDestinoPeer::ID_USUARIO, $usuario_actual->getPrimaryKey());
     //solo puedo leer los mensajes que NO haya borrado el remitente!
     $criterion1 = $c->getNewCriterion(MensajePeer::BORRADO, null, Criteria::ISNULL);
     $criterion2 = $c->getNewCriterion(MensajePeer::BORRADO, false);
     $criterion1->addOr($criterion2);
     $c->addAnd($criterion1);
     $mi_date = new Date();
     $c->addAnd(MensajePeer::FECHA, $mi_date->toString(FMT_DATETIMEMYSQL), Criteria::LESS_EQUAL);
     $c->addDescendingOrderByColumn(MensajePeer::FECHA);
     return $c;
 }
function mod_todo($data, $origin)
{
    $validDate = new Date($data['year'], $data['month'], $data['day']);
    $data['deadline'] = $validDate->toString() . ' ' . $data['hour'] . ':' . $data['minute'] . ':' . $data['second'];
    if (trim($data['name']) == '') {
        $data['name'] = 'todo';
    }
    $data['name'] = text2html($data['name']);
    $data['text'] = format_msg($data['text']);
    if (!isset($data['expire'])) {
        $data['expire'] = false;
    }
    $t = new todo();
    $t->data = $data;
    $t->save();
    $_SESSION['calendar_week'] = w_dif($data['deadline']);
    redirect('todo.php?tid=' . $data['id']);
}
示例#4
0
文件: DateTest.php 项目: seytar/psx
 public function testConstructorFull()
 {
     $date = new Date(2014, 1, 1);
     $this->assertEquals('2014-01-01', $date->toString());
 }
示例#5
0
 public static function createCalendarioMes($mes, $ano, $modo)
 {
     //include_once('CalendarShow.class.php');
     $cal = new CalendarShow();
     $fecha = new Date();
     $fecha->setDay(1);
     $fecha->setMonth($mes);
     $fecha->setYear($ano);
     $fecha_uno = $fecha->toString(FMT_DATEMYSQL);
     $fecha->addMonths(1);
     $fecha->addDays(-1);
     $fecha_dos = $fecha->toString(FMT_DATEMYSQL);
     $diasEvento = array();
     $diasTareas = array();
     $c1 = TareaPeer::getCriterioAlcance();
     $crit0 = $c1->getNewCriterion(TareaPeer::FECHA_INICIO, $fecha_uno . " 00:00:00", Criteria::GREATER_EQUAL);
     $crit1 = $c1->getNewCriterion(TareaPeer::FECHA_INICIO, $fecha_dos . " 23:59:59", Criteria::LESS_EQUAL);
     $crit0->addAnd($crit1);
     $crit2 = $c1->getNewCriterion(TareaPeer::FECHA_VENCIMIENTO, $fecha_uno . " 00:00:00", Criteria::GREATER_EQUAL);
     $crit3 = $c1->getNewCriterion(TareaPeer::FECHA_VENCIMIENTO, $fecha_dos . " 23:59:59", Criteria::LESS_EQUAL);
     $crit2->addAnd($crit3);
     $crit0->addOr($crit2);
     $c1->add($crit0);
     $c1->setDistinct();
     $dias = TareaPeer::doSelect($c1);
     $ruta = UsuarioPeer::getRuta();
     foreach ($dias as $dia) {
         $fecha_inicio = $dia->getFechaInicio('Y-m-d');
         $fecha_fin = $dia->getFechaVencimiento('Y-m-d');
         if ($fecha_inicio == $fecha_fin) {
             if ($dia->getEsEvento() == '1') {
                 if (!isset($diasEvento[$fecha_inicio])) {
                     $diasEvento[$fecha_inicio] = "";
                 }
                 //$diasEvento[$fecha_inicio] .= "<div style=\"background-color: #4078B5; color: #ffffff;\"><a href=\"".$ruta."/tareas/show/?id_tarea=".$dia->getIdTarea()."\" style=\"color: #ffffff;\">".$dia->getResumen()."</a></div>";
                 $diasEvento[$fecha_inicio] .= $dia->getResumen();
             } else {
                 if (!isset($diasTareas[$fecha_inicio])) {
                     $diasTareas[$fecha_inicio] = "";
                 }
                 //$diasTareas[$fecha_inicio] .= "<div style=\"background-color: #76BB5F; color: #fff;\"><a href=\"".$ruta."/tareas/show/?id_tarea=".$dia->getIdTarea()."\" style=\"color: #ffffff;\">".$dia->getResumen()."</a></div>";
                 $diasTareas[$fecha_inicio] .= $dia->getResumen();
             }
         } else {
             if ($dia->getEsEvento() == '1') {
                 if (!isset($diasEvento[$fecha_inicio])) {
                     $diasEvento[$fecha_inicio] = "";
                 }
                 if (!isset($diasEvento[$fecha_fin])) {
                     $diasEvento[$fecha_fin] = "";
                 }
                 //$diasEvento[$fecha_inicio] .= "<div style=\"background-color: #4078B5; color: #ffffff;\"><a href=\"".$ruta."/tareas/show/?id_tarea=".$dia->getIdTarea()."\" style=\"color: #ffffff;\">Inicio Evento: ".$dia->getResumen()."</a></div>";
                 $diasEvento[$fecha_inicio] .= $dia->getResumen();
                 //$diasEvento[$fecha_fin] .= "<div style=\"background-color: #4078B5; color: #ffffff;\"><a href=\"".$ruta."/tareas/show/?id_tarea=".$dia->getIdTarea()."\" style=\"color: #ffffff;\">Vencimiento Evento: ".$dia->getResumen()."</a></div>";
                 $diasEvento[$fecha_fin] .= $dia->getResumen();
             } else {
                 if (!isset($diasTareas[$fecha_inicio])) {
                     $diasTareas[$fecha_inicio] = "";
                 }
                 if (!isset($diasTareas[$fecha_fin])) {
                     $diasTareas[$fecha_fin] = "";
                 }
                 //$diasTareas[$fecha_inicio] .= "<div style=\"background-color: #76BB5F; color: #fff;\"><a href=\"".$ruta."/tareas/show/?id_tarea=".$dia->getIdTarea()."\" style=\"color: #ffffff;\">Inicio Tarea: ".$dia->getResumen()."</a></div>";
                 $diasTareas[$fecha_inicio] .= $dia->getResumen();
                 //$diasTareas[$fecha_fin] .= "<div style=\"background-color: #76BB5F; color: #fff;\"><a href=\"".$ruta."/tareas/show/?id_tarea=".$dia->getIdTarea()."\" style=\"color: #ffffff;\">Vencimiento Tarea: ".$dia->getResumen()."</a></div>";
                 $diasTareas[$fecha_fin] .= $dia->getResumen();
             }
         }
         /*
         if ($dia->getEsEvento() == '1') {
             if (isset($diasEvento[$fecha]))
                 $diasEvento[$fecha] .= "<div style=\"background-color: #4078B5; color: #ffffff;\"><a href=\"".$ruta."/tareas/show/?id_tarea=".$dia->getIdTarea()."\" style=\"color: #ffffff;\">".$dia->getResumen()."</a></div>";
             else
                 $diasEvento[$fecha] = "<div style=\"background-color: #4078B5; color: #ffffff;\"><a href=\"".$ruta."/tareas/show/?id_tarea=".$dia->getIdTarea()."\" style=\"color: #ffffff;\">".$dia->getResumen()."</a></div>";		 		
         }
         else {
         		if (isset($diasTareas[$fecha]))
                 $diasTareas[$fecha] .= "<div style=\"background-color: #76BB5F; color: #fff;\"><a href=\"".$ruta."/tareas/show/?id_tarea=".$dia->getIdTarea()."\" style=\"color: #ffffff;\">".$dia->getResumen()."</a></div>";
         		else
         		    $diasTareas[$fecha] = "<div style=\"background-color: #76BB5F; color: #fff;\"><a href=\"".$ruta."/tareas/show/?id_tarea=".$dia->getIdTarea()."\" style=\"color: #ffffff;\">".$dia->getResumen()."</a></div>";
         }
         */
         $filters = array();
         $filters['fecha_inicio']['from'] = $dia->getFechaInicio('d/m/Y');
         $filters['fecha_inicio']['to'] = $dia->getFechaVencimiento('d/m/Y');
         if ($modo) {
             if ($fecha_inicio != $fecha_fin) {
                 $cal->setDateLink($fecha_inicio, "tareas/list?mes=" . $dia->getFechaInicio('m') . "&year=" . $dia->getFechaInicio('Y') . "&filters=" . $filters);
                 $cal->setDateLink($fecha_fin, "tareas/list?mes=" . $dia->getFechaInicio('m') . "&year=" . $dia->getFechaInicio('Y') . "&filters=" . $filters);
             } else {
                 $cal->setDateLink($fecha_inicio, "tareas/list?mes=" . $dia->getFechaInicio('m') . "&year=" . $dia->getFechaInicio('Y') . "&filters=" . $filters);
             }
         } else {
             if ($fecha_inicio != $fecha_fin) {
                 $cal->setDateLink($fecha_inicio, "1");
                 $cal->setDateLink($fecha_fin, "1");
             } else {
                 $cal->setDateLink($fecha_inicio, "1");
             }
         }
     }
     $cal->setDaysInColor($diasEvento);
     $cal->setDaysFree($diasTareas);
     return $cal;
 }
 public function dateFormatCallbackWithoutTZ()
 {
     $date = new Date('2009-09-20 21:33:00');
     $this->assertEquals($date->toString('Y-m-d H:i:s T'), $this->runTransformation(Node::fromObject($date, 'date')->getSource(), 'xp.date::format', array('string(/date/value)', "'Y-m-d H:i:s T'")));
 }
示例#7
0
 public function verFecha()
 {
     $lafecha = new Date();
     $lafecha->fromDatetime($this->getFecha());
     return $lafecha->toString(FMT_DATETIMEESGSS);
 }
示例#8
0
文件: Log.php 项目: rayful/toolkit
 public function dateText()
 {
     return Date::toString($this->date);
 }
 public function executeEnviar_alarmas()
 {
     set_time_limit(0);
     $fecha = new Date();
     $fecha_uno = $fecha->toString(FMT_DATEMYSQL);
     $c1 = new Criteria();
     $crit0 = $c1->getNewCriterion(TareaPeer::FECHA_INICIO, $fecha_uno . " 00:00:00", Criteria::GREATER_EQUAL);
     $crit1 = $c1->getNewCriterion(TareaPeer::FECHA_INICIO, $fecha_uno . " 23:59:59", Criteria::LESS_EQUAL);
     $crit4 = $c1->getNewCriterion(TareaPeer::AVISAR_EMAIL, true, Criteria::EQUAL);
     $crit0->addAnd($crit1);
     $crit0->addAnd($crit4);
     $crit2 = $c1->getNewCriterion(TareaPeer::FECHA_VENCIMIENTO, $fecha_uno . " 00:00:00", Criteria::GREATER_EQUAL);
     $crit3 = $c1->getNewCriterion(TareaPeer::FECHA_VENCIMIENTO, $fecha_uno . " 23:59:59", Criteria::LESS_EQUAL);
     $crit5 = $c1->getNewCriterion(TareaPeer::AVISAR_EMAIL_FIN, true, Criteria::EQUAL);
     $crit2->addAnd($crit3);
     $crit2->addAnd($crit5);
     $crit0->addOr($crit2);
     $c1->add($crit0);
     $c1->setDistinct();
     $tareas_hoy = TareaPeer::doSelect($c1);
     foreach ($tareas_hoy as $tarea) {
         $asunto = $tarea->getResumen();
         $fecha_uno = $tarea->getFechaInicio('d/m/Y');
         $fecha_dos = $tarea->getFechaVencimiento('d/m/Y');
         if ($fecha_uno != $fecha_dos && $fecha_uno == date('d/m/Y')) {
             $cuerpo .= "<strong>Legedia</strong> - Inicio de ";
             $cuerpo .= $tarea->getEsEvento() ? "evento: " : "tarea: ";
         } elseif ($fecha_uno != $fecha_dos && $fecha_dos == date('d/m/Y')) {
             $cuerpo = "<strong>Legedia</strong> - Vencimiento de ";
             $cuerpo .= $tarea->getEsEvento() ? "evento: " : "tarea: ";
         } else {
             $cuerpo = "<strong>Legedia</strong> - " . $tarea->getEsEvento() ? "Evento:" : "Tarea: ";
         }
         $cuerpo .= $tarea->getResumen() . "<br />";
         $cuerpo .= "Inicio: " . $fecha_uno . "<br />";
         $cuerpo .= "Fin: " . $fecha_dos . "<br />";
         $cuerpo .= $tarea->getDescripcion();
         if ($tarea->getIdFormulario() != 0) {
             $form = FormularioPeer::retrieveByPK($tarea->getIdFormulario());
             if ($form instanceof Formulario) {
                 $cuerpo .= "Objeto relacionado: <a href=\"" . UsuarioPeer::getRuta() . "formularios/edit?id_formulario=" . $tarea->getIdFormulario() . "\">" . $form->__toString() . "</a>";
             }
         }
         $cuerpo .= "<br /><br />Muchas gracias<br /><br />Un Saludo<br />Administrador <strong>LEGEDIA</strong>\n";
         $mens = new Mensaje();
         $mens->setAsunto($asunto);
         $mens->setCuerpo($cuerpo);
         $mens->setEmail(true);
         $mens->setFecha(time());
         $mens->save();
         $c = new Criteria();
         $c->addAnd(MensajeDestinoPeer::ID_MENSAJE, $mens->getPrimaryKey());
         MensajeDestinoPeer::doDelete($c);
         $mensajeDestino = new MensajeDestino();
         $mensajeDestino->setIdMensaje($mens->getPrimaryKey());
         $mensajeDestino->setIdUsuario($tarea->getUsuario()->getIdUsuario());
         $mensajeDestino->save();
         echo $tarea->getUsuario()->getEmail() . "::" . $asunto . "<br />" . $cuerpo . "<br /><br />";
         if (trim($tarea->getUsuario()->getEmail()) != "") {
             $enviado = MensajePeer::enviarEmailDefault($tarea->getIdEmpresa(), $asunto, $cuerpo, array($tarea->getUsuario()->getEmail()));
         }
     }
     echo "ENVIADOS: " . $enviado;
     return sfView::NONE;
 }
示例#10
0
                                     <div class="day">
                                         <?php 
 echo $d;
 ?>
                                     </div>
                                 </div>
                                 <div class="daytitle">
                                     <?php 
 echo $doy->days[$w - 1] . ' ' . $d . ' ' . $doy->months[$m - 1];
 ?>
                                 </div>
                                 
                                 
                                 <?php 
 $date_obj = new Date($year, $m, $d);
 $in = $date_obj->toString("in");
 echo "<div class=\"hiddenDate\">" . $in . "</div>";
 if ($access_rights == Rights::$LIMITED_ACCESS) {
     $my_contents = $child->getContentsByStartingDate($in, $user->getType());
 } else {
     if ($access_rights == Rights::$FULL_ACCESS) {
         $medical = $child->getContentsByStartingDate($in, "doctor");
         $teaching = $child->getContentsByStartingDate($in, "teacher");
         $family = $child->getContentsByStartingDate($in, "family");
     }
 }
 ?>
                                 
                                 <?php 
 if ($access_rights == Rights::$LIMITED_ACCESS) {
     ?>
    $person = array();
    $query = 'select person.id,person.first_name,person.last_name';
    $query .= ' from person';
    if ($gid) {
        $query .= ',pg where person.id=pg.pid and pg.gid="' . $gid . '"';
    }
    $query .= ' order by last_name';
    global $db;
    $personen = $db->query($query);
    while (list($p['id'], $p['first_name'], $p['last_name']) = mysql_fetch_row($personen)) {
        $person[] = $p;
    }
    return $person;
}
$output->secure();
$data = $_POST['data'];
$validDate = new Date($data['year'], $data['month'], $data['day']);
$data['deadline'] = $validDate->toString() . ' ' . $data['hour'] . ':' . $data['minute'] . ':' . $data['second'];
if (!isset($data['expire'])) {
    $data['expire'] = false;
}
$ids = array();
if ($_POST['group']) {
    foreach ($data as $index => $value) {
        $v['data[' . $index . ']'] = $value;
    }
    $ids = complete_ids('g', 'group', $v, $_SESSION['userid']);
}
add_todo($data, $ids);
$_SESSION['calendar_week'] = w_dif($data['deadline']);
redirect('./');
 function dateFunctionTest()
 {
     $date = new Date();
     $myDate = $date->toString($this->myconn->getFormatter()->dialect->dateFormat);
     $syDate = $date->toString($this->syconn->getFormatter()->dialect->dateFormat);
     $pgDate = $date->toString($this->pgconn->getFormatter()->dialect->dateFormat);
     $sqDate = $date->toString($this->sqconn->getFormatter()->dialect->dateFormat);
     $this->assertProjection('cast(sysdate() as char)', 'convert(varchar, getdate())', 'str(getdate())', 'php(\'strval\', php(\'date\', \'Y-m-d H:i:s\', php(\'time\')))', create(new Criteria())->setProjection(SQLFunctions::str(SQLFunctions::getdate())));
     $this->assertProjection('cast(timestampadd(month, -4, sysdate()) as char)', 'convert(varchar, dateadd(month, -4, getdate()))', 'str(dateadd(month, -4, getdate()))', 'php(\'strval\', dateadd("m", -4, php(\'date\', \'Y-m-d H:i:s\', php(\'time\'))))', create(new Criteria())->setProjection(SQLFunctions::str(SQLFunctions::dateadd('month', '-4', SQLFunctions::getdate()))));
     $this->assertProjection('timestampdiff(second, timestampadd(day, -4, sysdate()), sysdate())', 'datediff(second, dateadd(day, -4, getdate()), getdate())', 'datediff(second, dateadd(day, -4, getdate()), getdate())', 'datediff_not_implemented', create(new Criteria())->setProjection(SQLFunctions::datediff('second', SQLFunctions::dateadd('day', '-4', SQLFunctions::getdate()), SQLFunctions::getdate())));
     $this->assertProjection('cast(extract(hour from sysdate()) as char)', 'datename(hour, getdate())', 'datename(hour, getdate())', 'php(\'strval\', php(\'idate\', "H", php(\'strtotime\', php(\'date\', \'Y-m-d H:i:s\', php(\'time\')))))', create(new Criteria())->setProjection(SQLFunctions::datename('hour', SQLFunctions::getdate())));
     $this->assertProjection('extract(hour from \'' . $myDate . '\')', 'datepart(hour, \'' . $syDate . '\')', 'datepart(hour, \'' . $pgDate . '\')', 'php(\'idate\', "H", php(\'strtotime\', \'' . $sqDate . '\'))', create(new Criteria())->setProjection(SQLFunctions::datepart('hour', $date)));
 }
示例#13
0
 public function executeSubir()
 {
     /*Guarda un archivo en la carpeta web/upload/backups */
     Usuario::usuarioActualPermisos($this, 'backups', 'subir', true, sfRequest::POST);
     $nombreRecibido = $this->getRequestParameter('archivo_subir');
     $archivoSubir = $this->getRequest()->getFile('archivo_subir');
     $directorio = sfConfig::get('app_directorio_backups');
     $backup = array();
     if ($archivoSubir = $this->getRequest()->getFile('archivo_subir')) {
         if (!empty($archivoSubir)) {
             $this->getRequest()->moveFile('archivo_subir', $directorio . $archivoSubir['name'], 0664, true, 0775);
             $minombre = $directorio . $archivoSubir['name'];
             $mi_archivo = fopen($minombre, "r");
             if (!$mi_archivo) {
                 $this->getUser()->setFlash('notice_error', 'No se ha subido correctamente el fichero');
             }
             $contenido = '';
             while (!feof($mi_archivo)) {
                 $linea = fgets($mi_archivo, 1024);
                 $contenido = $contenido . $linea;
             }
             fclose($mi_archivo);
             $miDate = new Date();
             $backup = array('nombre' => $archivoSubir['name'], 'fecha' => $miDate->toString(FMT_DATETIMEMYSQL), 'tamano' => $archivoSubir['size']);
             return $this->redirect('backups/index');
         }
         //if
     }
     //if
     return $this->redirect('backups/index');
 }
示例#14
0
 /**
  * Retrieve whether a given date object is in daylight savings time.
  *
  * @param   util.Date date
  * @param   int method default CAL_DST_EU Method to calculate (CAL_DST_EU|CAL_DST_US)
  * @return  bool
  */
 public static function inDst(Date $date)
 {
     return (bool) $date->toString('I');
 }
示例#15
0
?>
</head>

<body>
<?php 
//get the children from the request
$children = array();
$length = count($_POST['children']);
for ($i = 0; $i < $length; $i++) {
    $string = $_POST['children'][$i];
    // print 'DEBUG>> : $string vaut '.$string;
    $email = split(",", $string)[0];
    //  print 'DEBUG>> : $email vaut '.$email;
    $date_en = split(",", $string)[1];
    $date = new Date($date_en, "en");
    $date_in = $date->toString("in");
    //  print 'DEBUG>> : $date vaut '.$date_in."MM";
    $children[] = array('email' => $email, 'dateStart' => $date_in, 'dateEnd' => $date_in);
    //  print 'DEBUG>> : $children[0] vaut '.$children[0]['dateStart']."MM";
    //$children[] = array('email' => "*****@*****.**", 'date' => "01/01/1901");
}
$size = count($_FILES['files']['tmp_name']);
for ($i = 1; $i < $size; $i++) {
    //Iterate over the files(start 1)
    // UPLOAD SUR EC2
    $path = "/var/www/html/";
    $name = $_FILES['files']['name'][$i];
    $path = $path . $name;
    //echo move_uploaded_file($_FILES['files']['tmp_name'][$i], $path);
    /*if(move_uploaded_file($_FILES['files']['tmp_name'][$i], $path))
      {
示例#16
0
 public function toStringOutput()
 {
     $date = new Date('2007-11-10 20:15+0100');
     $this->assertEquals('2007-11-10 20:15:00+0100', $date->toString());
     $this->assertEquals('2007-11-10 19:15:00+0000', $date->toString(Date::DEFAULT_FORMAT, new TimeZone(NULL)));
 }
示例#17
0
 public function getUltimoSuceso()
 {
     $sucesos = $this->getSesionLogs();
     $lafecha = new Date();
     if ($sucesos) {
         $lafecha->fromDatetime($sucesos[sizeof($sucesos) - 1]->getFecha());
         return $lafecha->toString(FMT_DATETIMEESGSS);
     } else {
         return "--";
     }
 }
示例#18
0
文件: editor.php 项目: rayful/toolkit
 protected function _input_datetime($key, $value)
 {
     $value = Date::toString($value, "Y-m-d\\TH:i:s");
     echo "<input class='form-control' type=datetime-local name=\"{$key}\" value=\"{$value}\">";
 }
 function testGoodRepair()
 {
     $date = new Date('1999', '04', '31');
     $this->assertEquals('1999-04-30', $date->toString());
 }