From f97c3d8ad1b406543b5000f17259315f523e901d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Ca=C3=B1as=20Vargas?= Date: Sun, 29 Sep 2019 18:24:08 +0200 Subject: [PATCH] Version19.19.1 --- swad_changelog.h | 2 +- swad_group.c | 2 +- swad_match.c | 19 ++++++++++++------- 3 files changed, 14 insertions(+), 9 deletions(-) diff --git a/swad_changelog.h b/swad_changelog.h index 495ffe623..041a4ad40 100644 --- a/swad_changelog.h +++ b/swad_changelog.h @@ -475,7 +475,7 @@ ps2pdf source.ps destination.pdf #define CSS_FILE "swad19.15.css" #define JS_FILE "swad19.15.js" /* - Version 19.19.1: Sep 29, 2019 Students will not see matches for groups to which they don't belong. + Version 19.19.1: Sep 29, 2019 Students will not see matches for groups to which they don't belong. (246601 lines) Version 19.19: Sep 29, 2019 Selections of my groups/all groups in listing of matches. Removed column with number of match. (246596 lines) Version 19.18.2: Sep 28, 2019 Code refactoring related to errors. (246585 lines) diff --git a/swad_group.c b/swad_group.c index fe8d163da..b2dc3092a 100644 --- a/swad_group.c +++ b/swad_group.c @@ -5059,7 +5059,7 @@ void Grp_GetParamWhichGrps (void) case ActPrnCrsTT: // Print course timetable case ActChgCrsTT1stDay:// Change first day of week in course timetable case ActSeeAsg: // List assignments - case ActSeeGam: // List games + case ActSeeAllGam: // List games case ActSeeAllSvy: // List surveys case ActSeeAtt: // List attendance /* diff --git a/swad_match.c b/swad_match.c index 001b73a4c..fb4426a59 100644 --- a/swad_match.c +++ b/swad_match.c @@ -635,6 +635,7 @@ static void Mch_ListOneOrMoreMatchesStatus (const struct Match *Match,unsigned N { extern const char *Txt_Play; extern const char *Txt_Resume; + bool IBelongToGroups; fprintf (Gbl.F.Out,"",Gbl.RowEvenOdd); @@ -646,13 +647,17 @@ static void Mch_ListOneOrMoreMatchesStatus (const struct Match *Match,unsigned N switch (Gbl.Usrs.Me.Role.Logged) { case Rol_STD: - /* Icon to play as student */ - Mch_CurrentMchCod = Match->MchCod; - Lay_PutContextualLinkOnlyIcon (ActPlyMchStd,NULL, - Mch_PutParams, - Match->Status.QstInd < Mch_AFTER_LAST_QUESTION ? "play.svg" : - "flag-checkered.svg", - Txt_Play); + IBelongToGroups = Mch_CheckIfIPlayThisMatchBasedOnGrps (Match->MchCod); + if (IBelongToGroups) + { + /* Icon to play as student */ + Mch_CurrentMchCod = Match->MchCod; + Lay_PutContextualLinkOnlyIcon (ActPlyMchStd,NULL, + Mch_PutParams, + Match->Status.QstInd < Mch_AFTER_LAST_QUESTION ? "play.svg" : + "flag-checkered.svg", + Txt_Play); + } break; case Rol_NET: case Rol_TCH: