From 10c318f9076e9c6763087813e3b685ab5ab4462c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Ca=C3=B1as=20Vargas?= Date: Mon, 30 Sep 2019 12:54:10 +0200 Subject: [PATCH] Version19.26.1 --- swad_changelog.h | 3 ++- swad_game.c | 18 +++++++++++++++++- 2 files changed, 19 insertions(+), 2 deletions(-) diff --git a/swad_changelog.h b/swad_changelog.h index 8549d4aca..e28d12871 100644 --- a/swad_changelog.h +++ b/swad_changelog.h @@ -476,10 +476,11 @@ enscript -2 --landscape --color --file-align=2 --highlight --line-numbers -o - * En OpenSWAD: ps2pdf source.ps destination.pdf */ -#define Log_PLATFORM_VERSION "SWAD 19.26 (2019-09-30)" +#define Log_PLATFORM_VERSION "SWAD 19.26.1 (2019-09-30)" #define CSS_FILE "swad19.15.css" #define JS_FILE "swad19.15.js" /* + Version 19.26.1: Sep 30, 2019 Changes in edition of games. (246760 lines) Version 19.26: Sep 30, 2019 Changes in edition of games. (246743 lines) Version 19.25.3: Sep 30, 2019 Fixed bug: students should not see icon to add a match. (246745 lines) Version 19.25.2: Sep 30, 2019 Fixed bug in match results. (246744 lines) diff --git a/swad_game.c b/swad_game.c index 365521d3d..5ca293bb2 100644 --- a/swad_game.c +++ b/swad_game.c @@ -1187,7 +1187,7 @@ void Gam_RecFormGame (void) NewGame.GamCod = Gam_GetParamGameCod (); /***** Check if game has matches *****/ - if (Gam_GetNumMchsGameAndCheckIfEditable (&NewGame)) + if (Gam_CheckIfICanEditGames ()) { ItsANewGame = (NewGame.GamCod < 0); if (!ItsANewGame) @@ -1233,6 +1233,8 @@ void Gam_RecFormGame (void) else Gam_RequestCreatOrEditGame (); } + else + Act_NoPermissionExit (); /***** Show games again *****/ Gam_ListAllGames (); @@ -1333,6 +1335,8 @@ void Gam_RequestNewQuestion (void) Gam_SetParamCurrentGamCod (Game.GamCod); // Used to pass parameter Tst_ShowFormAskSelectTstsForGame (); } + else + Act_NoPermissionExit (); /***** Show current game *****/ Gam_ShowOneGame (Game.GamCod, @@ -1360,6 +1364,8 @@ void Gam_ListTstQuestionsToSelect (void) Gam_SetParamCurrentGamCod (Game.GamCod); // Used to pass parameter Tst_ListQuestionsToSelect (); } + else + Act_NoPermissionExit (); } /*****************************************************************************/ @@ -1856,6 +1862,8 @@ void Gam_AddTstQuestionsToGame (void) /***** Free space for selected question codes *****/ Gam_FreeListsSelectedQuestions (); } + else + Act_NoPermissionExit (); /***** Show current game *****/ Gam_ShowOneGame (Game.GamCod, @@ -1953,6 +1961,8 @@ void Gam_RequestRemoveQst (void) Ale_QUESTION,Txt_Do_you_really_want_to_remove_the_question_X, QstInd); } + else + Act_NoPermissionExit (); /***** Show current game *****/ Gam_ShowOneGame (Game.GamCod, @@ -2009,6 +2019,8 @@ void Gam_RemoveQst (void) /***** Write message *****/ Ale_ShowAlert (Ale_SUCCESS,Txt_Question_removed); } + else + Act_NoPermissionExit (); /***** Show current game *****/ Gam_ShowOneGame (Game.GamCod, @@ -2056,6 +2068,8 @@ void Gam_MoveUpQst (void) else Ale_ShowAlert (Ale_WARNING,Txt_Movement_not_allowed); } + else + Act_NoPermissionExit (); /***** Show current game *****/ Gam_ShowOneGame (Game.GamCod, @@ -2113,6 +2127,8 @@ void Gam_MoveDownQst (void) else Ale_ShowAlert (Ale_WARNING,Txt_This_game_has_no_questions); } + else + Act_NoPermissionExit (); /***** Show current game *****/ Gam_ShowOneGame (Game.GamCod,