Version 22.39.1: Oct 02, 2022 Changes in dialog to reset a survey.

This commit is contained in:
acanas 2022-10-03 21:32:31 +02:00
parent 660af0abcc
commit 759f513ed5
2 changed files with 9 additions and 24 deletions

View File

@ -606,12 +606,12 @@ TODO: Fix bug: error al enviar un mensaje a dos recipientes, error on duplicate
TODO: Attach pdf files in multimedia. TODO: Attach pdf files in multimedia.
*/ */
#define Log_PLATFORM_VERSION "SWAD 22.39 (2022-10-02)" #define Log_PLATFORM_VERSION "SWAD 22.39.1 (2022-10-02)"
#define CSS_FILE "swad22.35.css" #define CSS_FILE "swad22.35.css"
#define JS_FILE "swad21.100.js" #define JS_FILE "swad21.100.js"
/* /*
Version 22.39.2: Oct 02, 2022 TODO: El botón de "Eliminar evento" debería salir dentro del diálogo. (? lines) Version 22.39.2: Oct 02, 2022 TODO: El botón de "Eliminar evento" debería salir dentro del diálogo. (? lines)
Version 22.39.1: Oct 02, 2022 TODO: El botón de "Poner encuesta a cero" debería salir dentro del diálogo, igual que el de borrar encuesta. (? lines) Version 22.39.1: Oct 02, 2022 Changes in dialog to reset a survey. (332527 lines)
Version 22.39: Oct 02, 2022 Code refactoring and changes in layout of attendance events. (332537 lines) Version 22.39: Oct 02, 2022 Code refactoring and changes in layout of attendance events. (332537 lines)
Version 22.38: Oct 02, 2022 Code refactoring and changes in layout of surveys. (332518 lines) Version 22.38: Oct 02, 2022 Code refactoring and changes in layout of surveys. (332518 lines)
Version 22.37.2: Oct 01, 2022 Fixed minor issues in layout. (332526 lines) Version 22.37.2: Oct 01, 2022 Fixed minor issues in layout. (332526 lines)

View File

@ -110,8 +110,6 @@ static void Svy_GetListSurveys (struct Svy_Surveys *Surveys);
static void Svy_SetAllowedAndHiddenScopes (unsigned *ScopesAllowed, static void Svy_SetAllowedAndHiddenScopes (unsigned *ScopesAllowed,
unsigned *HiddenAllowed); unsigned *HiddenAllowed);
static void Svy_PutButtonToResetSurvey (struct Svy_Surveys *Surveys);
static void Svy_SetDefaultAndAllowedScope (struct Svy_Survey *Svy); static void Svy_SetDefaultAndAllowedScope (struct Svy_Survey *Svy);
static void Svy_ShowLstGrpsToEditSurvey (long SvyCod); static void Svy_ShowLstGrpsToEditSurvey (long SvyCod);
static void Svy_CreateSurvey (struct Svy_Survey *Svy,const char *Txt); static void Svy_CreateSurvey (struct Svy_Survey *Svy,const char *Txt);
@ -1526,6 +1524,7 @@ void Svy_RemoveSurvey (void)
void Svy_AskResetSurvey (void) void Svy_AskResetSurvey (void)
{ {
extern const char *Txt_Do_you_really_want_to_reset_the_survey_X; extern const char *Txt_Do_you_really_want_to_reset_the_survey_X;
extern const char *Txt_Reset_survey;
struct Svy_Surveys Surveys; struct Svy_Surveys Surveys;
/***** Reset surveys *****/ /***** Reset surveys *****/
@ -1545,31 +1544,17 @@ void Svy_AskResetSurvey (void)
if (!Surveys.Svy.Status.ICanEdit) if (!Surveys.Svy.Status.ICanEdit)
Err_NoPermissionExit (); Err_NoPermissionExit ();
/***** Ask for confirmation of reset *****/ /***** Show question and button to reset survey *****/
Ale_ShowAlert (Ale_WARNING,Txt_Do_you_really_want_to_reset_the_survey_X, Ale_ShowAlertAndButton (ActRstSvy,NULL,NULL,
Surveys.Svy.Title); Svy_PutParams,&Surveys,
Btn_REMOVE_BUTTON,Txt_Reset_survey,
/***** Button of confirmation of reset *****/ Ale_QUESTION,Txt_Do_you_really_want_to_reset_the_survey_X,
Svy_PutButtonToResetSurvey (&Surveys); Surveys.Svy.Title);
/***** Show surveys again *****/ /***** Show surveys again *****/
Svy_ListAllSurveys (&Surveys); Svy_ListAllSurveys (&Surveys);
} }
/*****************************************************************************/
/************************* Put button to reset survey ************************/
/*****************************************************************************/
static void Svy_PutButtonToResetSurvey (struct Svy_Surveys *Surveys)
{
extern const char *Txt_Reset_survey;
Frm_BeginForm (ActRstSvy);
Svy_PutParams (Surveys);
Btn_PutRemoveButton (Txt_Reset_survey);
Frm_EndForm ();
}
/*****************************************************************************/ /*****************************************************************************/
/******************************* Reset a survey ******************************/ /******************************* Reset a survey ******************************/
/*****************************************************************************/ /*****************************************************************************/