diff --git a/swad_changelog.h b/swad_changelog.h index ccd4337ab..ac0e68c44 100644 --- a/swad_changelog.h +++ b/swad_changelog.h @@ -134,13 +134,15 @@ /****************************** Public constants *****************************/ /*****************************************************************************/ -#define Log_PLATFORM_VERSION "SWAD 15.220 (2016-06-08)" +#define Log_PLATFORM_VERSION "SWAD 15.220.1 (2016-06-08)" #define CSS_FILE "swad15.218.css" #define JS_FILE "swad15.216.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 15.220.2: Jun 08, 2016 Single (radio) selection of number of indicators changed to multiple (checkbox) selection. (? lines) + Version 15.220.1: Jun 08, 2016 Code refactoring in form to view indicators of courses. (202031 lines) Version 15.220: Jun 08, 2016 Number of indicators now appears inside form. (202029 lines) Version 15.219.1: Jun 05, 2016 Highlighted row with number of indicators selected. (202023 lines) Version 15.219: Jun 04, 2016 Changes in listing of indicators of courses. (202001 lines) diff --git a/swad_indicator.c b/swad_indicator.c index 50bb84b11..23bdbb8b8 100644 --- a/swad_indicator.c +++ b/swad_indicator.c @@ -94,6 +94,27 @@ void Ind_ReqIndicatorsCourses (void) unsigned NumCrssWithIndicatorYes[1+Ind_NUM_INDICATORS]; unsigned NumCrssToList; + /***** Get scope *****/ + Gbl.Scope.Allowed = 1 << Sco_SCOPE_SYS | + 1 << Sco_SCOPE_CTY | + 1 << Sco_SCOPE_INS | + 1 << Sco_SCOPE_CTR | + 1 << Sco_SCOPE_DEG | + 1 << Sco_SCOPE_CRS; + Gbl.Scope.Default = Sco_SCOPE_CRS; + Sco_GetScope (); + + /***** Get courses from database *****/ + /* The result will contain courses with any number of indicators + If Gbl.Stat.NumIndicators < 0 ==> all courses in result will be listed + If Gbl.Stat.NumIndicators >= 0 ==> only those courses in result + with Gbl.Stat.NumIndicators set to yes + will be listed */ + NumCrss = Ind_GetTableOfCourses (&mysql_res); + + /***** Get vector with numbers of courses with 0, 1, 2... indicators set to yes *****/ + Ind_GetNumCoursesWithIndicators (NumCrssWithIndicatorYes,NumCrss,mysql_res); + /***** Start frame *****/ Lay_StartRoundFrame (NULL,Txt_Indicators_of_courses,NULL); @@ -108,14 +129,7 @@ void Ind_ReqIndicatorsCourses (void) "" "