Fixing PDF export + adding new date format DATE_FORMAT_NUMBER_NO_YEAR like dd/mm see BT#4940

skala
Julio Montoya 13 years ago
parent 6a4b2b5e5f
commit 51af158440
  1. 2
      main/attendance/attendance_controller.php
  2. 2
      main/attendance/attendance_sheet.php
  3. 8
      main/inc/lib/internationalization.lib.php
  4. 17
      main/lang/english/trad4all.inc.php
  5. 1
      main/lang/spanish/admin.inc.php
  6. 1
      main/lang/spanish/index.inc.php
  7. 7
      main/lang/spanish/trad4all.inc.php

@ -443,7 +443,7 @@
$head_table = array('#', get_lang('Name'));
foreach ($data_array['attendant_calendar'] as $class_day) {
//$head_table[] = api_format_date($class_day['date_time'], DATE_FORMAT_SHORT).' <br />'.api_format_date($class_day['date_time'], TIME_NO_SEC_FORMAT);
$head_table[] = api_format_date($class_day['date_time'], DATE_FORMAT_NUMBER);
$head_table[] = api_format_date($class_day['date_time'], DATE_FORMAT_NUMBER_NO_YEAR);
}
$data_table[] = $head_table;

@ -65,7 +65,7 @@ if (api_is_allowed_to_edit(null, true)) {
if (count($users_in_course) > 0) {
$form->display();
}
echo '<a id="pdf_export" style="float:left;" href="index.php?'.api_get_cidreq().'&action=attendance_sheet_export_to_pdf&attendance_id='.$attendance_id.$param_gradebook.'">'.
echo '<a id="pdf_export" style="float:left;" href="index.php?'.api_get_cidreq().'&action=attendance_sheet_export_to_pdf&attendance_id='.$attendance_id.$param_gradebook.'&filter='.$default_filter.'">'.
Display::return_icon('pdf.png',get_lang('ExportToPDF'),'',ICON_SIZE_MEDIUM).'</a>';
echo '</div>';
}

@ -33,6 +33,7 @@ define('DATE_TIME_FORMAT_LONG_24H', 5); // August 25, 2009 at 15:28
define('DATE_TIME_FORMAT_SHORT', 6); // Aug 25, 2009 at 03:28 PM
define('DATE_TIME_FORMAT_SHORT_TIME_FIRST', 7); // 03:28 PM, Aug 25 2009
define('DATE_FORMAT_NUMBER_NO_YEAR', 8); // 25.08
// Formatting person's name.
define('PERSON_NAME_COMMON_CONVENTION', 0); // Formatting a person's name using the pattern as it has been
@ -689,6 +690,13 @@ function api_format_date($time, $format = null, $language = null) {
if (is_int($format)) {
switch ($format) {
case DATE_FORMAT_NUMBER_NO_YEAR:
$date_format = get_lang('dateFormatShortNumberNoYear', '', $language);
if (IS_PHP_53 && INTL_INSTALLED) {
$datetype = IntlDateFormatter::SHORT;
$timetype = IntlDateFormatter::NONE;
}
break;
case DATE_FORMAT_NUMBER:
$date_format = get_lang('dateFormatShortNumber', '', $language);
if (IS_PHP_53 && INTL_INSTALLED) {

@ -976,6 +976,7 @@ $NumberOfCoursesPrivate = "Number of private courses";
$NumberOfCoursesClosed = "Number of closed courses";
$NumberOfCoursesTotal = "Total number of courses";
$NumberOfUsersActive = "Number of active users";
$dateFormatShortNumberNoYear = "%d/%m";
$CourseTutor = "Course tutor";
$StudentInSessionCourse = "Student in session course";
$StudentInCourse = "Student in course";
@ -1002,13 +1003,13 @@ $YouMustAcceptLicence = "You must accept the licence";
$SelectOne = "Select one";
$ContactInformationHasBeenSent = "Contact information has been sent";
$UserInactivedSinceX = "User inactive since %s";
$ContactInformationDescription = "Dear user,<br />
<br />You are about to start using one of the best open-source e-learning platform on the market. Like many other open-source project, this project is backed up by a large community of students, teachers, developers and content creators who would like to promote the project better.<br />
<br />
By knowing a little bit more about you, one of our most important users, who will manage this e-learning system, we will be able to let people know that our software is used and let you know when we organize events that might be relevant to you.<br />
<br />
By filling this form, you accept that the Chamilo association or its members might send you information by e-mail about important events or updates in the Chamilo software or community. This will help the community grow as an organized entity where information flow, with a permanent respect of your time and your privacy.<br />
<br />
$ContactInformationDescription = "Dear user,<br />
<br />You are about to start using one of the best open-source e-learning platform on the market. Like many other open-source project, this project is backed up by a large community of students, teachers, developers and content creators who would like to promote the project better.<br />
<br />
By knowing a little bit more about you, one of our most important users, who will manage this e-learning system, we will be able to let people know that our software is used and let you know when we organize events that might be relevant to you.<br />
<br />
By filling this form, you accept that the Chamilo association or its members might send you information by e-mail about important events or updates in the Chamilo software or community. This will help the community grow as an organized entity where information flow, with a permanent respect of your time and your privacy.<br />
<br />
Please note that you are <b>not required</b> to fill this form. If you want to remain anonymous, we will loose the opportunity to offer you all the privileges of being a registered portal administrator, but we will respect your decision. Simply leave this form empty and click \"Next\".<br /><br />";
$CompanyActivity = "Your company's activity";
$DateUnLock = "Unlock date";
@ -1214,7 +1215,7 @@ $SaveForNow = "Save and continue later";
$NoQuicktime = "Your browser does not have the QuickTime plugin installed. You can still use the platform, but to run a larger number of media file types, we suggest you might want to install it.";
$NoJavaSun = "Your browser doesn't seem to have the Sun Java plugin installed. You can still use the platform, but you will lose a few of its capabilities.";
$NoJava = "Your browser does not support Java";
$JavaSun24 = "Your browser has a Java version not supported by this tool.
$JavaSun24 = "Your browser has a Java version not supported by this tool.
To use it you have to install a Java Sun version higher than 24";
$NoMessageAnywere = "If you do not want to see this message again during this session, click here";
$Attempts = "Attempts";

@ -1253,6 +1253,7 @@ $SessionStartDate = "Fecha de inicio de acceso";
$SessionDisplayEndDate = "Fecha de fin a mostrar";
$SessionDisplayStartDate = "Fecha de inicio a mostrar";
$UserHasNoCourse = "El usuario no tiene inscripción a cursos";
$SessionTutorsCanSeeExpiredSessionsResultsTitle = "Visibilidad de reportes para los tutores de sesión";
$TheXMLImportLetYouAddMoreInfoAndCreateResources = "La importación XML le permitirá añadir más información y crear recursos (cursos, usuarios), mientras la importación CSV solamente creará sesiones y usará recursos ya existentes.";
$ShowLinkBugNotificationTitle = "Mostrar el enlace para informar de errores";
$ShowLinkBugNotificationComment = "Mostrar un enlace en la cabecera para informar de un error a la plataforma de apoyo (http://support.chamilo.org). Al hacer clic en el enlace el usuario será dirigido al sistema de soporte de Chamilo, en el que una página wiki describe el procedimiento para informar de errores.";

@ -77,5 +77,6 @@ $Username = "Nombre de usuario";
$GoAheadAndBrowseOurCourseCatalogXOnceRegisteredYouWillSeeTheCourseHereX = "Adelante, vaya al catálogo de cursos %s para inscribirte en un curso que le interese. Una vez inscrito/a, el curso aparecerá %s, en lugar de este mensaje.";
$HelloXAsYouCanSeeYourCourseListIsEmpty = "Hola %s, te deseamos la bienvenida,<br />
Como puedes ver, tu lista de cursos todavía está vacía. Esto es porque no estás inscrito/a a algun curso todavía!";
$PleaseAllowUsALittleTimeToSubscribeYouToOneOfOurCourses = "Permitanos un poco de tiempo para suscribirse a uno de nuestros cursos. Si considera que nos olvidamos de Ud., póngase en contacto con los administradores del portal. Puede encontrar sus datos de contacto en el pie de página.";
$Profile = "Perfil";
?>

@ -977,6 +977,13 @@ $NumberOfCoursesPrivate = "Número de cursos privados";
$NumberOfCoursesClosed = "Número de cursos cerrados";
$NumberOfCoursesTotal = "Número total de cursos";
$NumberOfUsersActive = "Número de usuarios activos";
$dateFormatShortNumberNoYear = "%d/%m";
$CourseTutor = "Tutor de curso";
$StudentInSessionCourse = "Estudiante en un curso de sesión";
$StudentInCourse = "Estudiante en un curso";
$SessionGeneralCoach = "Tutor general de sesión";
$SessionCourseCoach = "Tutor de curso de sesión";
$Admin = "Admin";
$UserNotAttendedSymbol = "F";
$UserAttendedSymbol = "P";
$Order = "Orden";

Loading…
Cancel
Save