From 39a95f5294f1e2554f495ca0b67602ff2e8353d6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Ca=C3=B1as=20Vargas?= Date: Sun, 9 Oct 2016 00:37:58 +0200 Subject: [PATCH] Version 16.17.13 --- swad_changelog.h | 3 ++- swad_report.c | 22 ++++++++-------------- 2 files changed, 10 insertions(+), 15 deletions(-) diff --git a/swad_changelog.h b/swad_changelog.h index 0d01f8bb5..9a00ea0c8 100644 --- a/swad_changelog.h +++ b/swad_changelog.h @@ -148,13 +148,14 @@ /****************************** Public constants *****************************/ /*****************************************************************************/ -#define Log_PLATFORM_VERSION "SWAD 16.17.12 (2016-10-09)" +#define Log_PLATFORM_VERSION "SWAD 16.17.13 (2016-10-09)" #define CSS_FILE "swad15.229.css" #define JS_FILE "swad15.238.1.js" // Number of lines (includes comments but not blank lines) has been got with the following command: // nl swad*.c swad*.h css/swad*.css py/swad*.py js/swad*.js soap/swad*.h sql/swad*.sql | tail -1 /* + Version 16.17.13: Oct 09, 2016 Code refactoring in user's usage report. (206273 lines) Version 16.17.12: Oct 09, 2016 Code refactoring in user's usage report. (206278 lines) Version 16.17.11: Oct 09, 2016 Code refactoring in user's usage report. (206279 lines) Version 16.17.10: Oct 09, 2016 Code refactoring in user's usage report. (206285 lines) diff --git a/swad_report.c b/swad_report.c index 1ee29f9cf..e85ee5c08 100644 --- a/swad_report.c +++ b/swad_report.c @@ -116,10 +116,7 @@ static void Rep_WriteSectionUsrInfo (void); static void Rep_WriteSectionUsrFigures (const struct Rep_Report *Report); static void Rep_WriteSectionHitsPerAction (const struct UsrFigures *UsrFigures); static void Rep_WriteSectionGlobalHits (const struct Rep_Report *Report); -static void Rep_WriteSectionCurrentCourses (const struct UsrFigures *UsrFigures, - const struct tm *tm_FirstClickTime, - const struct Rep_CurrentTimeUTC *CurrentTimeUTC, - unsigned long MaxHitsPerYear); +static void Rep_WriteSectionCurrentCourses (const struct Rep_Report *Report); static void Rep_WriteSectionHistoricCourses (const struct UsrFigures *UsrFigures, const struct tm *tm_FirstClickTime, unsigned long MaxHitsPerYear); @@ -246,8 +243,7 @@ static void Rep_CreateMyUsageReport (struct Rep_Report *Report) /***** Current courses *****/ Report->MaxHitsPerYear = Rep_GetMaxHitsPerYear (Report->UsrFigures.FirstClickTimeUTC); - Rep_WriteSectionCurrentCourses (&Report->UsrFigures,&Report->tm_FirstClickTime, - &Report->CurrentTimeUTC,Report->MaxHitsPerYear); + Rep_WriteSectionCurrentCourses (Report); /***** Historic courses *****/ Rep_WriteSectionHistoricCourses (&Report->UsrFigures,&Report->tm_FirstClickTime, @@ -848,10 +844,7 @@ static void Rep_WriteSectionHitsPerAction (const struct UsrFigures *UsrFigures) /****** Write section for user's current courses in user's usage report ******/ /*****************************************************************************/ -static void Rep_WriteSectionCurrentCourses (const struct UsrFigures *UsrFigures, - const struct tm *tm_FirstClickTime, - const struct Rep_CurrentTimeUTC *CurrentTimeUTC, - unsigned long MaxHitsPerYear) +static void Rep_WriteSectionCurrentCourses (const struct Rep_Report *Report) { extern const char *Txt_Courses; Rol_Role_t Role; @@ -860,8 +853,8 @@ static void Rep_WriteSectionCurrentCourses (const struct UsrFigures *UsrFigures, fprintf (Gbl.F.Rep,"
" "

%s", Txt_Courses); - if (CurrentTimeUTC->StrDate[0]) - fprintf (Gbl.F.Rep," (%s)",CurrentTimeUTC->StrDate); + if (Report->CurrentTimeUTC.StrDate[0]) + fprintf (Gbl.F.Rep," (%s)",Report->CurrentTimeUTC.StrDate); fprintf (Gbl.F.Rep,"

" ""