mirror of https://github.com/acanas/swad-core.git
Version 18.46.5
This commit is contained in:
parent
ff5db0e23c
commit
a1c44eca91
|
@ -145,7 +145,7 @@ static void Acc_ShowFormCheckIfIHaveAccount (const char *Title)
|
||||||
Hlp_PROFILE_SignUp,Box_CLOSABLE);
|
Hlp_PROFILE_SignUp,Box_CLOSABLE);
|
||||||
|
|
||||||
/***** Help alert *****/
|
/***** Help alert *****/
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_If_you_think_you_may_have_been_registered_);
|
Ale_ShowAlert (Ale_INFO,Txt_If_you_think_you_may_have_been_registered_);
|
||||||
|
|
||||||
/***** Form to request user's ID for possible account already created *****/
|
/***** Form to request user's ID for possible account already created *****/
|
||||||
Frm_StartForm (ActChkUsrAcc);
|
Frm_StartForm (ActChkUsrAcc);
|
||||||
|
@ -243,7 +243,7 @@ void Acc_CheckIfEmptyAccountExists (void)
|
||||||
Box_EndBoxTable ();
|
Box_EndBoxTable ();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_There_is_no_empty_account_associated_with_your_ID_X,
|
Ale_ShowAlert (Ale_INFO,Txt_There_is_no_empty_account_associated_with_your_ID_X,
|
||||||
ID);
|
ID);
|
||||||
|
|
||||||
/***** Free structure that stores the query result *****/
|
/***** Free structure that stores the query result *****/
|
||||||
|
@ -255,7 +255,7 @@ void Acc_CheckIfEmptyAccountExists (void)
|
||||||
else // ID not valid
|
else // ID not valid
|
||||||
{
|
{
|
||||||
/**** Show again form to check if I have an account *****/
|
/**** Show again form to check if I have an account *****/
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_Please_enter_your_ID);
|
Ale_ShowAlert (Ale_WARNING,Txt_Please_enter_your_ID);
|
||||||
|
|
||||||
Acc_ShowFormCheckIfIHaveAccount (Txt_Before_creating_a_new_account_check_if_you_have_been_already_registered);
|
Acc_ShowFormCheckIfIHaveAccount (Txt_Before_creating_a_new_account_check_if_you_have_been_already_registered);
|
||||||
}
|
}
|
||||||
|
@ -442,20 +442,17 @@ void Acc_ShowFormChgMyAccount (void)
|
||||||
/***** Check nickname, email and ID *****/
|
/***** Check nickname, email and ID *****/
|
||||||
IMustCreateMyPasswordNow = (Gbl.Usrs.Me.UsrDat.Password[0] == '\0');
|
IMustCreateMyPasswordNow = (Gbl.Usrs.Me.UsrDat.Password[0] == '\0');
|
||||||
if (IMustCreateMyPasswordNow)
|
if (IMustCreateMyPasswordNow)
|
||||||
Ale_ShowA_fmt (Ale_WARNING,
|
Ale_ShowAlert (Ale_WARNING,Txt_Before_going_to_any_other_option_you_must_create_your_password);
|
||||||
Txt_Before_going_to_any_other_option_you_must_create_your_password);
|
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
IMustCreateMyNicknameNow = (Gbl.Usrs.Me.UsrDat.Nickname[0] == '\0');
|
IMustCreateMyNicknameNow = (Gbl.Usrs.Me.UsrDat.Nickname[0] == '\0');
|
||||||
if (IMustCreateMyNicknameNow)
|
if (IMustCreateMyNicknameNow)
|
||||||
Ale_ShowA_fmt (Ale_WARNING,
|
Ale_ShowAlert (Ale_WARNING,Txt_Before_going_to_any_other_option_you_must_fill_your_nickname);
|
||||||
Txt_Before_going_to_any_other_option_you_must_fill_your_nickname);
|
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
IMustFillInMyEmailNow = (Gbl.Usrs.Me.UsrDat.Email[0] == '\0');
|
IMustFillInMyEmailNow = (Gbl.Usrs.Me.UsrDat.Email[0] == '\0');
|
||||||
if (IMustFillInMyEmailNow)
|
if (IMustFillInMyEmailNow)
|
||||||
Ale_ShowA_fmt (Ale_WARNING,
|
Ale_ShowAlert (Ale_WARNING,Txt_Before_going_to_any_other_option_you_must_fill_in_your_email_address);
|
||||||
Txt_Before_going_to_any_other_option_you_must_fill_in_your_email_address);
|
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
IShouldConfirmMyEmailNow = (!Gbl.Usrs.Me.UsrDat.EmailConfirmed && // Email not yet confirmed
|
IShouldConfirmMyEmailNow = (!Gbl.Usrs.Me.UsrDat.EmailConfirmed && // Email not yet confirmed
|
||||||
|
@ -525,10 +522,10 @@ void Acc_ShowFormChgOtherUsrAccount (void)
|
||||||
fprintf (Gbl.F.Out,"</div>");
|
fprintf (Gbl.F.Out,"</div>");
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
else // User not found
|
else // User not found
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
@ -646,14 +643,14 @@ static bool Acc_GetParamsNewAccount (char NewNicknameWithoutArroba[Nck_MAX_BYTES
|
||||||
Gbl.Usrs.Me.UsrDat.UsrCod)) // A nickname of another user is the same that this nickname
|
Gbl.Usrs.Me.UsrDat.UsrCod)) // A nickname of another user is the same that this nickname
|
||||||
{
|
{
|
||||||
Error = true;
|
Error = true;
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_nickname_X_had_been_registered_by_another_user,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_nickname_X_had_been_registered_by_another_user,
|
||||||
NewNicknameWithoutArroba);
|
NewNicknameWithoutArroba);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else // New nickname is not valid
|
else // New nickname is not valid
|
||||||
{
|
{
|
||||||
Error = true;
|
Error = true;
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_nickname_entered_X_is_not_valid_,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_nickname_entered_X_is_not_valid_,
|
||||||
NewNicknameWithArroba,
|
NewNicknameWithArroba,
|
||||||
Nck_MIN_CHARS_NICKNAME_WITHOUT_ARROBA,
|
Nck_MIN_CHARS_NICKNAME_WITHOUT_ARROBA,
|
||||||
Nck_MAX_CHARS_NICKNAME_WITHOUT_ARROBA);
|
Nck_MAX_CHARS_NICKNAME_WITHOUT_ARROBA);
|
||||||
|
@ -672,14 +669,14 @@ static bool Acc_GetParamsNewAccount (char NewNicknameWithoutArroba[Nck_MAX_BYTES
|
||||||
NewEmail)) // An email of another user is the same that my email
|
NewEmail)) // An email of another user is the same that my email
|
||||||
{
|
{
|
||||||
Error = true;
|
Error = true;
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_email_address_X_had_been_registered_by_another_user,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_email_address_X_had_been_registered_by_another_user,
|
||||||
NewEmail);
|
NewEmail);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else // New email is not valid
|
else // New email is not valid
|
||||||
{
|
{
|
||||||
Error = true;
|
Error = true;
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_email_address_entered_X_is_not_valid,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_email_address_entered_X_is_not_valid,
|
||||||
NewEmail);
|
NewEmail);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -689,7 +686,7 @@ static bool Acc_GetParamsNewAccount (char NewNicknameWithoutArroba[Nck_MAX_BYTES
|
||||||
if (!Pwd_SlowCheckIfPasswordIsGood (NewPlainPassword,NewEncryptedPassword,-1L)) // New password is good?
|
if (!Pwd_SlowCheckIfPasswordIsGood (NewPlainPassword,NewEncryptedPassword,-1L)) // New password is good?
|
||||||
{
|
{
|
||||||
Error = true;
|
Error = true;
|
||||||
Ale_ShowA_new (Ale_WARNING,Gbl.AlertToShowLater.Txt); // Error message is set in Pwd_SlowCheckIfPasswordIsGood
|
Ale_ShowDelayedAlert (); // Error message is set in Pwd_SlowCheckIfPasswordIsGood
|
||||||
}
|
}
|
||||||
|
|
||||||
return !Error;
|
return !Error;
|
||||||
|
@ -834,7 +831,7 @@ void Acc_AfterCreationNewAccount (void)
|
||||||
if (Gbl.Usrs.Me.Logged) // If account has been created without problem, I am logged
|
if (Gbl.Usrs.Me.Logged) // If account has been created without problem, I am logged
|
||||||
{
|
{
|
||||||
/***** Show message of success *****/
|
/***** Show message of success *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Congratulations_You_have_created_your_account_X_Now_Y_will_request_you_,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Congratulations_You_have_created_your_account_X_Now_Y_will_request_you_,
|
||||||
Gbl.Usrs.Me.UsrDat.Nickname,
|
Gbl.Usrs.Me.UsrDat.Nickname,
|
||||||
Cfg_PLATFORM_SHORT_NAME);
|
Cfg_PLATFORM_SHORT_NAME);
|
||||||
|
|
||||||
|
@ -863,7 +860,7 @@ void Acc_GetUsrCodAndRemUsrGbl (void)
|
||||||
Error = true;
|
Error = true;
|
||||||
|
|
||||||
if (Error)
|
if (Error)
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
@ -973,7 +970,7 @@ static void Acc_AskIfRemoveOtherUsrAccount (void)
|
||||||
Ale_ShowAlertAndButton2 (ActUnk,NULL,NULL,NULL,Btn_NO_BUTTON,NULL);
|
Ale_ShowAlertAndButton2 (ActUnk,NULL,NULL,NULL,Btn_NO_BUTTON,NULL);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
@ -1033,7 +1030,7 @@ void Acc_CompletelyEliminateAccount (struct UsrData *UsrDat,
|
||||||
UsrDat->UsrCod);
|
UsrDat->UsrCod);
|
||||||
|
|
||||||
if (QuietOrVerbose == Cns_VERBOSE)
|
if (QuietOrVerbose == Cns_VERBOSE)
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_THE_USER_X_has_been_removed_from_all_his_her_courses,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_THE_USER_X_has_been_removed_from_all_his_her_courses,
|
||||||
UsrDat->FullName);
|
UsrDat->FullName);
|
||||||
|
|
||||||
/***** Remove user as administrator of any degree *****/
|
/***** Remove user as administrator of any degree *****/
|
||||||
|
@ -1042,7 +1039,7 @@ void Acc_CompletelyEliminateAccount (struct UsrData *UsrDat,
|
||||||
UsrDat->UsrCod);
|
UsrDat->UsrCod);
|
||||||
|
|
||||||
if (QuietOrVerbose == Cns_VERBOSE)
|
if (QuietOrVerbose == Cns_VERBOSE)
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_THE_USER_X_has_been_removed_as_administrator,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_THE_USER_X_has_been_removed_as_administrator,
|
||||||
UsrDat->FullName);
|
UsrDat->FullName);
|
||||||
|
|
||||||
/***** Remove user's clipboard in forums *****/
|
/***** Remove user's clipboard in forums *****/
|
||||||
|
@ -1054,7 +1051,7 @@ void Acc_CompletelyEliminateAccount (struct UsrData *UsrDat,
|
||||||
/***** Remove the file tree of a user *****/
|
/***** Remove the file tree of a user *****/
|
||||||
Acc_RemoveUsrBriefcase (UsrDat);
|
Acc_RemoveUsrBriefcase (UsrDat);
|
||||||
if (QuietOrVerbose == Cns_VERBOSE)
|
if (QuietOrVerbose == Cns_VERBOSE)
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Briefcase_of_THE_USER_X_has_been_removed,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Briefcase_of_THE_USER_X_has_been_removed,
|
||||||
UsrDat->FullName);
|
UsrDat->FullName);
|
||||||
|
|
||||||
/***** Remove test results made by user in all courses *****/
|
/***** Remove test results made by user in all courses *****/
|
||||||
|
@ -1067,7 +1064,7 @@ void Acc_CompletelyEliminateAccount (struct UsrData *UsrDat,
|
||||||
Gbl.Msg.FilterContent[0] = '\0';
|
Gbl.Msg.FilterContent[0] = '\0';
|
||||||
Msg_DelAllRecAndSntMsgsUsr (UsrDat->UsrCod);
|
Msg_DelAllRecAndSntMsgsUsr (UsrDat->UsrCod);
|
||||||
if (QuietOrVerbose == Cns_VERBOSE)
|
if (QuietOrVerbose == Cns_VERBOSE)
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Messages_of_THE_USER_X_have_been_deleted,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Messages_of_THE_USER_X_have_been_deleted,
|
||||||
UsrDat->FullName);
|
UsrDat->FullName);
|
||||||
|
|
||||||
/***** Remove user from tables of banned users *****/
|
/***** Remove user from tables of banned users *****/
|
||||||
|
@ -1111,13 +1108,13 @@ void Acc_CompletelyEliminateAccount (struct UsrData *UsrDat,
|
||||||
/***** Remove user's photo *****/
|
/***** Remove user's photo *****/
|
||||||
PhotoRemoved = Pho_RemovePhoto (UsrDat);
|
PhotoRemoved = Pho_RemovePhoto (UsrDat);
|
||||||
if (PhotoRemoved && QuietOrVerbose == Cns_VERBOSE)
|
if (PhotoRemoved && QuietOrVerbose == Cns_VERBOSE)
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Photo_of_THE_USER_X_has_been_removed,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Photo_of_THE_USER_X_has_been_removed,
|
||||||
UsrDat->FullName);
|
UsrDat->FullName);
|
||||||
|
|
||||||
/***** Remove user *****/
|
/***** Remove user *****/
|
||||||
Acc_RemoveUsr (UsrDat);
|
Acc_RemoveUsr (UsrDat);
|
||||||
if (QuietOrVerbose == Cns_VERBOSE)
|
if (QuietOrVerbose == Cns_VERBOSE)
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Record_card_of_THE_USER_X_has_been_removed,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Record_card_of_THE_USER_X_has_been_removed,
|
||||||
UsrDat->FullName);
|
UsrDat->FullName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -371,7 +371,7 @@ void Agd_ShowUsrAgenda (void)
|
||||||
}
|
}
|
||||||
|
|
||||||
if (Error)
|
if (Error)
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
@ -415,12 +415,12 @@ void Agd_ShowOtherAgendaAfterLogIn (void)
|
||||||
Box_EndBox ();
|
Box_EndBox ();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
/* The current language is not my preferred language
|
/* The current language is not my preferred language
|
||||||
==> change automatically to my language */
|
==> change automatically to my language */
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_Switching_to_LANGUAGE[Gbl.Usrs.Me.UsrDat.Prefs.Language]);
|
Ale_ShowAlert (Ale_INFO,Txt_Switching_to_LANGUAGE[Gbl.Usrs.Me.UsrDat.Prefs.Language]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -480,7 +480,7 @@ static void Agd_ShowEvents (Agd_AgendaType_t AgendaType)
|
||||||
Tbl_EndTable ();
|
Tbl_EndTable ();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_No_events);
|
Ale_ShowAlert (Ale_INFO,Txt_No_events);
|
||||||
|
|
||||||
/***** Write again links to pages *****/
|
/***** Write again links to pages *****/
|
||||||
if (Pagination.MoreThanOnePage)
|
if (Pagination.MoreThanOnePage)
|
||||||
|
@ -1311,7 +1311,7 @@ void Agd_RemoveEvent (void)
|
||||||
AgdEvent.AgdCod,AgdEvent.UsrCod);
|
AgdEvent.AgdCod,AgdEvent.UsrCod);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Event_X_removed,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Event_X_removed,
|
||||||
AgdEvent.Event);
|
AgdEvent.Event);
|
||||||
|
|
||||||
/***** Show events again *****/
|
/***** Show events again *****/
|
||||||
|
@ -1342,7 +1342,7 @@ void Agd_HideEvent (void)
|
||||||
AgdEvent.AgdCod,AgdEvent.UsrCod);
|
AgdEvent.AgdCod,AgdEvent.UsrCod);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Event_X_is_now_hidden,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Event_X_is_now_hidden,
|
||||||
AgdEvent.Event);
|
AgdEvent.Event);
|
||||||
|
|
||||||
/***** Show events again *****/
|
/***** Show events again *****/
|
||||||
|
@ -1373,7 +1373,7 @@ void Agd_UnhideEvent (void)
|
||||||
AgdEvent.AgdCod,AgdEvent.UsrCod);
|
AgdEvent.AgdCod,AgdEvent.UsrCod);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Event_X_is_now_visible,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Event_X_is_now_visible,
|
||||||
AgdEvent.Event);
|
AgdEvent.Event);
|
||||||
|
|
||||||
/***** Show events again *****/
|
/***** Show events again *****/
|
||||||
|
@ -1404,7 +1404,7 @@ void Agd_MakeEventPrivate (void)
|
||||||
AgdEvent.AgdCod,AgdEvent.UsrCod);
|
AgdEvent.AgdCod,AgdEvent.UsrCod);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Event_X_is_now_private,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Event_X_is_now_private,
|
||||||
AgdEvent.Event);
|
AgdEvent.Event);
|
||||||
|
|
||||||
/***** Show events again *****/
|
/***** Show events again *****/
|
||||||
|
@ -1435,7 +1435,7 @@ void Agd_MakeEventPublic (void)
|
||||||
AgdEvent.AgdCod,AgdEvent.UsrCod);
|
AgdEvent.AgdCod,AgdEvent.UsrCod);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Event_X_is_now_visible_to_users_of_your_courses,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Event_X_is_now_visible_to_users_of_your_courses,
|
||||||
AgdEvent.Event);
|
AgdEvent.Event);
|
||||||
|
|
||||||
/***** Show events again *****/
|
/***** Show events again *****/
|
||||||
|
@ -1616,14 +1616,14 @@ void Agd_RecFormEvent (void)
|
||||||
if (!AgdEvent.Location[0]) // If there is no event
|
if (!AgdEvent.Location[0]) // If there is no event
|
||||||
{
|
{
|
||||||
NewEventIsCorrect = false;
|
NewEventIsCorrect = false;
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_must_specify_the_title_of_the_event);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_must_specify_the_title_of_the_event);
|
||||||
}
|
}
|
||||||
|
|
||||||
/***** Check if event is correct *****/
|
/***** Check if event is correct *****/
|
||||||
if (!AgdEvent.Event[0]) // If there is no event
|
if (!AgdEvent.Event[0]) // If there is no event
|
||||||
{
|
{
|
||||||
NewEventIsCorrect = false;
|
NewEventIsCorrect = false;
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_must_specify_the_title_of_the_event);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_must_specify_the_title_of_the_event);
|
||||||
}
|
}
|
||||||
|
|
||||||
/***** Create a new event or update an existing one *****/
|
/***** Create a new event or update an existing one *****/
|
||||||
|
@ -1634,7 +1634,7 @@ void Agd_RecFormEvent (void)
|
||||||
Agd_CreateEvent (&AgdEvent,EventTxt); // Add new event to database
|
Agd_CreateEvent (&AgdEvent,EventTxt); // Add new event to database
|
||||||
|
|
||||||
/***** Write success message *****/
|
/***** Write success message *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Created_new_event_X,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Created_new_event_X,
|
||||||
AgdEvent.Event);
|
AgdEvent.Event);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -1642,7 +1642,7 @@ void Agd_RecFormEvent (void)
|
||||||
Agd_UpdateEvent (&AgdEvent,EventTxt);
|
Agd_UpdateEvent (&AgdEvent,EventTxt);
|
||||||
|
|
||||||
/***** Write success message *****/
|
/***** Write success message *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_event_has_been_modified);
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_event_has_been_modified);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Free memory for list of selected groups */
|
/* Free memory for list of selected groups */
|
||||||
|
|
20
swad_alert.c
20
swad_alert.c
|
@ -68,6 +68,8 @@ static const char *Ale_AlertIcons[Ale_NUM_ALERT_TYPES] =
|
||||||
/***************************** Private prototypes ****************************/
|
/***************************** Private prototypes ****************************/
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
||||||
|
static void Ale_ShowFixAlert (Ale_AlertType_t AlertType,const char *Txt);
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
/******************************** Reset alert ********************************/
|
/******************************** Reset alert ********************************/
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
@ -99,8 +101,13 @@ void Ale_ShowPendingAlert (void)
|
||||||
/******************** Show an alert message to the user **********************/
|
/******************** Show an alert message to the user **********************/
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
||||||
void Ale_ShowA_fmt (Ale_AlertType_t AlertType,
|
void Ale_ShowDelayedAlert (void)
|
||||||
const char *fmt,...)
|
{
|
||||||
|
if (Gbl.DelayedAlert.Type != Ale_NONE)
|
||||||
|
Ale_ShowFixAlert (Gbl.DelayedAlert.Type,Gbl.DelayedAlert.Txt);
|
||||||
|
}
|
||||||
|
|
||||||
|
void Ale_ShowAlert (Ale_AlertType_t AlertType,const char *fmt,...)
|
||||||
{
|
{
|
||||||
va_list ap;
|
va_list ap;
|
||||||
int NumBytesPrinted;
|
int NumBytesPrinted;
|
||||||
|
@ -113,18 +120,17 @@ void Ale_ShowA_fmt (Ale_AlertType_t AlertType,
|
||||||
va_end (ap);
|
va_end (ap);
|
||||||
|
|
||||||
if (NumBytesPrinted < 0) // If memory allocation wasn't possible,
|
if (NumBytesPrinted < 0) // If memory allocation wasn't possible,
|
||||||
// or some other error occurs,
|
// or some other error occurs,
|
||||||
// vasprintf will return -1
|
// vasprintf will return -1
|
||||||
Lay_NotEnoughMemoryExit ();
|
Lay_NotEnoughMemoryExit ();
|
||||||
|
|
||||||
Ale_ShowAlertAndButton (AlertType,Txt,
|
Ale_ShowAlert (AlertType,Txt);
|
||||||
ActUnk,NULL,NULL,NULL,Btn_NO_BUTTON,NULL);
|
|
||||||
|
|
||||||
free ((void *) Txt);
|
free ((void *) Txt);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void Ale_ShowA_new (Ale_AlertType_t AlertType,const char *Txt)
|
static void Ale_ShowFixAlert (Ale_AlertType_t AlertType,const char *Txt)
|
||||||
{
|
{
|
||||||
if (AlertType != Ale_NONE)
|
if (AlertType != Ale_NONE)
|
||||||
Ale_ShowAlertAndButton (AlertType,Txt,
|
Ale_ShowAlertAndButton (AlertType,Txt,
|
||||||
|
|
|
@ -61,9 +61,8 @@ typedef enum
|
||||||
void Ale_ResetAlert (void);
|
void Ale_ResetAlert (void);
|
||||||
|
|
||||||
void Ale_ShowPendingAlert (void);
|
void Ale_ShowPendingAlert (void);
|
||||||
void Ale_ShowA_fmt (Ale_AlertType_t AlertType,
|
void Ale_ShowDelayedAlert (void);
|
||||||
const char *fmt,...);
|
void Ale_ShowAlert (Ale_AlertType_t AlertType,const char *fmt,...);
|
||||||
void Ale_ShowA_new (Ale_AlertType_t AlertType,const char *Txt);
|
|
||||||
void Ale_ShowA_old (Ale_AlertType_t AlertType,const char *Txt);
|
void Ale_ShowA_old (Ale_AlertType_t AlertType,const char *Txt);
|
||||||
void Ale_ShowAlertAndButton (Ale_AlertType_t AlertType,const char *Txt,
|
void Ale_ShowAlertAndButton (Ale_AlertType_t AlertType,const char *Txt,
|
||||||
Act_Action_t NextAction,const char *Anchor,const char *OnSubmit,
|
Act_Action_t NextAction,const char *Anchor,const char *OnSubmit,
|
||||||
|
|
|
@ -131,7 +131,7 @@ void Ann_ShowAllAnnouncements (void)
|
||||||
NULL,
|
NULL,
|
||||||
Hlp_MESSAGES_Announcements,Box_NOT_CLOSABLE);
|
Hlp_MESSAGES_Announcements,Box_NOT_CLOSABLE);
|
||||||
if (!NumAnnouncements)
|
if (!NumAnnouncements)
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_No_announcements);
|
Ale_ShowAlert (Ale_INFO,Txt_No_announcements);
|
||||||
|
|
||||||
/***** Show the announcements *****/
|
/***** Show the announcements *****/
|
||||||
for (NumAnn = 0;
|
for (NumAnn = 0;
|
||||||
|
@ -495,7 +495,7 @@ void Ann_ReceiveAnnouncement (void)
|
||||||
Ann_CreateAnnouncement (Roles,Subject,Content);
|
Ann_CreateAnnouncement (Roles,Subject,Content);
|
||||||
|
|
||||||
/***** Write message of success *****/
|
/***** Write message of success *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Announcement_created);
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Announcement_created);
|
||||||
|
|
||||||
/***** Refresh list of announcements *****/
|
/***** Refresh list of announcements *****/
|
||||||
Ann_ShowAllAnnouncements ();
|
Ann_ShowAllAnnouncements ();
|
||||||
|
@ -575,7 +575,7 @@ void Ann_RemoveAnnouncement (void)
|
||||||
AnnCod);
|
AnnCod);
|
||||||
|
|
||||||
/***** Write message of success *****/
|
/***** Write message of success *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Announcement_removed);
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Announcement_removed);
|
||||||
|
|
||||||
/***** Refresh list of announcements *****/
|
/***** Refresh list of announcements *****/
|
||||||
Ann_ShowAllAnnouncements ();
|
Ann_ShowAllAnnouncements ();
|
||||||
|
|
|
@ -167,7 +167,7 @@ static void Asg_ShowAllAssignments (void)
|
||||||
Tbl_EndTable ();
|
Tbl_EndTable ();
|
||||||
}
|
}
|
||||||
else // No assignments created
|
else // No assignments created
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_No_assignments);
|
Ale_ShowAlert (Ale_INFO,Txt_No_assignments);
|
||||||
|
|
||||||
/***** Button to create a new assignment *****/
|
/***** Button to create a new assignment *****/
|
||||||
if (Asg_CheckIfICanCreateAssignments ())
|
if (Asg_CheckIfICanCreateAssignments ())
|
||||||
|
@ -989,7 +989,7 @@ void Asg_RemoveAssignment (void)
|
||||||
Ntf_MarkNotifAsRemoved (Ntf_EVENT_ASSIGNMENT,Asg.AsgCod);
|
Ntf_MarkNotifAsRemoved (Ntf_EVENT_ASSIGNMENT,Asg.AsgCod);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Assignment_X_removed,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Assignment_X_removed,
|
||||||
Asg.Title);
|
Asg.Title);
|
||||||
|
|
||||||
/***** Show assignments again *****/
|
/***** Show assignments again *****/
|
||||||
|
@ -1019,7 +1019,7 @@ void Asg_HideAssignment (void)
|
||||||
Asg.AsgCod,Gbl.CurrentCrs.Crs.CrsCod);
|
Asg.AsgCod,Gbl.CurrentCrs.Crs.CrsCod);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Assignment_X_is_now_hidden,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Assignment_X_is_now_hidden,
|
||||||
Asg.Title);
|
Asg.Title);
|
||||||
|
|
||||||
/***** Show assignments again *****/
|
/***** Show assignments again *****/
|
||||||
|
@ -1049,7 +1049,7 @@ void Asg_ShowAssignment (void)
|
||||||
Asg.AsgCod,Gbl.CurrentCrs.Crs.CrsCod);
|
Asg.AsgCod,Gbl.CurrentCrs.Crs.CrsCod);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Assignment_X_is_now_visible,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Assignment_X_is_now_visible,
|
||||||
Asg.Title);
|
Asg.Title);
|
||||||
|
|
||||||
/***** Show assignments again *****/
|
/***** Show assignments again *****/
|
||||||
|
@ -1337,7 +1337,7 @@ void Asg_RecFormAssignment (void)
|
||||||
{
|
{
|
||||||
NewAssignmentIsCorrect = false;
|
NewAssignmentIsCorrect = false;
|
||||||
|
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_Already_existed_an_assignment_with_the_title_X,
|
Ale_ShowAlert (Ale_WARNING,Txt_Already_existed_an_assignment_with_the_title_X,
|
||||||
NewAsg.Title);
|
NewAsg.Title);
|
||||||
}
|
}
|
||||||
else // Title is correct
|
else // Title is correct
|
||||||
|
@ -1350,14 +1350,14 @@ void Asg_RecFormAssignment (void)
|
||||||
{
|
{
|
||||||
NewAssignmentIsCorrect = false;
|
NewAssignmentIsCorrect = false;
|
||||||
|
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_Already_existed_an_assignment_with_the_folder_X,
|
Ale_ShowAlert (Ale_WARNING,Txt_Already_existed_an_assignment_with_the_folder_X,
|
||||||
NewAsg.Folder);
|
NewAsg.Folder);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else // Folder name not valid
|
else // Folder name not valid
|
||||||
{
|
{
|
||||||
NewAssignmentIsCorrect = false;
|
NewAssignmentIsCorrect = false;
|
||||||
Ale_ShowA_new (Ale_WARNING,Gbl.AlertToShowLater.Txt);
|
Ale_ShowDelayedAlert (Ale_WARNING,Gbl.DelayedAlert.Txt);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else // NewAsg.SendWork == Asg_DO_NOT_SEND_WORK
|
else // NewAsg.SendWork == Asg_DO_NOT_SEND_WORK
|
||||||
|
@ -1367,7 +1367,7 @@ void Asg_RecFormAssignment (void)
|
||||||
if (Brw_CheckIfExistsFolderAssigmentForAnyUsr (OldAsg.Folder))
|
if (Brw_CheckIfExistsFolderAssigmentForAnyUsr (OldAsg.Folder))
|
||||||
{
|
{
|
||||||
NewAssignmentIsCorrect = false;
|
NewAssignmentIsCorrect = false;
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_can_not_disable_file_uploading_once_folders_have_been_created);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_can_not_disable_file_uploading_once_folders_have_been_created);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1376,7 +1376,7 @@ void Asg_RecFormAssignment (void)
|
||||||
else // If there is not an assignment title
|
else // If there is not an assignment title
|
||||||
{
|
{
|
||||||
NewAssignmentIsCorrect = false;
|
NewAssignmentIsCorrect = false;
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_must_specify_the_title_of_the_assignment);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_must_specify_the_title_of_the_assignment);
|
||||||
}
|
}
|
||||||
|
|
||||||
/***** Create a new assignment or update an existing one *****/
|
/***** Create a new assignment or update an existing one *****/
|
||||||
|
@ -1390,7 +1390,7 @@ void Asg_RecFormAssignment (void)
|
||||||
Asg_CreateAssignment (&NewAsg,Description); // Add new assignment to database
|
Asg_CreateAssignment (&NewAsg,Description); // Add new assignment to database
|
||||||
|
|
||||||
/***** Write success message *****/
|
/***** Write success message *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Created_new_assignment_X,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Created_new_assignment_X,
|
||||||
NewAsg.Title);
|
NewAsg.Title);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -1403,7 +1403,7 @@ void Asg_RecFormAssignment (void)
|
||||||
Asg_UpdateAssignment (&NewAsg,Description);
|
Asg_UpdateAssignment (&NewAsg,Description);
|
||||||
|
|
||||||
/***** Write success message *****/
|
/***** Write success message *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_assignment_has_been_modified);
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_assignment_has_been_modified);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -276,7 +276,7 @@ static void Att_ShowAllAttEvents (void)
|
||||||
Tbl_EndTable ();
|
Tbl_EndTable ();
|
||||||
}
|
}
|
||||||
else // No events created
|
else // No events created
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_No_events);
|
Ale_ShowAlert (Ale_INFO,Txt_No_events);
|
||||||
|
|
||||||
/***** Button to create a new attendance event *****/
|
/***** Button to create a new attendance event *****/
|
||||||
if (ICanEdit)
|
if (ICanEdit)
|
||||||
|
@ -897,7 +897,7 @@ void Att_AskRemAttEvent (void)
|
||||||
Pag_PutHiddenParamPagNum (Pag_ATT_EVENTS,Gbl.AttEvents.CurrentPage);
|
Pag_PutHiddenParamPagNum (Pag_ATT_EVENTS,Gbl.AttEvents.CurrentPage);
|
||||||
|
|
||||||
/* Ask for confirmation of removing */
|
/* Ask for confirmation of removing */
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_Do_you_really_want_to_remove_the_event_X,
|
Ale_ShowAlert (Ale_WARNING,Txt_Do_you_really_want_to_remove_the_event_X,
|
||||||
Att.Title);
|
Att.Title);
|
||||||
|
|
||||||
Btn_PutRemoveButton (Txt_Remove_event);
|
Btn_PutRemoveButton (Txt_Remove_event);
|
||||||
|
@ -928,7 +928,7 @@ void Att_GetAndRemAttEvent (void)
|
||||||
Att_RemoveAttEventFromDB (Att.AttCod);
|
Att_RemoveAttEventFromDB (Att.AttCod);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Event_X_removed,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Event_X_removed,
|
||||||
Att.Title);
|
Att.Title);
|
||||||
|
|
||||||
/***** Show attendance events again *****/
|
/***** Show attendance events again *****/
|
||||||
|
@ -974,7 +974,7 @@ void Att_HideAttEvent (void)
|
||||||
Att.AttCod,Gbl.CurrentCrs.Crs.CrsCod);
|
Att.AttCod,Gbl.CurrentCrs.Crs.CrsCod);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Event_X_is_now_hidden,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Event_X_is_now_hidden,
|
||||||
Att.Title);
|
Att.Title);
|
||||||
|
|
||||||
/***** Show attendance events again *****/
|
/***** Show attendance events again *****/
|
||||||
|
@ -1004,7 +1004,7 @@ void Att_ShowAttEvent (void)
|
||||||
Att.AttCod,Gbl.CurrentCrs.Crs.CrsCod);
|
Att.AttCod,Gbl.CurrentCrs.Crs.CrsCod);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Event_X_is_now_visible,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Event_X_is_now_visible,
|
||||||
Att.Title);
|
Att.Title);
|
||||||
|
|
||||||
/***** Show attendance events again *****/
|
/***** Show attendance events again *****/
|
||||||
|
@ -1290,14 +1290,14 @@ void Att_RecFormAttEvent (void)
|
||||||
{
|
{
|
||||||
ReceivedAttEventIsCorrect = false;
|
ReceivedAttEventIsCorrect = false;
|
||||||
|
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_Already_existed_an_event_with_the_title_X,
|
Ale_ShowAlert (Ale_WARNING,Txt_Already_existed_an_event_with_the_title_X,
|
||||||
ReceivedAtt.Title);
|
ReceivedAtt.Title);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else // If there is not an attendance event title
|
else // If there is not an attendance event title
|
||||||
{
|
{
|
||||||
ReceivedAttEventIsCorrect = false;
|
ReceivedAttEventIsCorrect = false;
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_must_specify_the_title_of_the_event);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_must_specify_the_title_of_the_event);
|
||||||
}
|
}
|
||||||
|
|
||||||
/***** Create a new attendance event or update an existing one *****/
|
/***** Create a new attendance event or update an existing one *****/
|
||||||
|
@ -1312,7 +1312,7 @@ void Att_RecFormAttEvent (void)
|
||||||
Att_CreateAttEvent (&ReceivedAtt,Description); // Add new attendance event to database
|
Att_CreateAttEvent (&ReceivedAtt,Description); // Add new attendance event to database
|
||||||
|
|
||||||
/***** Write success message *****/
|
/***** Write success message *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Created_new_event_X,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Created_new_event_X,
|
||||||
ReceivedAtt.Title);
|
ReceivedAtt.Title);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -1320,7 +1320,7 @@ void Att_RecFormAttEvent (void)
|
||||||
Att_UpdateAttEvent (&ReceivedAtt,Description);
|
Att_UpdateAttEvent (&ReceivedAtt,Description);
|
||||||
|
|
||||||
/***** Write success message *****/
|
/***** Write success message *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_event_has_been_modified);
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_event_has_been_modified);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Free memory for list of selected groups */
|
/* Free memory for list of selected groups */
|
||||||
|
@ -2282,7 +2282,7 @@ void Att_RegisterMeAsStdInAttEvent (void)
|
||||||
Att_RemoveUsrFromAttEvent (Att.AttCod,Gbl.Usrs.Me.UsrDat.UsrCod);
|
Att_RemoveUsrFromAttEvent (Att.AttCod,Gbl.Usrs.Me.UsrDat.UsrCod);
|
||||||
|
|
||||||
/***** Write final message *****/
|
/***** Write final message *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Your_comment_has_been_updated);
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Your_comment_has_been_updated);
|
||||||
}
|
}
|
||||||
|
|
||||||
/***** Show the attendance event again *****/
|
/***** Show the attendance event again *****/
|
||||||
|
@ -2407,7 +2407,7 @@ void Att_RegisterStudentsInAttEvent (void)
|
||||||
Usr_FreeUsrsList (Rol_STD);
|
Usr_FreeUsrsList (Rol_STD);
|
||||||
|
|
||||||
/***** Write final message *****/
|
/***** Write final message *****/
|
||||||
Ale_ShowA_fmt (Ale_INFO,"%s: %u<br />"
|
Ale_ShowAlert (Ale_INFO,"%s: %u<br />"
|
||||||
"%s: %u",
|
"%s: %u",
|
||||||
Txt_Presents,NumStdsPresent,
|
Txt_Presents,NumStdsPresent,
|
||||||
Txt_Absents ,NumStdsAbsent );
|
Txt_Absents ,NumStdsAbsent );
|
||||||
|
@ -2916,7 +2916,7 @@ static void Usr_ListOrPrintStdsAttendanceCrs (Att_TypeOfView_t TypeOfView)
|
||||||
}
|
}
|
||||||
else // No students selected
|
else // No students selected
|
||||||
{
|
{
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_must_select_one_ore_more_students);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_must_select_one_ore_more_students);
|
||||||
Usr_ReqListStdsAttendanceCrs (); // ...show again the form
|
Usr_ReqListStdsAttendanceCrs (); // ...show again the form
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -111,7 +111,7 @@ void Ban_SeeBanners (void)
|
||||||
if (Gbl.Banners.Num) // There are banners
|
if (Gbl.Banners.Num) // There are banners
|
||||||
Ban_WriteListOfBanners ();
|
Ban_WriteListOfBanners ();
|
||||||
else // No banners created
|
else // No banners created
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_No_banners);
|
Ale_ShowAlert (Ale_INFO,Txt_No_banners);
|
||||||
|
|
||||||
/***** Button to create banner *****/
|
/***** Button to create banner *****/
|
||||||
if (Gbl.Usrs.Me.Role.Logged == Rol_SYS_ADM)
|
if (Gbl.Usrs.Me.Role.Logged == Rol_SYS_ADM)
|
||||||
|
@ -521,7 +521,7 @@ void Ban_RemoveBanner (void)
|
||||||
Ban.BanCod);
|
Ban.BanCod);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Banner_X_removed,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Banner_X_removed,
|
||||||
Ban.ShrtName);
|
Ban.ShrtName);
|
||||||
|
|
||||||
/***** Show the form again *****/
|
/***** Show the form again *****/
|
||||||
|
@ -575,7 +575,7 @@ static void Ban_ShowOrHideBanner (bool Hide)
|
||||||
Ban.BanCod);
|
Ban.BanCod);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Hide ? Txt_The_banner_X_is_now_hidden :
|
Ale_ShowAlert (Ale_SUCCESS,Hide ? Txt_The_banner_X_is_now_hidden :
|
||||||
Txt_The_banner_X_is_now_visible,
|
Txt_The_banner_X_is_now_visible,
|
||||||
Ban.ShrtName);
|
Ban.ShrtName);
|
||||||
|
|
||||||
|
@ -648,7 +648,7 @@ static void Ban_RenameBanner (Cns_ShrtOrFullName_t ShrtOrFullName)
|
||||||
|
|
||||||
/***** Check if new name is empty *****/
|
/***** Check if new name is empty *****/
|
||||||
if (!NewBanName[0])
|
if (!NewBanName[0])
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_can_not_leave_the_name_of_the_banner_X_empty,
|
Ale_ShowAlert (Ale_WARNING,Txt_You_can_not_leave_the_name_of_the_banner_X_empty,
|
||||||
CurrentBanName);
|
CurrentBanName);
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -658,7 +658,7 @@ static void Ban_RenameBanner (Cns_ShrtOrFullName_t ShrtOrFullName)
|
||||||
{
|
{
|
||||||
/***** If banner was in database... *****/
|
/***** If banner was in database... *****/
|
||||||
if (Ban_CheckIfBannerNameExists (ParamName,NewBanName,Ban->BanCod))
|
if (Ban_CheckIfBannerNameExists (ParamName,NewBanName,Ban->BanCod))
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_banner_X_already_exists,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_banner_X_already_exists,
|
||||||
NewBanName);
|
NewBanName);
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -666,12 +666,12 @@ static void Ban_RenameBanner (Cns_ShrtOrFullName_t ShrtOrFullName)
|
||||||
Ban_UpdateBanNameDB (Ban->BanCod,FieldName,NewBanName);
|
Ban_UpdateBanNameDB (Ban->BanCod,FieldName,NewBanName);
|
||||||
|
|
||||||
/* Write message to show the change made */
|
/* Write message to show the change made */
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_banner_X_has_been_renamed_as_Y,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_banner_X_has_been_renamed_as_Y,
|
||||||
CurrentBanName,NewBanName);
|
CurrentBanName,NewBanName);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else // The same name
|
else // The same name
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_The_name_of_the_banner_X_has_not_changed,
|
Ale_ShowAlert (Ale_INFO,Txt_The_name_of_the_banner_X_has_not_changed,
|
||||||
CurrentBanName);
|
CurrentBanName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -739,11 +739,11 @@ void Ban_ChangeBannerImg (void)
|
||||||
NewImg,Ban->BanCod);
|
NewImg,Ban->BanCod);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_new_image_is_X,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_new_image_is_X,
|
||||||
NewImg);
|
NewImg);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_can_not_leave_the_image_empty);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_can_not_leave_the_image_empty);
|
||||||
|
|
||||||
/***** Show the form again *****/
|
/***** Show the form again *****/
|
||||||
Str_Copy (Ban->Img,NewImg,
|
Str_Copy (Ban->Img,NewImg,
|
||||||
|
@ -782,11 +782,11 @@ void Ban_ChangeBannerWWW (void)
|
||||||
NewWWW,Ban->BanCod);
|
NewWWW,Ban->BanCod);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_new_web_address_is_X,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_new_web_address_is_X,
|
||||||
NewWWW);
|
NewWWW);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_can_not_leave_the_web_address_empty);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_can_not_leave_the_web_address_empty);
|
||||||
|
|
||||||
/***** Show the form again *****/
|
/***** Show the form again *****/
|
||||||
Str_Copy (Ban->WWW,NewWWW,
|
Str_Copy (Ban->WWW,NewWWW,
|
||||||
|
@ -926,20 +926,20 @@ void Ban_RecFormNewBanner (void)
|
||||||
{
|
{
|
||||||
/***** If name of banner was in database... *****/
|
/***** If name of banner was in database... *****/
|
||||||
if (Ban_CheckIfBannerNameExists ("ShortName",Ban->ShrtName,-1L))
|
if (Ban_CheckIfBannerNameExists ("ShortName",Ban->ShrtName,-1L))
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_banner_X_already_exists,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_banner_X_already_exists,
|
||||||
Ban->ShrtName);
|
Ban->ShrtName);
|
||||||
else if (Ban_CheckIfBannerNameExists ("FullName",Ban->FullName,-1L))
|
else if (Ban_CheckIfBannerNameExists ("FullName",Ban->FullName,-1L))
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_banner_X_already_exists,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_banner_X_already_exists,
|
||||||
Ban->FullName);
|
Ban->FullName);
|
||||||
else if (!Ban->Img[0])
|
else if (!Ban->Img[0])
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_must_specify_the_image_of_the_new_banner);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_must_specify_the_image_of_the_new_banner);
|
||||||
else if (!Ban->WWW[0])
|
else if (!Ban->WWW[0])
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_must_specify_the_URL_of_the_new_banner);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_must_specify_the_URL_of_the_new_banner);
|
||||||
else // Add new banner to database
|
else // Add new banner to database
|
||||||
Ban_CreateBanner (Ban);
|
Ban_CreateBanner (Ban);
|
||||||
}
|
}
|
||||||
else // If there is not a banner name
|
else // If there is not a banner name
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_must_specify_the_short_name_and_the_full_name_of_the_new_banner);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_must_specify_the_short_name_and_the_full_name_of_the_new_banner);
|
||||||
|
|
||||||
/***** Show the form again *****/
|
/***** Show the form again *****/
|
||||||
Ban_EditBanners ();
|
Ban_EditBanners ();
|
||||||
|
@ -962,7 +962,7 @@ static void Ban_CreateBanner (struct Banner *Ban)
|
||||||
Ban->ShrtName,Ban->FullName,Ban->Img,Ban->WWW);
|
Ban->ShrtName,Ban->FullName,Ban->Img,Ban->WWW);
|
||||||
|
|
||||||
/***** Write success message *****/
|
/***** Write success message *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Created_new_banner_X,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Created_new_banner_X,
|
||||||
Ban->ShrtName);
|
Ban->ShrtName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -225,7 +225,7 @@ void Ctr_SeeCtrWithPendingDegs (void)
|
||||||
Box_EndBoxTable ();
|
Box_EndBoxTable ();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_There_are_no_centres_with_requests_for_degrees_to_be_confirmed);
|
Ale_ShowAlert (Ale_INFO,Txt_There_are_no_centres_with_requests_for_degrees_to_be_confirmed);
|
||||||
|
|
||||||
/***** Free structure that stores the query result *****/
|
/***** Free structure that stores the query result *****/
|
||||||
DB_FreeMySQLResult (&mysql_res);
|
DB_FreeMySQLResult (&mysql_res);
|
||||||
|
@ -816,7 +816,7 @@ static void Ctr_ListCentres (void)
|
||||||
Tbl_EndTable ();
|
Tbl_EndTable ();
|
||||||
}
|
}
|
||||||
else // No centres created in the current institution
|
else // No centres created in the current institution
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_No_centres);
|
Ale_ShowAlert (Ale_INFO,Txt_No_centres);
|
||||||
|
|
||||||
/***** Button to create centre *****/
|
/***** Button to create centre *****/
|
||||||
if (Ctr_CheckIfICanCreateCentres ())
|
if (Ctr_CheckIfICanCreateCentres ())
|
||||||
|
@ -1766,7 +1766,7 @@ void Ctr_RemoveCentre (void)
|
||||||
if (Ctr.Degs.Num ||
|
if (Ctr.Degs.Num ||
|
||||||
Ctr.NumUsrsWhoClaimToBelongToCtr ||
|
Ctr.NumUsrsWhoClaimToBelongToCtr ||
|
||||||
Ctr.NumUsrs) // Centre has degrees or users ==> don't remove
|
Ctr.NumUsrs) // Centre has degrees or users ==> don't remove
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_To_remove_a_centre_you_must_first_remove_all_degrees_and_teachers_in_the_centre);
|
Ale_ShowAlert (Ale_WARNING,Txt_To_remove_a_centre_you_must_first_remove_all_degrees_and_teachers_in_the_centre);
|
||||||
else // Centre has no teachers ==> remove it
|
else // Centre has no teachers ==> remove it
|
||||||
{
|
{
|
||||||
/***** Remove all the threads and posts in forums of the centre *****/
|
/***** Remove all the threads and posts in forums of the centre *****/
|
||||||
|
@ -1795,7 +1795,7 @@ void Ctr_RemoveCentre (void)
|
||||||
Ctr.CtrCod);
|
Ctr.CtrCod);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Centre_X_removed,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Centre_X_removed,
|
||||||
Ctr.FullName);
|
Ctr.FullName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1828,8 +1828,8 @@ void Ctr_ChangeCtrInsInConfig (void)
|
||||||
Gbl.CurrentCtr.Ctr.CtrCod,
|
Gbl.CurrentCtr.Ctr.CtrCod,
|
||||||
NewIns.InsCod))
|
NewIns.InsCod))
|
||||||
{
|
{
|
||||||
Gbl.AlertToShowLater.Type = Ale_WARNING;
|
Gbl.DelayedAlert.Type = Ale_WARNING;
|
||||||
snprintf (Gbl.AlertToShowLater.Txt,sizeof (Gbl.AlertToShowLater.Txt),
|
snprintf (Gbl.DelayedAlert.Txt,sizeof (Gbl.DelayedAlert.Txt),
|
||||||
Txt_The_centre_X_already_exists,
|
Txt_The_centre_X_already_exists,
|
||||||
Gbl.CurrentCtr.Ctr.ShrtName);
|
Gbl.CurrentCtr.Ctr.ShrtName);
|
||||||
}
|
}
|
||||||
|
@ -1838,8 +1838,8 @@ void Ctr_ChangeCtrInsInConfig (void)
|
||||||
Gbl.CurrentCtr.Ctr.CtrCod,
|
Gbl.CurrentCtr.Ctr.CtrCod,
|
||||||
NewIns.InsCod))
|
NewIns.InsCod))
|
||||||
{
|
{
|
||||||
Gbl.AlertToShowLater.Type = Ale_WARNING;
|
Gbl.DelayedAlert.Type = Ale_WARNING;
|
||||||
snprintf (Gbl.AlertToShowLater.Txt,sizeof (Gbl.AlertToShowLater.Txt),
|
snprintf (Gbl.DelayedAlert.Txt,sizeof (Gbl.DelayedAlert.Txt),
|
||||||
Txt_The_centre_X_already_exists,
|
Txt_The_centre_X_already_exists,
|
||||||
Gbl.CurrentCtr.Ctr.FullName);
|
Gbl.CurrentCtr.Ctr.FullName);
|
||||||
}
|
}
|
||||||
|
@ -1854,8 +1854,8 @@ void Ctr_ChangeCtrInsInConfig (void)
|
||||||
Hie_InitHierarchy ();
|
Hie_InitHierarchy ();
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Gbl.AlertToShowLater.Type = Ale_SUCCESS;
|
Gbl.DelayedAlert.Type = Ale_SUCCESS;
|
||||||
snprintf (Gbl.AlertToShowLater.Txt,sizeof (Gbl.AlertToShowLater.Txt),
|
snprintf (Gbl.DelayedAlert.Txt,sizeof (Gbl.DelayedAlert.Txt),
|
||||||
Txt_The_centre_X_has_been_moved_to_the_institution_Y,
|
Txt_The_centre_X_has_been_moved_to_the_institution_Y,
|
||||||
Gbl.CurrentCtr.Ctr.FullName,NewIns.FullName);
|
Gbl.CurrentCtr.Ctr.FullName,NewIns.FullName);
|
||||||
}
|
}
|
||||||
|
@ -1911,8 +1911,8 @@ void Ctr_ChangeCtrPlc (void)
|
||||||
|
|
||||||
/***** Write message to show the change made
|
/***** Write message to show the change made
|
||||||
and put button to go to centre changed *****/
|
and put button to go to centre changed *****/
|
||||||
Gbl.AlertToShowLater.Type = Ale_SUCCESS;
|
Gbl.DelayedAlert.Type = Ale_SUCCESS;
|
||||||
Str_Copy (Gbl.AlertToShowLater.Txt,Txt_The_place_of_the_centre_has_changed,
|
Str_Copy (Gbl.DelayedAlert.Txt,Txt_The_place_of_the_centre_has_changed,
|
||||||
Ale_MAX_BYTES_ALERT);
|
Ale_MAX_BYTES_ALERT);
|
||||||
Ctr_ShowAlertAndButtonToGoToCtr ();
|
Ctr_ShowAlertAndButtonToGoToCtr ();
|
||||||
|
|
||||||
|
@ -1933,7 +1933,7 @@ void Ctr_ChangeCtrPlcInConfig (void)
|
||||||
Gbl.CurrentCtr.Ctr.PlcCod = NewPlcCod;
|
Gbl.CurrentCtr.Ctr.PlcCod = NewPlcCod;
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_place_of_the_centre_has_changed);
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_place_of_the_centre_has_changed);
|
||||||
|
|
||||||
/***** Show the form again *****/
|
/***** Show the form again *****/
|
||||||
Ctr_ShowConfiguration ();
|
Ctr_ShowConfiguration ();
|
||||||
|
@ -2022,8 +2022,8 @@ static void Ctr_RenameCentre (struct Centre *Ctr,Cns_ShrtOrFullName_t ShrtOrFull
|
||||||
/***** Check if new name is empty *****/
|
/***** Check if new name is empty *****/
|
||||||
if (!NewCtrName[0])
|
if (!NewCtrName[0])
|
||||||
{
|
{
|
||||||
Gbl.AlertToShowLater.Type = Ale_WARNING;
|
Gbl.DelayedAlert.Type = Ale_WARNING;
|
||||||
snprintf (Gbl.AlertToShowLater.Txt,sizeof (Gbl.AlertToShowLater.Txt),
|
snprintf (Gbl.DelayedAlert.Txt,sizeof (Gbl.DelayedAlert.Txt),
|
||||||
Txt_You_can_not_leave_the_name_of_the_centre_X_empty,
|
Txt_You_can_not_leave_the_name_of_the_centre_X_empty,
|
||||||
CurrentCtrName);
|
CurrentCtrName);
|
||||||
}
|
}
|
||||||
|
@ -2036,8 +2036,8 @@ static void Ctr_RenameCentre (struct Centre *Ctr,Cns_ShrtOrFullName_t ShrtOrFull
|
||||||
/***** If degree was in database... *****/
|
/***** If degree was in database... *****/
|
||||||
if (Ctr_CheckIfCtrNameExistsInIns (ParamName,NewCtrName,Ctr->CtrCod,Gbl.CurrentIns.Ins.InsCod))
|
if (Ctr_CheckIfCtrNameExistsInIns (ParamName,NewCtrName,Ctr->CtrCod,Gbl.CurrentIns.Ins.InsCod))
|
||||||
{
|
{
|
||||||
Gbl.AlertToShowLater.Type = Ale_WARNING;
|
Gbl.DelayedAlert.Type = Ale_WARNING;
|
||||||
snprintf (Gbl.AlertToShowLater.Txt,sizeof (Gbl.AlertToShowLater.Txt),
|
snprintf (Gbl.DelayedAlert.Txt,sizeof (Gbl.DelayedAlert.Txt),
|
||||||
Txt_The_centre_X_already_exists,NewCtrName);
|
Txt_The_centre_X_already_exists,NewCtrName);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -2046,8 +2046,8 @@ static void Ctr_RenameCentre (struct Centre *Ctr,Cns_ShrtOrFullName_t ShrtOrFull
|
||||||
Ctr_UpdateInsNameDB (Ctr->CtrCod,FieldName,NewCtrName);
|
Ctr_UpdateInsNameDB (Ctr->CtrCod,FieldName,NewCtrName);
|
||||||
|
|
||||||
/* Write message to show the change made */
|
/* Write message to show the change made */
|
||||||
Gbl.AlertToShowLater.Type = Ale_SUCCESS;
|
Gbl.DelayedAlert.Type = Ale_SUCCESS;
|
||||||
snprintf (Gbl.AlertToShowLater.Txt,sizeof (Gbl.AlertToShowLater.Txt),
|
snprintf (Gbl.DelayedAlert.Txt,sizeof (Gbl.DelayedAlert.Txt),
|
||||||
Txt_The_centre_X_has_been_renamed_as_Y,
|
Txt_The_centre_X_has_been_renamed_as_Y,
|
||||||
CurrentCtrName,NewCtrName);
|
CurrentCtrName,NewCtrName);
|
||||||
|
|
||||||
|
@ -2058,8 +2058,8 @@ static void Ctr_RenameCentre (struct Centre *Ctr,Cns_ShrtOrFullName_t ShrtOrFull
|
||||||
}
|
}
|
||||||
else // The same name
|
else // The same name
|
||||||
{
|
{
|
||||||
Gbl.AlertToShowLater.Type = Ale_INFO;
|
Gbl.DelayedAlert.Type = Ale_INFO;
|
||||||
snprintf (Gbl.AlertToShowLater.Txt,sizeof (Gbl.AlertToShowLater.Txt),
|
snprintf (Gbl.DelayedAlert.Txt,sizeof (Gbl.DelayedAlert.Txt),
|
||||||
Txt_The_name_of_the_centre_X_has_not_changed,
|
Txt_The_name_of_the_centre_X_has_not_changed,
|
||||||
CurrentCtrName);
|
CurrentCtrName);
|
||||||
}
|
}
|
||||||
|
@ -2121,14 +2121,14 @@ void Ctr_ChangeCtrWWW (void)
|
||||||
|
|
||||||
/***** Write message to show the change made
|
/***** Write message to show the change made
|
||||||
and put button to go to centre changed *****/
|
and put button to go to centre changed *****/
|
||||||
Gbl.AlertToShowLater.Type = Ale_SUCCESS;
|
Gbl.DelayedAlert.Type = Ale_SUCCESS;
|
||||||
snprintf (Gbl.AlertToShowLater.Txt,sizeof (Gbl.Alert.Txt),
|
snprintf (Gbl.DelayedAlert.Txt,sizeof (Gbl.Alert.Txt),
|
||||||
Txt_The_new_web_address_is_X,
|
Txt_The_new_web_address_is_X,
|
||||||
NewWWW);
|
NewWWW);
|
||||||
Ctr_ShowAlertAndButtonToGoToCtr ();
|
Ctr_ShowAlertAndButtonToGoToCtr ();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_can_not_leave_the_web_address_empty);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_can_not_leave_the_web_address_empty);
|
||||||
|
|
||||||
/***** Show the form again *****/
|
/***** Show the form again *****/
|
||||||
Ctr_EditCentres ();
|
Ctr_EditCentres ();
|
||||||
|
@ -2153,11 +2153,11 @@ void Ctr_ChangeCtrWWWInConfig (void)
|
||||||
Cns_MAX_BYTES_WWW);
|
Cns_MAX_BYTES_WWW);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_new_web_address_is_X,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_new_web_address_is_X,
|
||||||
NewWWW);
|
NewWWW);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_can_not_leave_the_web_address_empty);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_can_not_leave_the_web_address_empty);
|
||||||
|
|
||||||
/***** Show the form again *****/
|
/***** Show the form again *****/
|
||||||
Ctr_ShowConfiguration ();
|
Ctr_ShowConfiguration ();
|
||||||
|
@ -2211,8 +2211,8 @@ void Ctr_ChangeCtrStatus (void)
|
||||||
|
|
||||||
/***** Write message to show the change made
|
/***** Write message to show the change made
|
||||||
and put button to go to centre changed *****/
|
and put button to go to centre changed *****/
|
||||||
Gbl.AlertToShowLater.Type = Ale_SUCCESS;
|
Gbl.DelayedAlert.Type = Ale_SUCCESS;
|
||||||
snprintf (Gbl.AlertToShowLater.Txt,sizeof (Gbl.Alert.Txt),
|
snprintf (Gbl.DelayedAlert.Txt,sizeof (Gbl.Alert.Txt),
|
||||||
Txt_The_status_of_the_centre_X_has_changed,
|
Txt_The_status_of_the_centre_X_has_changed,
|
||||||
Gbl.Ctrs.EditingCtr.ShrtName);
|
Gbl.Ctrs.EditingCtr.ShrtName);
|
||||||
Ctr_ShowAlertAndButtonToGoToCtr ();
|
Ctr_ShowAlertAndButtonToGoToCtr ();
|
||||||
|
@ -2259,7 +2259,7 @@ static void Ctr_ShowAlertAndButtonToGoToCtr (void)
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
/***** Alert *****/
|
/***** Alert *****/
|
||||||
Ale_ShowA_new (Gbl.AlertToShowLater.Type,Gbl.AlertToShowLater.Txt);
|
Ale_ShowDelayedAlert (Gbl.DelayedAlert.Type,Gbl.DelayedAlert.Txt);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void Ctr_PutParamGoToCtr (void)
|
static void Ctr_PutParamGoToCtr (void)
|
||||||
|
@ -2315,7 +2315,7 @@ void Ctr_RequestPhoto (void)
|
||||||
NULL,Box_NOT_CLOSABLE);
|
NULL,Box_NOT_CLOSABLE);
|
||||||
|
|
||||||
/***** Write help message *****/
|
/***** Write help message *****/
|
||||||
Ale_ShowA_fmt (Ale_INFO,"%s: %s<br />"
|
Ale_ShowAlert (Ale_INFO,"%s: %s<br />"
|
||||||
"%s: %u×%u %s",
|
"%s: %u×%u %s",
|
||||||
Txt_Recommended_aspect_ratio,
|
Txt_Recommended_aspect_ratio,
|
||||||
Ctr_RECOMMENDED_ASPECT_RATIO,
|
Ctr_RECOMMENDED_ASPECT_RATIO,
|
||||||
|
@ -2374,7 +2374,7 @@ void Ctr_ReceivePhoto (void)
|
||||||
WrongType = true;
|
WrongType = true;
|
||||||
if (WrongType)
|
if (WrongType)
|
||||||
{
|
{
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_Wrong_file_type);
|
Ale_ShowAlert (Ale_WARNING,Txt_Wrong_file_type);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2394,14 +2394,14 @@ void Ctr_ReceivePhoto (void)
|
||||||
/* Get filename extension */
|
/* Get filename extension */
|
||||||
if ((PtrExtension = strrchr (FileNameImgSrc,(int) '.')) == NULL)
|
if ((PtrExtension = strrchr (FileNameImgSrc,(int) '.')) == NULL)
|
||||||
{
|
{
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_Wrong_file_type);
|
Ale_ShowAlert (Ale_WARNING,Txt_Wrong_file_type);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
LengthExtension = strlen (PtrExtension);
|
LengthExtension = strlen (PtrExtension);
|
||||||
if (LengthExtension < Fil_MIN_BYTES_FILE_EXTENSION ||
|
if (LengthExtension < Fil_MIN_BYTES_FILE_EXTENSION ||
|
||||||
LengthExtension > Fil_MAX_BYTES_FILE_EXTENSION)
|
LengthExtension > Fil_MAX_BYTES_FILE_EXTENSION)
|
||||||
{
|
{
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_Wrong_file_type);
|
Ale_ShowAlert (Ale_WARNING,Txt_Wrong_file_type);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2412,7 +2412,7 @@ void Ctr_ReceivePhoto (void)
|
||||||
Gbl.UniqueNameEncrypted,PtrExtension);
|
Gbl.UniqueNameEncrypted,PtrExtension);
|
||||||
if (!Fil_EndReceptionOfFile (FileNameImgTmp,Param))
|
if (!Fil_EndReceptionOfFile (FileNameImgTmp,Param))
|
||||||
{
|
{
|
||||||
Ale_ShowA_fmt (Ale_WARNING,"Error copying file.");
|
Ale_ShowAlert (Ale_WARNING,"Error copying file.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2767,7 +2767,7 @@ static void Ctr_RecFormRequestOrCreateCtr (unsigned Status)
|
||||||
|
|
||||||
/* Get place */
|
/* Get place */
|
||||||
if ((Gbl.Ctrs.EditingCtr.PlcCod = Plc_GetParamPlcCod ()) < 0) // 0 is reserved for "other place"
|
if ((Gbl.Ctrs.EditingCtr.PlcCod = Plc_GetParamPlcCod ()) < 0) // 0 is reserved for "other place"
|
||||||
Ale_ShowA_fmt (Ale_ERROR,"Wrong place.");
|
Ale_ShowAlert (Ale_ERROR,"Wrong place.");
|
||||||
|
|
||||||
/* Get centre short name */
|
/* Get centre short name */
|
||||||
Par_GetParToText ("ShortName",Gbl.Ctrs.EditingCtr.ShrtName,Hie_MAX_BYTES_SHRT_NAME);
|
Par_GetParToText ("ShortName",Gbl.Ctrs.EditingCtr.ShrtName,Hie_MAX_BYTES_SHRT_NAME);
|
||||||
|
@ -2785,19 +2785,19 @@ static void Ctr_RecFormRequestOrCreateCtr (unsigned Status)
|
||||||
{
|
{
|
||||||
/***** If name of centre was in database... *****/
|
/***** If name of centre was in database... *****/
|
||||||
if (Ctr_CheckIfCtrNameExistsInIns ("ShortName",Gbl.Ctrs.EditingCtr.ShrtName,-1L,Gbl.CurrentIns.Ins.InsCod))
|
if (Ctr_CheckIfCtrNameExistsInIns ("ShortName",Gbl.Ctrs.EditingCtr.ShrtName,-1L,Gbl.CurrentIns.Ins.InsCod))
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_centre_X_already_exists,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_centre_X_already_exists,
|
||||||
Gbl.Ctrs.EditingCtr.ShrtName);
|
Gbl.Ctrs.EditingCtr.ShrtName);
|
||||||
else if (Ctr_CheckIfCtrNameExistsInIns ("FullName",Gbl.Ctrs.EditingCtr.FullName,-1L,Gbl.CurrentIns.Ins.InsCod))
|
else if (Ctr_CheckIfCtrNameExistsInIns ("FullName",Gbl.Ctrs.EditingCtr.FullName,-1L,Gbl.CurrentIns.Ins.InsCod))
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_centre_X_already_exists,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_centre_X_already_exists,
|
||||||
Gbl.Ctrs.EditingCtr.FullName);
|
Gbl.Ctrs.EditingCtr.FullName);
|
||||||
else // Add new centre to database
|
else // Add new centre to database
|
||||||
Ctr_CreateCentre (Status);
|
Ctr_CreateCentre (Status);
|
||||||
}
|
}
|
||||||
else // If there is not a web
|
else // If there is not a web
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_must_specify_the_web_address_of_the_new_centre);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_must_specify_the_web_address_of_the_new_centre);
|
||||||
}
|
}
|
||||||
else // If there is not a centre name
|
else // If there is not a centre name
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_must_specify_the_short_name_and_the_full_name_of_the_new_centre);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_must_specify_the_short_name_and_the_full_name_of_the_new_centre);
|
||||||
|
|
||||||
/***** Show the form again *****/
|
/***** Show the form again *****/
|
||||||
Ctr_EditCentres ();
|
Ctr_EditCentres ();
|
||||||
|
@ -2831,8 +2831,8 @@ static void Ctr_CreateCentre (unsigned Status)
|
||||||
|
|
||||||
/***** Write message to show the change made
|
/***** Write message to show the change made
|
||||||
and put button to go to centre created *****/
|
and put button to go to centre created *****/
|
||||||
Gbl.AlertToShowLater.Type = Ale_SUCCESS;
|
Gbl.DelayedAlert.Type = Ale_SUCCESS;
|
||||||
snprintf (Gbl.AlertToShowLater.Txt,sizeof (Gbl.AlertToShowLater.Txt),
|
snprintf (Gbl.DelayedAlert.Txt,sizeof (Gbl.DelayedAlert.Txt),
|
||||||
Txt_Created_new_centre_X,
|
Txt_Created_new_centre_X,
|
||||||
Gbl.Ctrs.EditingCtr.FullName);
|
Gbl.Ctrs.EditingCtr.FullName);
|
||||||
Ctr_ShowAlertAndButtonToGoToCtr ();
|
Ctr_ShowAlertAndButtonToGoToCtr ();
|
||||||
|
|
|
@ -402,10 +402,11 @@ En OpenSWAD:
|
||||||
ps2pdf source.ps destination.pdf
|
ps2pdf source.ps destination.pdf
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#define Log_PLATFORM_VERSION "SWAD 18.46.4 (2019-02-16)"
|
#define Log_PLATFORM_VERSION "SWAD 18.46.5 (2019-02-16)"
|
||||||
#define CSS_FILE "swad18.41.1.css"
|
#define CSS_FILE "swad18.41.1.css"
|
||||||
#define JS_FILE "swad18.32.1.js"
|
#define JS_FILE "swad18.32.1.js"
|
||||||
/*
|
/*
|
||||||
|
Version 18.46.5: Feb 16, 2019 Refactoring code related to alerts. (238062 lines)
|
||||||
Version 18.46.4: Feb 16, 2019 Refactoring code related to alerts. (238061 lines)
|
Version 18.46.4: Feb 16, 2019 Refactoring code related to alerts. (238061 lines)
|
||||||
Version 18.46.3: Feb 16, 2019 Refactoring code related to alerts. (238243 lines)
|
Version 18.46.3: Feb 16, 2019 Refactoring code related to alerts. (238243 lines)
|
||||||
Version 18.46.2: Feb 16, 2019 Refactoring code related to alerts. (238298 lines)
|
Version 18.46.2: Feb 16, 2019 Refactoring code related to alerts. (238298 lines)
|
||||||
|
|
|
@ -82,14 +82,14 @@ void Cht_ShowChatRooms (void)
|
||||||
extern const char *Txt_Unfortunately_Firefox_and_Chrome_no_longer_allow_Java_to_run_;
|
extern const char *Txt_Unfortunately_Firefox_and_Chrome_no_longer_allow_Java_to_run_;
|
||||||
|
|
||||||
/***** Help message about software needed to use the whiteboard/chat *****/
|
/***** Help message about software needed to use the whiteboard/chat *****/
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_To_use_chat_you_must_have_installed_the_software_X_and_add_Y_,
|
Ale_ShowAlert (Ale_INFO,Txt_To_use_chat_you_must_have_installed_the_software_X_and_add_Y_,
|
||||||
Cfg_JAVA_URL,Cfg_JAVA_NAME,
|
Cfg_JAVA_URL,Cfg_JAVA_NAME,
|
||||||
Cfg_PLATFORM_SERVER);
|
Cfg_PLATFORM_SERVER);
|
||||||
|
|
||||||
/***** List available chat rooms *****/
|
/***** List available chat rooms *****/
|
||||||
Cht_ShowListOfAvailableChatRooms ();
|
Cht_ShowListOfAvailableChatRooms ();
|
||||||
|
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_Unfortunately_Firefox_and_Chrome_no_longer_allow_Java_to_run_);
|
Ale_ShowAlert (Ale_WARNING,Txt_Unfortunately_Firefox_and_Chrome_no_longer_allow_Java_to_run_);
|
||||||
|
|
||||||
if (Gbl.Usrs.Me.Role.Logged == Rol_SYS_ADM)
|
if (Gbl.Usrs.Me.Role.Logged == Rol_SYS_ADM)
|
||||||
Cht_ShowListOfChatRoomsWithUsrs ();
|
Cht_ShowListOfChatRoomsWithUsrs ();
|
||||||
|
|
|
@ -583,7 +583,7 @@ void Cla_RemoveClassroom (void)
|
||||||
Cla->ClaCod);
|
Cla->ClaCod);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Classroom_X_removed,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Classroom_X_removed,
|
||||||
Cla->FullName);
|
Cla->FullName);
|
||||||
|
|
||||||
/***** Show the form again *****/
|
/***** Show the form again *****/
|
||||||
|
@ -668,7 +668,7 @@ static void Cla_RenameClassroom (Cns_ShrtOrFullName_t ShrtOrFullName)
|
||||||
|
|
||||||
/***** Check if new name is empty *****/
|
/***** Check if new name is empty *****/
|
||||||
if (!NewClaName[0])
|
if (!NewClaName[0])
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_can_not_leave_the_name_of_the_classroom_X_empty,
|
Ale_ShowAlert (Ale_WARNING,Txt_You_can_not_leave_the_name_of_the_classroom_X_empty,
|
||||||
CurrentClaName);
|
CurrentClaName);
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -678,7 +678,7 @@ static void Cla_RenameClassroom (Cns_ShrtOrFullName_t ShrtOrFullName)
|
||||||
{
|
{
|
||||||
/***** If classroom was in database... *****/
|
/***** If classroom was in database... *****/
|
||||||
if (Cla_CheckIfClassroomNameExists (ParamName,NewClaName,Cla->ClaCod))
|
if (Cla_CheckIfClassroomNameExists (ParamName,NewClaName,Cla->ClaCod))
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_classroom_X_already_exists,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_classroom_X_already_exists,
|
||||||
NewClaName);
|
NewClaName);
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -686,12 +686,12 @@ static void Cla_RenameClassroom (Cns_ShrtOrFullName_t ShrtOrFullName)
|
||||||
Cla_UpdateClaNameDB (Cla->ClaCod,FieldName,NewClaName);
|
Cla_UpdateClaNameDB (Cla->ClaCod,FieldName,NewClaName);
|
||||||
|
|
||||||
/* Write message to show the change made */
|
/* Write message to show the change made */
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_classroom_X_has_been_renamed_as_Y,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_classroom_X_has_been_renamed_as_Y,
|
||||||
CurrentClaName,NewClaName);
|
CurrentClaName,NewClaName);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else // The same name
|
else // The same name
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_The_name_of_the_classroom_X_has_not_changed,
|
Ale_ShowAlert (Ale_INFO,Txt_The_name_of_the_classroom_X_has_not_changed,
|
||||||
CurrentClaName);
|
CurrentClaName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -763,7 +763,7 @@ void Cla_ChangeCapacity (void)
|
||||||
(this happens when return is pressed without changes) *****/
|
(this happens when return is pressed without changes) *****/
|
||||||
if (Cla->Capacity == NewCapacity)
|
if (Cla->Capacity == NewCapacity)
|
||||||
/***** Message to show no changes made *****/
|
/***** Message to show no changes made *****/
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_The_capacity_of_classroom_X_has_not_changed,
|
Ale_ShowAlert (Ale_INFO,Txt_The_capacity_of_classroom_X_has_not_changed,
|
||||||
Cla->FullName);
|
Cla->FullName);
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -775,10 +775,10 @@ void Cla_ChangeCapacity (void)
|
||||||
|
|
||||||
/***** Message to show the change made *****/
|
/***** Message to show the change made *****/
|
||||||
if (NewCapacity > Grp_MAX_STUDENTS_IN_A_GROUP)
|
if (NewCapacity > Grp_MAX_STUDENTS_IN_A_GROUP)
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_classroom_X_does_not_have_a_limited_capacity_now,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_classroom_X_does_not_have_a_limited_capacity_now,
|
||||||
Cla->FullName);
|
Cla->FullName);
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_capacity_of_classroom_X_is_now_Y,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_capacity_of_classroom_X_is_now_Y,
|
||||||
Cla->FullName,NewCapacity);
|
Cla->FullName,NewCapacity);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -830,11 +830,11 @@ void Cla_ChangeClassroomLocation (void)
|
||||||
Cla_MAX_BYTES_LOCATION);
|
Cla_MAX_BYTES_LOCATION);
|
||||||
|
|
||||||
/* Write message to show the change made */
|
/* Write message to show the change made */
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_location_of_the_classroom_X_has_changed_to_Y,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_location_of_the_classroom_X_has_changed_to_Y,
|
||||||
Cla->FullName,NewLocation);
|
Cla->FullName,NewLocation);
|
||||||
}
|
}
|
||||||
else // The same location
|
else // The same location
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_The_location_of_the_classroom_X_has_not_changed,
|
Ale_ShowAlert (Ale_INFO,Txt_The_location_of_the_classroom_X_has_not_changed,
|
||||||
Cla->FullName);
|
Cla->FullName);
|
||||||
|
|
||||||
/***** Show the form again *****/
|
/***** Show the form again *****/
|
||||||
|
@ -983,16 +983,16 @@ void Cla_RecFormNewClassroom (void)
|
||||||
{
|
{
|
||||||
/***** If name of classroom was in database... *****/
|
/***** If name of classroom was in database... *****/
|
||||||
if (Cla_CheckIfClassroomNameExists ("ShortName",Cla->ShrtName,-1L))
|
if (Cla_CheckIfClassroomNameExists ("ShortName",Cla->ShrtName,-1L))
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_classroom_X_already_exists,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_classroom_X_already_exists,
|
||||||
Cla->ShrtName);
|
Cla->ShrtName);
|
||||||
else if (Cla_CheckIfClassroomNameExists ("FullName",Cla->FullName,-1L))
|
else if (Cla_CheckIfClassroomNameExists ("FullName",Cla->FullName,-1L))
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_classroom_X_already_exists,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_classroom_X_already_exists,
|
||||||
Cla->FullName);
|
Cla->FullName);
|
||||||
else // Add new classroom to database
|
else // Add new classroom to database
|
||||||
Cla_CreateClassroom (Cla);
|
Cla_CreateClassroom (Cla);
|
||||||
}
|
}
|
||||||
else // If there is not a classroom name
|
else // If there is not a classroom name
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_must_specify_the_short_name_and_the_full_name_of_the_new_classroom);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_must_specify_the_short_name_and_the_full_name_of_the_new_classroom);
|
||||||
|
|
||||||
/***** Show the form again *****/
|
/***** Show the form again *****/
|
||||||
Cla_EditClassrooms ();
|
Cla_EditClassrooms ();
|
||||||
|
@ -1016,6 +1016,6 @@ static void Cla_CreateClassroom (struct Classroom *Cla)
|
||||||
Cla->ShrtName,Cla->FullName,Cla->Capacity,Cla->Location);
|
Cla->ShrtName,Cla->FullName,Cla->Capacity,Cla->Location);
|
||||||
|
|
||||||
/***** Write success message *****/
|
/***** Write success message *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Created_new_classroom_X,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Created_new_classroom_X,
|
||||||
Cla->FullName);
|
Cla->FullName);
|
||||||
}
|
}
|
||||||
|
|
|
@ -197,7 +197,7 @@ void Cty_SeeCtyWithPendingInss (void)
|
||||||
Box_EndBoxTable ();
|
Box_EndBoxTable ();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_There_are_no_countries_with_requests_for_institutions_to_be_confirmed);
|
Ale_ShowAlert (Ale_INFO,Txt_There_are_no_countries_with_requests_for_institutions_to_be_confirmed);
|
||||||
|
|
||||||
/***** Free structure that stores the query result *****/
|
/***** Free structure that stores the query result *****/
|
||||||
DB_FreeMySQLResult (&mysql_res);
|
DB_FreeMySQLResult (&mysql_res);
|
||||||
|
@ -1740,7 +1740,7 @@ void Cty_RemoveCountry (void)
|
||||||
if (Cty.NumInss ||
|
if (Cty.NumInss ||
|
||||||
Cty.NumUsrsWhoClaimToBelongToCty ||
|
Cty.NumUsrsWhoClaimToBelongToCty ||
|
||||||
Cty.NumUsrs) // Country has institutions or users ==> don't remove
|
Cty.NumUsrs) // Country has institutions or users ==> don't remove
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_can_not_remove_a_country_with_institutions_or_users);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_can_not_remove_a_country_with_institutions_or_users);
|
||||||
else // Country has no users ==> remove it
|
else // Country has no users ==> remove it
|
||||||
{
|
{
|
||||||
/***** Remove surveys of the country *****/
|
/***** Remove surveys of the country *****/
|
||||||
|
@ -1755,7 +1755,7 @@ void Cty_RemoveCountry (void)
|
||||||
Cty_FlushCacheCountryName ();
|
Cty_FlushCacheCountryName ();
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Country_X_removed,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Country_X_removed,
|
||||||
Cty.Name[Gbl.Prefs.Language]);
|
Cty.Name[Gbl.Prefs.Language]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1795,7 +1795,7 @@ void Cty_RenameCountry (void)
|
||||||
|
|
||||||
/***** Check if new name is empty *****/
|
/***** Check if new name is empty *****/
|
||||||
if (!NewCtyName[0])
|
if (!NewCtyName[0])
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_can_not_leave_the_name_of_the_country_X_empty,
|
Ale_ShowAlert (Ale_WARNING,Txt_You_can_not_leave_the_name_of_the_country_X_empty,
|
||||||
Cty->Name[Language]);
|
Cty->Name[Language]);
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -1805,7 +1805,7 @@ void Cty_RenameCountry (void)
|
||||||
{
|
{
|
||||||
/***** If country was in database... *****/
|
/***** If country was in database... *****/
|
||||||
if (Cty_CheckIfCountryNameExists (Language,NewCtyName,Cty->CtyCod))
|
if (Cty_CheckIfCountryNameExists (Language,NewCtyName,Cty->CtyCod))
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_country_X_already_exists,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_country_X_already_exists,
|
||||||
NewCtyName);
|
NewCtyName);
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -1816,7 +1816,7 @@ void Cty_RenameCountry (void)
|
||||||
Cty_UpdateCtyNameDB (Cty->CtyCod,FieldName,NewCtyName);
|
Cty_UpdateCtyNameDB (Cty->CtyCod,FieldName,NewCtyName);
|
||||||
|
|
||||||
/* Write message to show the change made */
|
/* Write message to show the change made */
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_country_X_has_been_renamed_as_Y,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_country_X_has_been_renamed_as_Y,
|
||||||
Cty->Name[Language],NewCtyName);
|
Cty->Name[Language],NewCtyName);
|
||||||
|
|
||||||
/* Update country name */
|
/* Update country name */
|
||||||
|
@ -1825,7 +1825,7 @@ void Cty_RenameCountry (void)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else // The same name
|
else // The same name
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_The_name_of_the_country_X_has_not_changed,
|
Ale_ShowAlert (Ale_INFO,Txt_The_name_of_the_country_X_has_not_changed,
|
||||||
Cty->Name[Language]);
|
Cty->Name[Language]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1927,7 +1927,7 @@ void Cty_ChangeCtyWWW (void)
|
||||||
Cns_MAX_BYTES_WWW);
|
Cns_MAX_BYTES_WWW);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_new_web_address_is_X,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_new_web_address_is_X,
|
||||||
NewWWW);
|
NewWWW);
|
||||||
|
|
||||||
/***** Show the form again *****/
|
/***** Show the form again *****/
|
||||||
|
@ -2131,12 +2131,12 @@ void Cty_RecFormNewCountry (void)
|
||||||
/* Get numeric country code */
|
/* Get numeric country code */
|
||||||
if ((Cty->CtyCod = Cty_GetParamOtherCtyCod ()) < 0)
|
if ((Cty->CtyCod = Cty_GetParamOtherCtyCod ()) < 0)
|
||||||
{
|
{
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_must_specify_the_numerical_code_of_the_new_country);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_must_specify_the_numerical_code_of_the_new_country);
|
||||||
CreateCountry = false;
|
CreateCountry = false;
|
||||||
}
|
}
|
||||||
else if (Cty_CheckIfNumericCountryCodeExists (Cty->CtyCod))
|
else if (Cty_CheckIfNumericCountryCodeExists (Cty->CtyCod))
|
||||||
{
|
{
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_numerical_code_X_already_exists,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_numerical_code_X_already_exists,
|
||||||
Cty->CtyCod);
|
Cty->CtyCod);
|
||||||
CreateCountry = false;
|
CreateCountry = false;
|
||||||
}
|
}
|
||||||
|
@ -2151,7 +2151,7 @@ void Cty_RecFormNewCountry (void)
|
||||||
if (Cty->Alpha2[i] < 'A' ||
|
if (Cty->Alpha2[i] < 'A' ||
|
||||||
Cty->Alpha2[i] > 'Z')
|
Cty->Alpha2[i] > 'Z')
|
||||||
{
|
{
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_alphabetical_code_X_is_not_correct,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_alphabetical_code_X_is_not_correct,
|
||||||
Cty->Alpha2);
|
Cty->Alpha2);
|
||||||
CreateCountry = false;
|
CreateCountry = false;
|
||||||
}
|
}
|
||||||
|
@ -2159,7 +2159,7 @@ void Cty_RecFormNewCountry (void)
|
||||||
{
|
{
|
||||||
if (Cty_CheckIfAlpha2CountryCodeExists (Cty->Alpha2))
|
if (Cty_CheckIfAlpha2CountryCodeExists (Cty->Alpha2))
|
||||||
{
|
{
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_alphabetical_code_X_already_exists,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_alphabetical_code_X_already_exists,
|
||||||
Cty->Alpha2);
|
Cty->Alpha2);
|
||||||
CreateCountry = false;
|
CreateCountry = false;
|
||||||
}
|
}
|
||||||
|
@ -2180,7 +2180,7 @@ void Cty_RecFormNewCountry (void)
|
||||||
/***** If name of country was in database... *****/
|
/***** If name of country was in database... *****/
|
||||||
if (Cty_CheckIfCountryNameExists (Lan,Cty->Name[Lan],-1L))
|
if (Cty_CheckIfCountryNameExists (Lan,Cty->Name[Lan],-1L))
|
||||||
{
|
{
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_country_X_already_exists,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_country_X_already_exists,
|
||||||
Cty->Name[Lan]);
|
Cty->Name[Lan]);
|
||||||
CreateCountry = false;
|
CreateCountry = false;
|
||||||
break;
|
break;
|
||||||
|
@ -2188,7 +2188,7 @@ void Cty_RecFormNewCountry (void)
|
||||||
}
|
}
|
||||||
else // If there is not a country name
|
else // If there is not a country name
|
||||||
{
|
{
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_must_specify_the_name_of_the_new_country_in_all_languages);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_must_specify_the_name_of_the_new_country_in_all_languages);
|
||||||
CreateCountry = false;
|
CreateCountry = false;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -2271,7 +2271,7 @@ static void Cty_CreateCountry (struct Country *Cty)
|
||||||
Cty->CtyCod,Cty->Alpha2,SubQueryNam2,SubQueryWWW2);
|
Cty->CtyCod,Cty->Alpha2,SubQueryNam2,SubQueryWWW2);
|
||||||
|
|
||||||
/***** Write success message *****/
|
/***** Write success message *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Created_new_country_X,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Created_new_country_X,
|
||||||
Cty->Name);
|
Cty->Name);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1164,7 +1164,7 @@ static void Crs_ListCourses (void)
|
||||||
Tbl_EndTable ();
|
Tbl_EndTable ();
|
||||||
}
|
}
|
||||||
else // No courses created in the current degree
|
else // No courses created in the current degree
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_No_courses);
|
Ale_ShowAlert (Ale_INFO,Txt_No_courses);
|
||||||
|
|
||||||
/***** Button to create course *****/
|
/***** Button to create course *****/
|
||||||
if (Crs_CheckIfICanCreateCourses ())
|
if (Crs_CheckIfICanCreateCourses ())
|
||||||
|
@ -1998,19 +1998,19 @@ void Crs_RemoveCourse (void)
|
||||||
{
|
{
|
||||||
/***** Check if this course has users *****/
|
/***** Check if this course has users *****/
|
||||||
if (Crs.NumUsrs[Rol_UNK]) // Course has users ==> don't remove
|
if (Crs.NumUsrs[Rol_UNK]) // Course has users ==> don't remove
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_To_remove_a_course_you_must_first_remove_all_users_in_the_course);
|
Ale_ShowAlert (Ale_WARNING,Txt_To_remove_a_course_you_must_first_remove_all_users_in_the_course);
|
||||||
else // Course has no users ==> remove it
|
else // Course has no users ==> remove it
|
||||||
{
|
{
|
||||||
/***** Remove course *****/
|
/***** Remove course *****/
|
||||||
Crs_RemoveCourseCompletely (Crs.CrsCod);
|
Crs_RemoveCourseCompletely (Crs.CrsCod);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Course_X_removed,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Course_X_removed,
|
||||||
Crs.FullName);
|
Crs.FullName);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_dont_have_permission_to_edit_this_course);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_dont_have_permission_to_edit_this_course);
|
||||||
|
|
||||||
/***** Show the form again *****/
|
/***** Show the form again *****/
|
||||||
Crs_EditCourses ();
|
Crs_EditCourses ();
|
||||||
|
@ -3468,7 +3468,7 @@ void Crs_RemoveOldCrss (void)
|
||||||
SecondsWithoutAccess);
|
SecondsWithoutAccess);
|
||||||
if (NumCrss)
|
if (NumCrss)
|
||||||
{
|
{
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_Eliminating_X_courses_whithout_users_and_with_more_than_Y_months_without_access,
|
Ale_ShowAlert (Ale_INFO,Txt_Eliminating_X_courses_whithout_users_and_with_more_than_Y_months_without_access,
|
||||||
NumCrss,
|
NumCrss,
|
||||||
MonthsWithoutAccess,
|
MonthsWithoutAccess,
|
||||||
Cfg_PLATFORM_SHORT_NAME);
|
Cfg_PLATFORM_SHORT_NAME);
|
||||||
|
@ -3489,6 +3489,6 @@ void Crs_RemoveOldCrss (void)
|
||||||
}
|
}
|
||||||
|
|
||||||
/***** Write end message *****/
|
/***** Write end message *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_X_courses_have_been_eliminated,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_X_courses_have_been_eliminated,
|
||||||
NumCrssRemoved);
|
NumCrssRemoved);
|
||||||
}
|
}
|
||||||
|
|
|
@ -88,7 +88,7 @@ void DB_CreateTablesIfNotExist (void)
|
||||||
extern const char *Txt_Created_tables_in_the_database_that_did_not_exist;
|
extern const char *Txt_Created_tables_in_the_database_that_did_not_exist;
|
||||||
|
|
||||||
/***** Information message *****/
|
/***** Information message *****/
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_Creating_database_tables_if_they_do_not_exist);
|
Ale_ShowAlert (Ale_INFO,Txt_Creating_database_tables_if_they_do_not_exist);
|
||||||
fprintf (Gbl.F.Out,"<ol>");
|
fprintf (Gbl.F.Out,"<ol>");
|
||||||
|
|
||||||
/***** Table IP_prefs *****/
|
/***** Table IP_prefs *****/
|
||||||
|
@ -3086,7 +3086,7 @@ mysql> DESCRIBE ws_keys;
|
||||||
|
|
||||||
/***** Show success message *****/
|
/***** Show success message *****/
|
||||||
fprintf (Gbl.F.Out,"</ol>");
|
fprintf (Gbl.F.Out,"</ol>");
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Created_tables_in_the_database_that_did_not_exist);
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Created_tables_in_the_database_that_did_not_exist);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
|
@ -228,7 +228,7 @@ void Deg_SeeDegWithPendingCrss (void)
|
||||||
Box_EndBoxTable ();
|
Box_EndBoxTable ();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_There_are_no_degrees_with_requests_for_courses_to_be_confirmed);
|
Ale_ShowAlert (Ale_INFO,Txt_There_are_no_degrees_with_requests_for_courses_to_be_confirmed);
|
||||||
|
|
||||||
/***** Free structure that stores the query result *****/
|
/***** Free structure that stores the query result *****/
|
||||||
DB_FreeMySQLResult (&mysql_res);
|
DB_FreeMySQLResult (&mysql_res);
|
||||||
|
@ -1202,7 +1202,7 @@ static void Deg_ListDegrees (void)
|
||||||
Tbl_EndTable ();
|
Tbl_EndTable ();
|
||||||
}
|
}
|
||||||
else // No degrees created in the current centre
|
else // No degrees created in the current centre
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_No_degrees);
|
Ale_ShowAlert (Ale_INFO,Txt_No_degrees);
|
||||||
|
|
||||||
/***** Button to create degree *****/
|
/***** Button to create degree *****/
|
||||||
if (Deg_CheckIfICanCreateDegrees ())
|
if (Deg_CheckIfICanCreateDegrees ())
|
||||||
|
@ -1376,7 +1376,7 @@ void Deg_EditDegrees (void)
|
||||||
else // No degree types
|
else // No degree types
|
||||||
{
|
{
|
||||||
/***** Warning message *****/
|
/***** Warning message *****/
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_No_types_of_degree);
|
Ale_ShowAlert (Ale_WARNING,Txt_No_types_of_degree);
|
||||||
|
|
||||||
/***** Form to create the first degree type *****/
|
/***** Form to create the first degree type *****/
|
||||||
if (DT_CheckIfICanCreateDegreeTypes ())
|
if (DT_CheckIfICanCreateDegreeTypes ())
|
||||||
|
@ -1579,19 +1579,19 @@ static void Deg_RecFormRequestOrCreateDeg (unsigned Status)
|
||||||
{
|
{
|
||||||
/***** If name of degree was in database... *****/
|
/***** If name of degree was in database... *****/
|
||||||
if (Deg_CheckIfDegNameExistsInCtr ("ShortName",Gbl.Degs.EditingDeg.ShrtName,-1L,Gbl.Degs.EditingDeg.CtrCod))
|
if (Deg_CheckIfDegNameExistsInCtr ("ShortName",Gbl.Degs.EditingDeg.ShrtName,-1L,Gbl.Degs.EditingDeg.CtrCod))
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_degree_X_already_exists,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_degree_X_already_exists,
|
||||||
Gbl.Degs.EditingDeg.ShrtName);
|
Gbl.Degs.EditingDeg.ShrtName);
|
||||||
else if (Deg_CheckIfDegNameExistsInCtr ("FullName",Gbl.Degs.EditingDeg.FullName,-1L,Gbl.Degs.EditingDeg.CtrCod))
|
else if (Deg_CheckIfDegNameExistsInCtr ("FullName",Gbl.Degs.EditingDeg.FullName,-1L,Gbl.Degs.EditingDeg.CtrCod))
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_degree_X_already_exists,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_degree_X_already_exists,
|
||||||
Gbl.Degs.EditingDeg.FullName);
|
Gbl.Degs.EditingDeg.FullName);
|
||||||
else // Add new degree to database
|
else // Add new degree to database
|
||||||
Deg_CreateDegree (Status);
|
Deg_CreateDegree (Status);
|
||||||
}
|
}
|
||||||
else // If there is not a degree logo or web
|
else // If there is not a degree logo or web
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_must_specify_the_web_address_of_the_new_degree);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_must_specify_the_web_address_of_the_new_degree);
|
||||||
}
|
}
|
||||||
else // If there is not a degree name
|
else // If there is not a degree name
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_must_specify_the_short_name_and_the_full_name_of_the_new_degree);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_must_specify_the_short_name_and_the_full_name_of_the_new_degree);
|
||||||
|
|
||||||
/***** Show the form again *****/
|
/***** Show the form again *****/
|
||||||
Deg_EditDegrees ();
|
Deg_EditDegrees ();
|
||||||
|
@ -1615,14 +1615,14 @@ void Deg_RemoveDegree (void)
|
||||||
|
|
||||||
/***** Check if this degree has courses *****/
|
/***** Check if this degree has courses *****/
|
||||||
if (Crs_GetNumCrssInDeg (Deg.DegCod)) // Degree has courses ==> don't remove
|
if (Crs_GetNumCrssInDeg (Deg.DegCod)) // Degree has courses ==> don't remove
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_To_remove_a_degree_you_must_first_remove_all_courses_in_the_degree);
|
Ale_ShowAlert (Ale_WARNING,Txt_To_remove_a_degree_you_must_first_remove_all_courses_in_the_degree);
|
||||||
else // Degree has no courses ==> remove it
|
else // Degree has no courses ==> remove it
|
||||||
{
|
{
|
||||||
/***** Remove degree *****/
|
/***** Remove degree *****/
|
||||||
Deg_RemoveDegreeCompletely (Deg.DegCod);
|
Deg_RemoveDegreeCompletely (Deg.DegCod);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Degree_X_removed,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Degree_X_removed,
|
||||||
Deg.FullName);
|
Deg.FullName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2163,7 +2163,7 @@ void Deg_ChangeDegWWW (void)
|
||||||
Deg_ShowAlertAndButtonToGoToDeg ();
|
Deg_ShowAlertAndButtonToGoToDeg ();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_can_not_leave_the_web_address_empty);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_can_not_leave_the_web_address_empty);
|
||||||
|
|
||||||
/***** Show the form again *****/
|
/***** Show the form again *****/
|
||||||
Deg_EditDegrees ();
|
Deg_EditDegrees ();
|
||||||
|
@ -2188,11 +2188,11 @@ void Deg_ChangeDegWWWInConfig (void)
|
||||||
Cns_MAX_BYTES_WWW);
|
Cns_MAX_BYTES_WWW);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_new_web_address_is_X,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_new_web_address_is_X,
|
||||||
NewWWW);
|
NewWWW);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_can_not_leave_the_web_address_empty);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_can_not_leave_the_web_address_empty);
|
||||||
|
|
||||||
/***** Show the form again *****/
|
/***** Show the form again *****/
|
||||||
Deg_ShowConfiguration ();
|
Deg_ShowConfiguration ();
|
||||||
|
@ -2295,7 +2295,7 @@ void Deg_ShowAlertAndButtonToGoToDeg (void)
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
/***** Alert *****/
|
/***** Alert *****/
|
||||||
Ale_ShowA_new (Gbl.AlertToShowLater.Type,Gbl.AlertToShowLater.Txt);
|
Ale_ShowDelayedAlert (Gbl.DelayedAlert.Type,Gbl.DelayedAlert.Txt);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void Deg_PutParamGoToDeg (void)
|
static void Deg_PutParamGoToDeg (void)
|
||||||
|
|
|
@ -218,7 +218,7 @@ static void DT_ListDegreeTypes (Act_Action_t NextAction,DT_Order_t SelectedOrder
|
||||||
Tbl_EndTable ();
|
Tbl_EndTable ();
|
||||||
}
|
}
|
||||||
else // No degree types created
|
else // No degree types created
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_No_types_of_degree);
|
Ale_ShowAlert (Ale_INFO,Txt_No_types_of_degree);
|
||||||
|
|
||||||
/***** Button to create degree type *****/
|
/***** Button to create degree type *****/
|
||||||
if (DT_CheckIfICanCreateDegreeTypes ())
|
if (DT_CheckIfICanCreateDegreeTypes ())
|
||||||
|
@ -567,7 +567,7 @@ static void DT_CreateDegreeType (struct DegreeType *DegTyp)
|
||||||
DegTyp->DegTypName);
|
DegTyp->DegTypName);
|
||||||
|
|
||||||
/***** Write success message *****/
|
/***** Write success message *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Created_new_type_of_degree_X,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Created_new_type_of_degree_X,
|
||||||
DegTyp->DegTypName);
|
DegTyp->DegTypName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -739,13 +739,13 @@ void DT_RecFormNewDegreeType (void)
|
||||||
{
|
{
|
||||||
/***** If name of degree type was in database... *****/
|
/***** If name of degree type was in database... *****/
|
||||||
if (DT_CheckIfDegreeTypeNameExists (DegTyp->DegTypName,-1L))
|
if (DT_CheckIfDegreeTypeNameExists (DegTyp->DegTypName,-1L))
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_type_of_degree_X_already_exists,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_type_of_degree_X_already_exists,
|
||||||
DegTyp->DegTypName);
|
DegTyp->DegTypName);
|
||||||
else // Add new degree type to database
|
else // Add new degree type to database
|
||||||
DT_CreateDegreeType (DegTyp);
|
DT_CreateDegreeType (DegTyp);
|
||||||
}
|
}
|
||||||
else // If there is not a degree type name
|
else // If there is not a degree type name
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_must_specify_the_name_of_the_new_type_of_degree);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_must_specify_the_name_of_the_new_type_of_degree);
|
||||||
|
|
||||||
/***** Show the form again *****/
|
/***** Show the form again *****/
|
||||||
DT_EditDegreeTypes ();
|
DT_EditDegreeTypes ();
|
||||||
|
@ -770,14 +770,14 @@ void DT_RemoveDegreeType (void)
|
||||||
|
|
||||||
/***** Check if this degree type has degrees *****/
|
/***** Check if this degree type has degrees *****/
|
||||||
if (DegTyp.NumDegs) // Degree type has degrees => don't remove
|
if (DegTyp.NumDegs) // Degree type has degrees => don't remove
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_To_remove_a_type_of_degree_you_must_first_remove_all_degrees_of_that_type);
|
Ale_ShowAlert (Ale_WARNING,Txt_To_remove_a_type_of_degree_you_must_first_remove_all_degrees_of_that_type);
|
||||||
else // Degree type has no degrees => remove it
|
else // Degree type has no degrees => remove it
|
||||||
{
|
{
|
||||||
/***** Remove degree type *****/
|
/***** Remove degree type *****/
|
||||||
DT_RemoveDegreeTypeCompletely (DegTyp.DegTypCod);
|
DT_RemoveDegreeTypeCompletely (DegTyp.DegTypCod);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Type_of_degree_X_removed,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Type_of_degree_X_removed,
|
||||||
DegTyp.DegTypName);
|
DegTyp.DegTypName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -946,7 +946,7 @@ void DT_RenameDegreeType (void)
|
||||||
|
|
||||||
/***** Check if new name is empty *****/
|
/***** Check if new name is empty *****/
|
||||||
if (!NewNameDegTyp[0])
|
if (!NewNameDegTyp[0])
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_can_not_leave_the_name_of_the_type_of_degree_X_empty,
|
Ale_ShowAlert (Ale_WARNING,Txt_You_can_not_leave_the_name_of_the_type_of_degree_X_empty,
|
||||||
DegTyp->DegTypName);
|
DegTyp->DegTypName);
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -956,7 +956,7 @@ void DT_RenameDegreeType (void)
|
||||||
{
|
{
|
||||||
/***** If degree type was in database... *****/
|
/***** If degree type was in database... *****/
|
||||||
if (DT_CheckIfDegreeTypeNameExists (NewNameDegTyp,DegTyp->DegTypCod))
|
if (DT_CheckIfDegreeTypeNameExists (NewNameDegTyp,DegTyp->DegTypCod))
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_type_of_degree_X_already_exists,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_type_of_degree_X_already_exists,
|
||||||
NewNameDegTyp);
|
NewNameDegTyp);
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -967,12 +967,12 @@ void DT_RenameDegreeType (void)
|
||||||
NewNameDegTyp,DegTyp->DegTypCod);
|
NewNameDegTyp,DegTyp->DegTypCod);
|
||||||
|
|
||||||
/* Write message to show the change made */
|
/* Write message to show the change made */
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_type_of_degree_X_has_been_renamed_as_Y,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_type_of_degree_X_has_been_renamed_as_Y,
|
||||||
DegTyp->DegTypName,NewNameDegTyp);
|
DegTyp->DegTypName,NewNameDegTyp);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else // The same name
|
else // The same name
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_The_name_of_the_type_of_degree_X_has_not_changed,
|
Ale_ShowAlert (Ale_INFO,Txt_The_name_of_the_type_of_degree_X_has_not_changed,
|
||||||
NewNameDegTyp);
|
NewNameDegTyp);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -613,7 +613,7 @@ void Dpt_RemoveDepartment (void)
|
||||||
|
|
||||||
/***** Check if this department has teachers *****/
|
/***** Check if this department has teachers *****/
|
||||||
if (Dpt.NumTchs) // Department has teachers ==> don't remove
|
if (Dpt.NumTchs) // Department has teachers ==> don't remove
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_To_remove_a_department_you_must_first_remove_all_teachers_in_the_department);
|
Ale_ShowAlert (Ale_WARNING,Txt_To_remove_a_department_you_must_first_remove_all_teachers_in_the_department);
|
||||||
else // Department has no teachers ==> remove it
|
else // Department has no teachers ==> remove it
|
||||||
{
|
{
|
||||||
/***** Remove department *****/
|
/***** Remove department *****/
|
||||||
|
@ -622,7 +622,7 @@ void Dpt_RemoveDepartment (void)
|
||||||
Dpt.DptCod);
|
Dpt.DptCod);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Department_X_removed,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Department_X_removed,
|
||||||
Dpt.FullName);
|
Dpt.FullName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -654,7 +654,7 @@ void Dpt_ChangeDepartIns (void)
|
||||||
Dpt->InsCod,Dpt->DptCod);
|
Dpt->InsCod,Dpt->DptCod);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_institution_of_the_department_has_changed);
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_institution_of_the_department_has_changed);
|
||||||
|
|
||||||
/***** Show the form again *****/
|
/***** Show the form again *****/
|
||||||
Dpt_EditDepartments ();
|
Dpt_EditDepartments ();
|
||||||
|
@ -724,7 +724,7 @@ static void Dpt_RenameDepartment (Cns_ShrtOrFullName_t ShrtOrFullName)
|
||||||
|
|
||||||
/***** Check if new name is empty *****/
|
/***** Check if new name is empty *****/
|
||||||
if (!NewDptName[0])
|
if (!NewDptName[0])
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_can_not_leave_the_name_of_the_department_X_empty,
|
Ale_ShowAlert (Ale_WARNING,Txt_You_can_not_leave_the_name_of_the_department_X_empty,
|
||||||
CurrentDptName);
|
CurrentDptName);
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -734,7 +734,7 @@ static void Dpt_RenameDepartment (Cns_ShrtOrFullName_t ShrtOrFullName)
|
||||||
{
|
{
|
||||||
/***** If degree was in database... *****/
|
/***** If degree was in database... *****/
|
||||||
if (Dpt_CheckIfDepartmentNameExists (ParamName,NewDptName,Dpt->DptCod))
|
if (Dpt_CheckIfDepartmentNameExists (ParamName,NewDptName,Dpt->DptCod))
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_department_X_already_exists,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_department_X_already_exists,
|
||||||
NewDptName);
|
NewDptName);
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -742,12 +742,12 @@ static void Dpt_RenameDepartment (Cns_ShrtOrFullName_t ShrtOrFullName)
|
||||||
Dpt_UpdateDegNameDB (Dpt->DptCod,FieldName,NewDptName);
|
Dpt_UpdateDegNameDB (Dpt->DptCod,FieldName,NewDptName);
|
||||||
|
|
||||||
/* Write message to show the change made */
|
/* Write message to show the change made */
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_department_X_has_been_renamed_as_Y,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_department_X_has_been_renamed_as_Y,
|
||||||
CurrentDptName,NewDptName);
|
CurrentDptName,NewDptName);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else // The same name
|
else // The same name
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_The_name_of_the_department_X_has_not_changed,
|
Ale_ShowAlert (Ale_INFO,Txt_The_name_of_the_department_X_has_not_changed,
|
||||||
CurrentDptName);
|
CurrentDptName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -812,11 +812,11 @@ void Dpt_ChangeDptWWW (void)
|
||||||
NewWWW,Dpt->DptCod);
|
NewWWW,Dpt->DptCod);
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_new_web_address_is_X,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_new_web_address_is_X,
|
||||||
NewWWW);
|
NewWWW);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_can_not_leave_the_web_address_empty);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_can_not_leave_the_web_address_empty);
|
||||||
|
|
||||||
/***** Show the form again *****/
|
/***** Show the form again *****/
|
||||||
Str_Copy (Dpt->WWW,NewWWW,
|
Str_Copy (Dpt->WWW,NewWWW,
|
||||||
|
@ -999,19 +999,19 @@ void Dpt_RecFormNewDpt (void)
|
||||||
{
|
{
|
||||||
/***** If name of department was in database... *****/
|
/***** If name of department was in database... *****/
|
||||||
if (Dpt_CheckIfDepartmentNameExists ("ShortName",Dpt->ShrtName,-1L))
|
if (Dpt_CheckIfDepartmentNameExists ("ShortName",Dpt->ShrtName,-1L))
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_department_X_already_exists,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_department_X_already_exists,
|
||||||
Dpt->ShrtName);
|
Dpt->ShrtName);
|
||||||
else if (Dpt_CheckIfDepartmentNameExists ("FullName",Dpt->FullName,-1L))
|
else if (Dpt_CheckIfDepartmentNameExists ("FullName",Dpt->FullName,-1L))
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_department_X_already_exists,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_department_X_already_exists,
|
||||||
Dpt->FullName);
|
Dpt->FullName);
|
||||||
else // Add new department to database
|
else // Add new department to database
|
||||||
Dpt_CreateDepartment (Dpt);
|
Dpt_CreateDepartment (Dpt);
|
||||||
}
|
}
|
||||||
else // If there is not a web
|
else // If there is not a web
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_must_specify_the_web_address_of_the_new_department);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_must_specify_the_web_address_of_the_new_department);
|
||||||
}
|
}
|
||||||
else // If there is not a department name
|
else // If there is not a department name
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_must_specify_the_short_name_and_the_full_name_of_the_new_department);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_must_specify_the_short_name_and_the_full_name_of_the_new_department);
|
||||||
|
|
||||||
/***** Show the form again *****/
|
/***** Show the form again *****/
|
||||||
Dpt_EditDepartments ();
|
Dpt_EditDepartments ();
|
||||||
|
@ -1034,7 +1034,7 @@ static void Dpt_CreateDepartment (struct Department *Dpt)
|
||||||
Dpt->InsCod,Dpt->ShrtName,Dpt->FullName,Dpt->WWW);
|
Dpt->InsCod,Dpt->ShrtName,Dpt->FullName,Dpt->WWW);
|
||||||
|
|
||||||
/***** Write success message *****/
|
/***** Write success message *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Created_new_department_X,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Created_new_department_X,
|
||||||
Dpt->FullName);
|
Dpt->FullName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -102,13 +102,13 @@ void Dup_ReportUsrAsPossibleDuplicate (void)
|
||||||
Gbl.Usrs.Me.UsrDat.UsrCod);
|
Gbl.Usrs.Me.UsrDat.UsrCod);
|
||||||
|
|
||||||
/***** Show feedback message *****/
|
/***** Show feedback message *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Thank_you_for_reporting_a_possible_duplicate_user);
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Thank_you_for_reporting_a_possible_duplicate_user);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
@ -250,7 +250,7 @@ void Dup_GetUsrCodAndListSimilarUsrs (void)
|
||||||
if (Usr_GetParamOtherUsrCodEncryptedAndGetUsrData ())
|
if (Usr_GetParamOtherUsrCodEncryptedAndGetUsrData ())
|
||||||
Dup_ListSimilarUsrs ();
|
Dup_ListSimilarUsrs ();
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void Dup_ListSimilarUsrs (void)
|
static void Dup_ListSimilarUsrs (void)
|
||||||
|
@ -459,7 +459,7 @@ void Dup_RemoveUsrFromListDupUsrs (void)
|
||||||
Dup_ListDuplicateUsrs ();
|
Dup_ListDuplicateUsrs ();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
112
swad_enrolment.c
112
swad_enrolment.c
|
@ -394,7 +394,7 @@ void Enr_ReqAcceptRegisterInCrs (void)
|
||||||
Hlp_USERS_SignUp_confirm_enrolment,Box_NOT_CLOSABLE);
|
Hlp_USERS_SignUp_confirm_enrolment,Box_NOT_CLOSABLE);
|
||||||
|
|
||||||
/***** Show message *****/
|
/***** Show message *****/
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_A_teacher_or_administrator_has_enroled_you_as_X_into_the_course_Y,
|
Ale_ShowAlert (Ale_INFO,Txt_A_teacher_or_administrator_has_enroled_you_as_X_into_the_course_Y,
|
||||||
Txt_ROLES_SINGUL_abc[Gbl.Usrs.Me.UsrDat.Roles.InCurrentCrs.Role][Gbl.Usrs.Me.UsrDat.Sex],
|
Txt_ROLES_SINGUL_abc[Gbl.Usrs.Me.UsrDat.Roles.InCurrentCrs.Role][Gbl.Usrs.Me.UsrDat.Sex],
|
||||||
Gbl.CurrentCrs.Crs.FullName);
|
Gbl.CurrentCrs.Crs.FullName);
|
||||||
|
|
||||||
|
@ -625,7 +625,7 @@ static void Enr_ReqAdminUsrs (Rol_Role_t Role)
|
||||||
Enr_ReqAnotherUsrIDToRegisterRemove (Role);
|
Enr_ReqAnotherUsrIDToRegisterRemove (Role);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
Ale_ShowA_fmt (Ale_ERROR,Txt_You_dont_have_permission_to_perform_this_action);
|
Ale_ShowAlert (Ale_ERROR,Txt_You_dont_have_permission_to_perform_this_action);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -719,7 +719,7 @@ static void Enr_ShowFormRegRemSeveralUsrs (Rol_Role_t Role)
|
||||||
The_ClassTitle[Gbl.Prefs.Theme],
|
The_ClassTitle[Gbl.Prefs.Theme],
|
||||||
Txt_Step_1_Provide_a_list_of_users);
|
Txt_Step_1_Provide_a_list_of_users);
|
||||||
|
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_Type_or_paste_a_list_of_IDs_nicks_or_emails_);
|
Ale_ShowAlert (Ale_INFO,Txt_Type_or_paste_a_list_of_IDs_nicks_or_emails_);
|
||||||
Enr_PutAreaToEnterUsrsIDs ();
|
Enr_PutAreaToEnterUsrsIDs ();
|
||||||
|
|
||||||
/***** Step 2: Put different actions to register/remove users to/from current course *****/
|
/***** Step 2: Put different actions to register/remove users to/from current course *****/
|
||||||
|
@ -740,12 +740,12 @@ static void Enr_ShowFormRegRemSeveralUsrs (Rol_Role_t Role)
|
||||||
{
|
{
|
||||||
if (Gbl.CurrentCrs.Grps.NumGrps) // This course has groups?
|
if (Gbl.CurrentCrs.Grps.NumGrps) // This course has groups?
|
||||||
{
|
{
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_Select_the_groups_in_from_which_you_want_to_register_remove_users_);
|
Ale_ShowAlert (Ale_INFO,Txt_Select_the_groups_in_from_which_you_want_to_register_remove_users_);
|
||||||
Grp_ShowLstGrpsToChgOtherUsrsGrps (-1L);
|
Grp_ShowLstGrpsToChgOtherUsrsGrps (-1L);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
/* Write help message */
|
/* Write help message */
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_No_groups_have_been_created_in_the_course_X_Therefore_,
|
Ale_ShowAlert (Ale_INFO,Txt_No_groups_have_been_created_in_the_course_X_Therefore_,
|
||||||
Gbl.CurrentCrs.Crs.FullName);
|
Gbl.CurrentCrs.Crs.FullName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -865,7 +865,7 @@ void Enr_RemoveOldUsrs (void)
|
||||||
(unsigned long) SecondsWithoutAccess);
|
(unsigned long) SecondsWithoutAccess);
|
||||||
if (NumUsrs)
|
if (NumUsrs)
|
||||||
{
|
{
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_Eliminating_X_users_who_were_not_enroled_in_any_course_and_with_more_than_Y_months_without_access_to_Z,
|
Ale_ShowAlert (Ale_INFO,Txt_Eliminating_X_users_who_were_not_enroled_in_any_course_and_with_more_than_Y_months_without_access_to_Z,
|
||||||
NumUsrs,
|
NumUsrs,
|
||||||
MonthsWithoutAccess,
|
MonthsWithoutAccess,
|
||||||
Cfg_PLATFORM_SHORT_NAME);
|
Cfg_PLATFORM_SHORT_NAME);
|
||||||
|
@ -898,7 +898,7 @@ void Enr_RemoveOldUsrs (void)
|
||||||
}
|
}
|
||||||
|
|
||||||
/***** Write end message *****/
|
/***** Write end message *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_X_users_have_been_eliminated,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_X_users_have_been_eliminated,
|
||||||
NumUsrsEliminated);
|
NumUsrsEliminated);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1499,7 +1499,7 @@ static void Enr_ReceiveFormUsrsCrs (Rol_Role_t Role)
|
||||||
if (!Grp_CheckIfSelectionGrpsSingleEnrolmentIsValid (Role,&LstGrps))
|
if (!Grp_CheckIfSelectionGrpsSingleEnrolmentIsValid (Role,&LstGrps))
|
||||||
{
|
{
|
||||||
/* Show warning message and exit */
|
/* Show warning message and exit */
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_In_a_type_of_group_with_single_enrolment_students_can_not_be_registered_in_more_than_one_group);
|
Ale_ShowAlert (Ale_WARNING,Txt_In_a_type_of_group_with_single_enrolment_students_can_not_be_registered_in_more_than_one_group);
|
||||||
|
|
||||||
/* Free memory used by lists of groups and abort */
|
/* Free memory used by lists of groups and abort */
|
||||||
Grp_FreeListCodGrp (&LstGrps);
|
Grp_FreeListCodGrp (&LstGrps);
|
||||||
|
@ -1736,13 +1736,13 @@ static void Enr_ReceiveFormUsrsCrs (Rol_Role_t Role)
|
||||||
switch (NumUsrsEliminated)
|
switch (NumUsrsEliminated)
|
||||||
{
|
{
|
||||||
case 0:
|
case 0:
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_No_user_has_been_eliminated);
|
Ale_ShowAlert (Ale_INFO,Txt_No_user_has_been_eliminated);
|
||||||
break;
|
break;
|
||||||
case 1:
|
case 1:
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_One_user_has_been_eliminated);
|
Ale_ShowAlert (Ale_SUCCESS,Txt_One_user_has_been_eliminated);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_X_users_have_been_eliminated,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_X_users_have_been_eliminated,
|
||||||
NumUsrsEliminated);
|
NumUsrsEliminated);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -1750,13 +1750,13 @@ static void Enr_ReceiveFormUsrsCrs (Rol_Role_t Role)
|
||||||
switch (NumUsrsRemoved)
|
switch (NumUsrsRemoved)
|
||||||
{
|
{
|
||||||
case 0:
|
case 0:
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_No_user_has_been_removed);
|
Ale_ShowAlert (Ale_INFO,Txt_No_user_has_been_removed);
|
||||||
break;
|
break;
|
||||||
case 1:
|
case 1:
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_One_user_has_been_removed);
|
Ale_ShowAlert (Ale_SUCCESS,Txt_One_user_has_been_removed);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_X_users_have_been_removed,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_X_users_have_been_removed,
|
||||||
NumUsrsRemoved);
|
NumUsrsRemoved);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -1765,13 +1765,13 @@ static void Enr_ReceiveFormUsrsCrs (Rol_Role_t Role)
|
||||||
switch (NumUsrsRegistered)
|
switch (NumUsrsRegistered)
|
||||||
{
|
{
|
||||||
case 0:
|
case 0:
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_No_user_has_been_enroled);
|
Ale_ShowAlert (Ale_INFO,Txt_No_user_has_been_enroled);
|
||||||
break;
|
break;
|
||||||
case 1:
|
case 1:
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_One_user_has_been_enroled);
|
Ale_ShowAlert (Ale_SUCCESS,Txt_One_user_has_been_enroled);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_X_users_have_been_enroled_including_possible_repetitions,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_X_users_have_been_enroled_including_possible_repetitions,
|
||||||
NumUsrsRegistered);
|
NumUsrsRegistered);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -1903,7 +1903,7 @@ void Enr_RemAllStdsThisCrs (void)
|
||||||
if (Pwd_GetConfirmationOnDangerousAction ())
|
if (Pwd_GetConfirmationOnDangerousAction ())
|
||||||
{
|
{
|
||||||
if ((NumStdsInCrs = Enr_RemAllStdsInCrs (&Gbl.CurrentCrs.Crs)))
|
if ((NumStdsInCrs = Enr_RemAllStdsInCrs (&Gbl.CurrentCrs.Crs)))
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_X_students_who_belonged_to_the_course_Y_have_been_removed_from_it,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_X_students_who_belonged_to_the_course_Y_have_been_removed_from_it,
|
||||||
NumStdsInCrs,Gbl.CurrentCrs.Crs.FullName);
|
NumStdsInCrs,Gbl.CurrentCrs.Crs.FullName);
|
||||||
else // NumStdsInCrs == 0
|
else // NumStdsInCrs == 0
|
||||||
/***** Show warning indicating no students found *****/
|
/***** Show warning indicating no students found *****/
|
||||||
|
@ -1953,7 +1953,7 @@ void Enr_ReqSignUpInCrs (void)
|
||||||
|
|
||||||
/***** Check if I already belong to course *****/
|
/***** Check if I already belong to course *****/
|
||||||
if (Gbl.Usrs.Me.UsrDat.Roles.InCurrentCrs.Role >= Rol_STD)
|
if (Gbl.Usrs.Me.UsrDat.Roles.InCurrentCrs.Role >= Rol_STD)
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_were_already_enroled_as_X_in_the_course_Y,
|
Ale_ShowAlert (Ale_WARNING,Txt_You_were_already_enroled_as_X_in_the_course_Y,
|
||||||
Txt_ROLES_SINGUL_abc[Gbl.Usrs.Me.UsrDat.Roles.InCurrentCrs.Role][Gbl.Usrs.Me.UsrDat.Sex],
|
Txt_ROLES_SINGUL_abc[Gbl.Usrs.Me.UsrDat.Roles.InCurrentCrs.Role][Gbl.Usrs.Me.UsrDat.Sex],
|
||||||
Gbl.CurrentCrs.Crs.FullName);
|
Gbl.CurrentCrs.Crs.FullName);
|
||||||
else if (Gbl.Usrs.Me.Role.Logged == Rol_GST ||
|
else if (Gbl.Usrs.Me.Role.Logged == Rol_GST ||
|
||||||
|
@ -1980,7 +1980,7 @@ void Enr_SignUpInCrs (void)
|
||||||
|
|
||||||
/***** Check if I already belong to course *****/
|
/***** Check if I already belong to course *****/
|
||||||
if (Gbl.Usrs.Me.UsrDat.Roles.InCurrentCrs.Role >= Rol_STD)
|
if (Gbl.Usrs.Me.UsrDat.Roles.InCurrentCrs.Role >= Rol_STD)
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_were_already_enroled_as_X_in_the_course_Y,
|
Ale_ShowAlert (Ale_WARNING,Txt_You_were_already_enroled_as_X_in_the_course_Y,
|
||||||
Txt_ROLES_SINGUL_abc[Gbl.Usrs.Me.UsrDat.Roles.InCurrentCrs.Role][Gbl.Usrs.Me.UsrDat.Sex],
|
Txt_ROLES_SINGUL_abc[Gbl.Usrs.Me.UsrDat.Roles.InCurrentCrs.Role][Gbl.Usrs.Me.UsrDat.Sex],
|
||||||
Gbl.CurrentCrs.Crs.FullName);
|
Gbl.CurrentCrs.Crs.FullName);
|
||||||
else
|
else
|
||||||
|
@ -2033,7 +2033,7 @@ void Enr_SignUpInCrs (void)
|
||||||
(unsigned) RoleFromForm);
|
(unsigned) RoleFromForm);
|
||||||
|
|
||||||
/***** Show confirmation message *****/
|
/***** Show confirmation message *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Your_request_for_enrolment_as_X_in_the_course_Y_has_been_accepted_for_processing,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Your_request_for_enrolment_as_X_in_the_course_Y_has_been_accepted_for_processing,
|
||||||
Txt_ROLES_SINGUL_abc[RoleFromForm][Gbl.Usrs.Me.UsrDat.Sex],
|
Txt_ROLES_SINGUL_abc[RoleFromForm][Gbl.Usrs.Me.UsrDat.Sex],
|
||||||
Gbl.CurrentCrs.Crs.FullName);
|
Gbl.CurrentCrs.Crs.FullName);
|
||||||
|
|
||||||
|
@ -2122,7 +2122,7 @@ void Enr_AskIfRejectSignUp (void)
|
||||||
if (Usr_CheckIfUsrBelongsToCurrentCrs (&Gbl.Usrs.Other.UsrDat))
|
if (Usr_CheckIfUsrBelongsToCurrentCrs (&Gbl.Usrs.Other.UsrDat))
|
||||||
{
|
{
|
||||||
/* User already belongs to this course */
|
/* User already belongs to this course */
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_THE_USER_X_is_already_enroled_in_the_course_Y,
|
Ale_ShowAlert (Ale_WARNING,Txt_THE_USER_X_is_already_enroled_in_the_course_Y,
|
||||||
Gbl.Usrs.Other.UsrDat.FullName,Gbl.CurrentCrs.Crs.FullName);
|
Gbl.Usrs.Other.UsrDat.FullName,Gbl.CurrentCrs.Crs.FullName);
|
||||||
Rec_ShowSharedRecordUnmodifiable (&Gbl.Usrs.Other.UsrDat);
|
Rec_ShowSharedRecordUnmodifiable (&Gbl.Usrs.Other.UsrDat);
|
||||||
|
|
||||||
|
@ -2158,7 +2158,7 @@ void Enr_AskIfRejectSignUp (void)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
@ -2179,7 +2179,7 @@ void Enr_RejectSignUp (void)
|
||||||
if (Usr_CheckIfUsrBelongsToCurrentCrs (&Gbl.Usrs.Other.UsrDat))
|
if (Usr_CheckIfUsrBelongsToCurrentCrs (&Gbl.Usrs.Other.UsrDat))
|
||||||
{
|
{
|
||||||
/* User already belongs to this course */
|
/* User already belongs to this course */
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_THE_USER_X_is_already_enroled_in_the_course_Y,
|
Ale_ShowAlert (Ale_WARNING,Txt_THE_USER_X_is_already_enroled_in_the_course_Y,
|
||||||
Gbl.Usrs.Other.UsrDat.FullName,Gbl.CurrentCrs.Crs.FullName);
|
Gbl.Usrs.Other.UsrDat.FullName,Gbl.CurrentCrs.Crs.FullName);
|
||||||
Rec_ShowSharedRecordUnmodifiable (&Gbl.Usrs.Other.UsrDat);
|
Rec_ShowSharedRecordUnmodifiable (&Gbl.Usrs.Other.UsrDat);
|
||||||
}
|
}
|
||||||
|
@ -2188,11 +2188,11 @@ void Enr_RejectSignUp (void)
|
||||||
Enr_RemoveEnrolmentRequest (Gbl.CurrentCrs.Crs.CrsCod,Gbl.Usrs.Other.UsrDat.UsrCod);
|
Enr_RemoveEnrolmentRequest (Gbl.CurrentCrs.Crs.CrsCod,Gbl.Usrs.Other.UsrDat.UsrCod);
|
||||||
|
|
||||||
/* Confirmation message */
|
/* Confirmation message */
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Enrolment_of_X_rejected,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Enrolment_of_X_rejected,
|
||||||
Gbl.Usrs.Other.UsrDat.FullName);
|
Gbl.Usrs.Other.UsrDat.FullName);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
|
|
||||||
/* Show again the rest of registrarion requests */
|
/* Show again the rest of registrarion requests */
|
||||||
Enr_ShowEnrolmentRequests ();
|
Enr_ShowEnrolmentRequests ();
|
||||||
|
@ -2972,7 +2972,7 @@ static void Enr_ShowEnrolmentRequestsGivenRoles (unsigned RolesSelected)
|
||||||
Usr_UsrDataDestructor (&UsrDat);
|
Usr_UsrDataDestructor (&UsrDat);
|
||||||
}
|
}
|
||||||
else // There are no requests
|
else // There are no requests
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_No_enrolment_requests);
|
Ale_ShowAlert (Ale_INFO,Txt_No_enrolment_requests);
|
||||||
|
|
||||||
/***** End box *****/
|
/***** End box *****/
|
||||||
Box_EndBox ();
|
Box_EndBox ();
|
||||||
|
@ -3251,7 +3251,7 @@ static void Enr_AskIfRegRemUsr (struct ListUsrCods *ListUsrCods,Rol_Role_t Role)
|
||||||
{
|
{
|
||||||
/***** Warning if more than one user found *****/
|
/***** Warning if more than one user found *****/
|
||||||
if (ListUsrCods->NumUsrs > 1)
|
if (ListUsrCods->NumUsrs > 1)
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_There_are_X_users_with_the_ID_Y,
|
Ale_ShowAlert (Ale_INFO,Txt_There_are_X_users_with_the_ID_Y,
|
||||||
ListUsrCods->NumUsrs,Gbl.Usrs.Other.UsrDat.UsrIDNickOrEmail);
|
ListUsrCods->NumUsrs,Gbl.Usrs.Other.UsrDat.UsrIDNickOrEmail);
|
||||||
|
|
||||||
/***** For each user found... *****/
|
/***** For each user found... *****/
|
||||||
|
@ -3270,17 +3270,17 @@ static void Enr_AskIfRegRemUsr (struct ListUsrCods *ListUsrCods,Rol_Role_t Role)
|
||||||
{
|
{
|
||||||
Gbl.Usrs.Other.UsrDat.Accepted = Usr_CheckIfUsrHasAcceptedInCurrentCrs (&Gbl.Usrs.Other.UsrDat);
|
Gbl.Usrs.Other.UsrDat.Accepted = Usr_CheckIfUsrHasAcceptedInCurrentCrs (&Gbl.Usrs.Other.UsrDat);
|
||||||
if (Gbl.Usrs.Other.UsrDat.Accepted)
|
if (Gbl.Usrs.Other.UsrDat.Accepted)
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_THE_USER_X_is_already_enroled_in_the_course_Y,
|
Ale_ShowAlert (Ale_INFO,Txt_THE_USER_X_is_already_enroled_in_the_course_Y,
|
||||||
Gbl.Usrs.Other.UsrDat.FullName,Gbl.CurrentCrs.Crs.FullName);
|
Gbl.Usrs.Other.UsrDat.FullName,Gbl.CurrentCrs.Crs.FullName);
|
||||||
else // Enrolment not yet accepted
|
else // Enrolment not yet accepted
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_THE_USER_X_is_already_in_the_course_Y_but_has_not_yet_accepted_the_enrolment,
|
Ale_ShowAlert (Ale_INFO,Txt_THE_USER_X_is_already_in_the_course_Y_but_has_not_yet_accepted_the_enrolment,
|
||||||
Gbl.Usrs.Other.UsrDat.FullName,Gbl.CurrentCrs.Crs.FullName);
|
Gbl.Usrs.Other.UsrDat.FullName,Gbl.CurrentCrs.Crs.FullName);
|
||||||
|
|
||||||
Enr_ShowFormToEditOtherUsr ();
|
Enr_ShowFormToEditOtherUsr ();
|
||||||
}
|
}
|
||||||
else // User does not belong to the current course
|
else // User does not belong to the current course
|
||||||
{
|
{
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_THE_USER_X_already_exists_in_Y_but_is_not_yet_enroled_in_the_course_Z,
|
Ale_ShowAlert (Ale_INFO,Txt_THE_USER_X_already_exists_in_Y_but_is_not_yet_enroled_in_the_course_Z,
|
||||||
Gbl.Usrs.Other.UsrDat.FullName,
|
Gbl.Usrs.Other.UsrDat.FullName,
|
||||||
Cfg_PLATFORM_SHORT_NAME,Gbl.CurrentCrs.Crs.FullName);
|
Cfg_PLATFORM_SHORT_NAME,Gbl.CurrentCrs.Crs.FullName);
|
||||||
|
|
||||||
|
@ -3289,7 +3289,7 @@ static void Enr_AskIfRegRemUsr (struct ListUsrCods *ListUsrCods,Rol_Role_t Role)
|
||||||
}
|
}
|
||||||
else // No course selected
|
else // No course selected
|
||||||
{
|
{
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_THE_USER_X_already_exists_in_Y,
|
Ale_ShowAlert (Ale_INFO,Txt_THE_USER_X_already_exists_in_Y,
|
||||||
Gbl.Usrs.Other.UsrDat.FullName,Cfg_PLATFORM_SHORT_NAME);
|
Gbl.Usrs.Other.UsrDat.FullName,Cfg_PLATFORM_SHORT_NAME);
|
||||||
|
|
||||||
Enr_ShowFormToEditOtherUsr ();
|
Enr_ShowFormToEditOtherUsr ();
|
||||||
|
@ -3311,14 +3311,14 @@ static void Enr_AskIfRegRemUsr (struct ListUsrCods *ListUsrCods,Rol_Role_t Role)
|
||||||
if (NewUsrIDValid)
|
if (NewUsrIDValid)
|
||||||
{
|
{
|
||||||
/***** Show form to enter the data of a new user *****/
|
/***** Show form to enter the data of a new user *****/
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_The_user_is_new_not_yet_in_X,
|
Ale_ShowAlert (Ale_INFO,Txt_The_user_is_new_not_yet_in_X,
|
||||||
Cfg_PLATFORM_SHORT_NAME);
|
Cfg_PLATFORM_SHORT_NAME);
|
||||||
Rec_ShowFormOtherNewSharedRecord (&Gbl.Usrs.Other.UsrDat,Role);
|
Rec_ShowFormOtherNewSharedRecord (&Gbl.Usrs.Other.UsrDat,Role);
|
||||||
}
|
}
|
||||||
else // User's ID is not valid
|
else // User's ID is not valid
|
||||||
{
|
{
|
||||||
/* Write message and request a new user's ID */
|
/* Write message and request a new user's ID */
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_If_this_is_a_new_user_in_X_you_should_indicate_her_his_ID,
|
Ale_ShowAlert (Ale_WARNING,Txt_If_this_is_a_new_user_in_X_you_should_indicate_her_his_ID,
|
||||||
Cfg_PLATFORM_SHORT_NAME);
|
Cfg_PLATFORM_SHORT_NAME);
|
||||||
Enr_ReqRegRemUsr (Role);
|
Enr_ReqRegRemUsr (Role);
|
||||||
}
|
}
|
||||||
|
@ -3391,10 +3391,10 @@ static void Enr_AddAdm (Sco_Scope_t Scope,long Cod,const char *InsCtrDegName)
|
||||||
Rec_ShowSharedRecordUnmodifiable (&Gbl.Usrs.Other.UsrDat);
|
Rec_ShowSharedRecordUnmodifiable (&Gbl.Usrs.Other.UsrDat);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -3410,7 +3410,7 @@ static void Enr_RegisterAdmin (struct UsrData *UsrDat,Sco_Scope_t Scope,long Cod
|
||||||
|
|
||||||
/***** Check if user was and administrator of current institution/centre/degree *****/
|
/***** Check if user was and administrator of current institution/centre/degree *****/
|
||||||
if (Usr_CheckIfUsrIsAdm (UsrDat->UsrCod,Scope,Cod))
|
if (Usr_CheckIfUsrIsAdm (UsrDat->UsrCod,Scope,Cod))
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_THE_USER_X_is_already_an_administrator_of_Y,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_THE_USER_X_is_already_an_administrator_of_Y,
|
||||||
UsrDat->FullName,InsCtrDegName);
|
UsrDat->FullName,InsCtrDegName);
|
||||||
else // User was not administrator of current institution/centre/degree
|
else // User was not administrator of current institution/centre/degree
|
||||||
{
|
{
|
||||||
|
@ -3422,7 +3422,7 @@ static void Enr_RegisterAdmin (struct UsrData *UsrDat,Sco_Scope_t Scope,long Cod
|
||||||
" (%ld,'%s',%ld)",
|
" (%ld,'%s',%ld)",
|
||||||
UsrDat->UsrCod,Sco_ScopeDB[Scope],Cod);
|
UsrDat->UsrCod,Sco_ScopeDB[Scope],Cod);
|
||||||
|
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_THE_USER_X_has_been_enroled_as_administrator_of_Y,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_THE_USER_X_has_been_enroled_as_administrator_of_Y,
|
||||||
UsrDat->FullName,InsCtrDegName);
|
UsrDat->FullName,InsCtrDegName);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -3450,10 +3450,10 @@ void Enr_ReqRemUsrFromCrs (void)
|
||||||
if (Enr_CheckIfICanRemUsrFromCrs ())
|
if (Enr_CheckIfICanRemUsrFromCrs ())
|
||||||
Enr_AskIfRemoveUsrFromCrs (&Gbl.Usrs.Other.UsrDat);
|
Enr_AskIfRemoveUsrFromCrs (&Gbl.Usrs.Other.UsrDat);
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
@ -3474,15 +3474,15 @@ void Enr_RemUsrFromCrs1 (void)
|
||||||
Enr_REMOVE_WORKS,Cns_VERBOSE);
|
Enr_REMOVE_WORKS,Cns_VERBOSE);
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
Gbl.AlertToShowLater.Type = Ale_WARNING;
|
Gbl.DelayedAlert.Type = Ale_WARNING;
|
||||||
Str_Copy (Gbl.AlertToShowLater.Txt,Txt_User_not_found_or_you_do_not_have_permission_,
|
Str_Copy (Gbl.DelayedAlert.Txt,Txt_User_not_found_or_you_do_not_have_permission_,
|
||||||
Ale_MAX_BYTES_ALERT);
|
Ale_MAX_BYTES_ALERT);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
Gbl.AlertToShowLater.Type = Ale_WARNING;
|
Gbl.DelayedAlert.Type = Ale_WARNING;
|
||||||
Str_Copy (Gbl.AlertToShowLater.Txt,Txt_User_not_found_or_you_do_not_have_permission_,
|
Str_Copy (Gbl.DelayedAlert.Txt,Txt_User_not_found_or_you_do_not_have_permission_,
|
||||||
Ale_MAX_BYTES_ALERT);
|
Ale_MAX_BYTES_ALERT);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -3490,7 +3490,7 @@ void Enr_RemUsrFromCrs1 (void)
|
||||||
|
|
||||||
void Enr_RemUsrFromCrs2 (void)
|
void Enr_RemUsrFromCrs2 (void)
|
||||||
{
|
{
|
||||||
Ale_ShowA_new (Gbl.AlertToShowLater.Type,Gbl.AlertToShowLater.Txt);
|
Ale_ShowDelayedAlert (Gbl.DelayedAlert.Type,Gbl.DelayedAlert.Txt);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
@ -3620,14 +3620,14 @@ static void Enr_ReqRemOrRemAdm (Enr_ReqDelOrDelUsr_t ReqDelOrDelUsr,Sco_Scope_t
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else // The other user is not an administrator of current institution
|
else // The other user is not an administrator of current institution
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_THE_USER_X_is_not_an_administrator_of_Y,
|
Ale_ShowAlert (Ale_WARNING,Txt_THE_USER_X_is_not_an_administrator_of_Y,
|
||||||
Gbl.Usrs.Other.UsrDat.FullName,InsCtrDegName);
|
Gbl.Usrs.Other.UsrDat.FullName,InsCtrDegName);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -3666,7 +3666,7 @@ static void Enr_ReqAddAdm (Sco_Scope_t Scope,long Cod,const char *InsCtrDegName)
|
||||||
{
|
{
|
||||||
if (Usr_CheckIfUsrIsAdm (Gbl.Usrs.Other.UsrDat.UsrCod,Scope,Cod)) // User is already an administrator of current institution/centre/degree
|
if (Usr_CheckIfUsrIsAdm (Gbl.Usrs.Other.UsrDat.UsrCod,Scope,Cod)) // User is already an administrator of current institution/centre/degree
|
||||||
{
|
{
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_THE_USER_X_is_already_an_administrator_of_Y,
|
Ale_ShowAlert (Ale_INFO,Txt_THE_USER_X_is_already_an_administrator_of_Y,
|
||||||
Gbl.Usrs.Other.UsrDat.FullName,InsCtrDegName);
|
Gbl.Usrs.Other.UsrDat.FullName,InsCtrDegName);
|
||||||
Rec_ShowSharedRecordUnmodifiable (&Gbl.Usrs.Other.UsrDat);
|
Rec_ShowSharedRecordUnmodifiable (&Gbl.Usrs.Other.UsrDat);
|
||||||
}
|
}
|
||||||
|
@ -3689,10 +3689,10 @@ static void Enr_ReqAddAdm (Sco_Scope_t Scope,long Cod,const char *InsCtrDegName)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -3715,7 +3715,7 @@ void Enr_AcceptRegisterMeInCrs (void)
|
||||||
Gbl.Usrs.Me.UsrDat.UsrCod);
|
Gbl.Usrs.Me.UsrDat.UsrCod);
|
||||||
|
|
||||||
/***** Confirmation message *****/
|
/***** Confirmation message *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_You_have_confirmed_your_enrolment_in_the_course_X,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_You_have_confirmed_your_enrolment_in_the_course_X,
|
||||||
Gbl.CurrentCrs.Crs.FullName);
|
Gbl.CurrentCrs.Crs.FullName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -4008,7 +4008,7 @@ void Enr_ModifyUsr2 (void)
|
||||||
extern const char *Txt_User_not_found_or_you_do_not_have_permission_;
|
extern const char *Txt_User_not_found_or_you_do_not_have_permission_;
|
||||||
|
|
||||||
if (Gbl.Alert.Type == Ale_WARNING)
|
if (Gbl.Alert.Type == Ale_WARNING)
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
else // No error
|
else // No error
|
||||||
switch (Gbl.Usrs.RegRemAction)
|
switch (Gbl.Usrs.RegRemAction)
|
||||||
{
|
{
|
||||||
|
@ -4125,7 +4125,7 @@ static void Enr_AskIfRemoveUsrFromCrs (struct UsrData *UsrDat)
|
||||||
Ale_ShowAlertAndButton2 (ActUnk,NULL,NULL,NULL,Btn_NO_BUTTON,NULL);
|
Ale_ShowAlertAndButton2 (ActUnk,NULL,NULL,NULL,Btn_NO_BUTTON,NULL);
|
||||||
}
|
}
|
||||||
else // User does not belong to current course
|
else // User does not belong to current course
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
@ -4285,10 +4285,10 @@ static void Enr_EffectivelyRemAdm (struct UsrData *UsrDat,Sco_Scope_t Scope,
|
||||||
" WHERE UsrCod=%ld AND Scope='%s' AND Cod=%ld",
|
" WHERE UsrCod=%ld AND Scope='%s' AND Cod=%ld",
|
||||||
UsrDat->UsrCod,Sco_ScopeDB[Scope],Cod);
|
UsrDat->UsrCod,Sco_ScopeDB[Scope],Cod);
|
||||||
|
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_THE_USER_X_has_been_removed_as_administrator_of_Y,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_THE_USER_X_has_been_removed_as_administrator_of_Y,
|
||||||
UsrDat->FullName,InsCtrDegName);
|
UsrDat->FullName,InsCtrDegName);
|
||||||
}
|
}
|
||||||
else // User is not an administrator of the current institution/centre/degree
|
else // User is not an administrator of the current institution/centre/degree
|
||||||
Ale_ShowA_fmt (Ale_ERROR,Txt_THE_USER_X_is_not_an_administrator_of_Y,
|
Ale_ShowAlert (Ale_ERROR,Txt_THE_USER_X_is_not_an_administrator_of_Y,
|
||||||
UsrDat->FullName,InsCtrDegName);
|
UsrDat->FullName,InsCtrDegName);
|
||||||
}
|
}
|
||||||
|
|
10
swad_exam.c
10
swad_exam.c
|
@ -295,7 +295,7 @@ void Exa_ReceiveExamAnnouncement2 (void)
|
||||||
struct SocialPublishing SocPub;
|
struct SocialPublishing SocPub;
|
||||||
|
|
||||||
/***** Show message *****/
|
/***** Show message *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,
|
Ale_ShowAlert (Ale_SUCCESS,
|
||||||
Gbl.ExamAnns.NewExamAnnouncement ? Txt_Created_new_announcement_of_exam :
|
Gbl.ExamAnns.NewExamAnnouncement ? Txt_Created_new_announcement_of_exam :
|
||||||
Txt_The_announcement_of_exam_has_been_successfully_updated);
|
Txt_The_announcement_of_exam_has_been_successfully_updated);
|
||||||
|
|
||||||
|
@ -414,7 +414,7 @@ void Exa_RemoveExamAnnouncement2 (void)
|
||||||
extern const char *Txt_Announcement_of_exam_removed;
|
extern const char *Txt_Announcement_of_exam_removed;
|
||||||
|
|
||||||
/***** Write message *****/
|
/***** Write message *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Announcement_of_exam_removed);
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Announcement_of_exam_removed);
|
||||||
|
|
||||||
/***** List again all the remaining exam announcements *****/
|
/***** List again all the remaining exam announcements *****/
|
||||||
Exa_ListExamAnnouncementsEdit ();
|
Exa_ListExamAnnouncementsEdit ();
|
||||||
|
@ -447,7 +447,7 @@ void Exa_HideExamAnnouncement2 (void)
|
||||||
extern const char *Txt_The_announcement_of_exam_is_now_hidden;
|
extern const char *Txt_The_announcement_of_exam_is_now_hidden;
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_announcement_of_exam_is_now_hidden);
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_announcement_of_exam_is_now_hidden);
|
||||||
|
|
||||||
/***** Show exam announcements again *****/
|
/***** Show exam announcements again *****/
|
||||||
Exa_ListExamAnnouncementsEdit ();
|
Exa_ListExamAnnouncementsEdit ();
|
||||||
|
@ -480,7 +480,7 @@ void Exa_UnhideExamAnnouncement2 (void)
|
||||||
extern const char *Txt_The_announcement_of_exam_is_now_visible;
|
extern const char *Txt_The_announcement_of_exam_is_now_visible;
|
||||||
|
|
||||||
/***** Write message to show the change made *****/
|
/***** Write message to show the change made *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_announcement_of_exam_is_now_visible);
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_announcement_of_exam_is_now_visible);
|
||||||
|
|
||||||
/***** Show exam announcements again *****/
|
/***** Show exam announcements again *****/
|
||||||
Exa_ListExamAnnouncementsEdit ();
|
Exa_ListExamAnnouncementsEdit ();
|
||||||
|
@ -657,7 +657,7 @@ static void Exa_ListExamAnnouncements (Exa_TypeViewExamAnnouncement_t TypeViewEx
|
||||||
|
|
||||||
/***** The result of the query may be empty *****/
|
/***** The result of the query may be empty *****/
|
||||||
if (!NumExaAnns)
|
if (!NumExaAnns)
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_No_announcements_of_exams_of_X,
|
Ale_ShowAlert (Ale_INFO,Txt_No_announcements_of_exams_of_X,
|
||||||
Gbl.CurrentCrs.Crs.FullName);
|
Gbl.CurrentCrs.Crs.FullName);
|
||||||
|
|
||||||
/***** List the existing exam announcements *****/
|
/***** List the existing exam announcements *****/
|
||||||
|
|
|
@ -2820,7 +2820,7 @@ bool Brw_UpdateFoldersAssigmentsIfExistForAllUsrs (const char *OldFolderName,con
|
||||||
NewFolderName);
|
NewFolderName);
|
||||||
if (rename (PathOldFolder,PathNewFolder)) // Fail
|
if (rename (PathOldFolder,PathNewFolder)) // Fail
|
||||||
{
|
{
|
||||||
Ale_ShowA_fmt (Ale_ERROR,Txt_Can_not_rename_a_folder_of_assignment);
|
Ale_ShowAlert (Ale_ERROR,Txt_Can_not_rename_a_folder_of_assignment);
|
||||||
NumUsrsError++;
|
NumUsrsError++;
|
||||||
}
|
}
|
||||||
else // Success
|
else // Success
|
||||||
|
@ -2847,7 +2847,7 @@ bool Brw_UpdateFoldersAssigmentsIfExistForAllUsrs (const char *OldFolderName,con
|
||||||
}
|
}
|
||||||
|
|
||||||
/***** Summary message *****/
|
/***** Summary message *****/
|
||||||
Ale_ShowA_fmt (Ale_INFO,"%s: %u<br />"
|
Ale_ShowAlert (Ale_INFO,"%s: %u<br />"
|
||||||
"%s: %u<br />"
|
"%s: %u<br />"
|
||||||
"%s: %u.",
|
"%s: %u.",
|
||||||
Txt_Users,NumUsrs,
|
Txt_Users,NumUsrs,
|
||||||
|
@ -2856,7 +2856,7 @@ bool Brw_UpdateFoldersAssigmentsIfExistForAllUsrs (const char *OldFolderName,con
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
/***** Warning message *****/
|
/***** Warning message *****/
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_Can_not_rename_a_folder_of_assignment);
|
Ale_ShowAlert (Ale_WARNING,Txt_Can_not_rename_a_folder_of_assignment);
|
||||||
|
|
||||||
/***** Free structure that stores the query result *****/
|
/***** Free structure that stores the query result *****/
|
||||||
DB_FreeMySQLResult (&mysql_res);
|
DB_FreeMySQLResult (&mysql_res);
|
||||||
|
@ -2921,7 +2921,7 @@ static void Brw_SetAndCheckQuota (void)
|
||||||
Brw_SetMaxQuota ();
|
Brw_SetMaxQuota ();
|
||||||
Brw_CalcSizeOfDir (Gbl.FileBrowser.Priv.PathRootFolder);
|
Brw_CalcSizeOfDir (Gbl.FileBrowser.Priv.PathRootFolder);
|
||||||
if (Brw_CheckIfQuotaExceded ())
|
if (Brw_CheckIfQuotaExceded ())
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_Quota_exceeded);
|
Ale_ShowAlert (Ale_WARNING,Txt_Quota_exceeded);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
@ -3206,7 +3206,7 @@ static void Brw_ShowFileBrowserProject (void)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_fmt (Ale_WARNING,"You have no access to project files.");
|
Ale_ShowAlert (Ale_WARNING,"You have no access to project files.");
|
||||||
|
|
||||||
/***** End box *****/
|
/***** End box *****/
|
||||||
Box_EndBox ();
|
Box_EndBox ();
|
||||||
|
@ -3278,7 +3278,7 @@ static void Brw_ShowFileBrowsersAsgWrkCrs (void)
|
||||||
else // If no users are selected...
|
else // If no users are selected...
|
||||||
{
|
{
|
||||||
// ...write warning alert
|
// ...write warning alert
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_You_must_select_one_ore_more_users);
|
Ale_ShowAlert (Ale_WARNING,Txt_You_must_select_one_ore_more_users);
|
||||||
// ...and show again the form
|
// ...and show again the form
|
||||||
Brw_AskEditWorksCrs ();
|
Brw_AskEditWorksCrs ();
|
||||||
}
|
}
|
||||||
|
@ -3533,14 +3533,14 @@ void Brw_ShowAgainFileBrowserOrWorks (void)
|
||||||
{
|
{
|
||||||
case Brw_ADMI_MRK_CRS:
|
case Brw_ADMI_MRK_CRS:
|
||||||
case Brw_ADMI_MRK_GRP:
|
case Brw_ADMI_MRK_GRP:
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_Files_of_marks_must_contain_a_table_in_HTML_format_);
|
Ale_ShowAlert (Ale_INFO,Txt_Files_of_marks_must_contain_a_table_in_HTML_format_);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
/***** Legal notice *****/
|
/***** Legal notice *****/
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_Disclaimer_the_files_hosted_here_,
|
Ale_ShowAlert (Ale_INFO,Txt_Disclaimer_the_files_hosted_here_,
|
||||||
Cfg_PLATFORM_SHORT_NAME,
|
Cfg_PLATFORM_SHORT_NAME,
|
||||||
Cfg_PLATFORM_RESPONSIBLE_EMAIL);
|
Cfg_PLATFORM_RESPONSIBLE_EMAIL);
|
||||||
}
|
}
|
||||||
|
@ -6784,7 +6784,7 @@ void Brw_RemFileFromTree (void)
|
||||||
Gbl.Usrs.Other.UsrDat.UsrCod);
|
Gbl.Usrs.Other.UsrDat.UsrCod);
|
||||||
|
|
||||||
/* Message of confirmation of removing */
|
/* Message of confirmation of removing */
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_FILE_X_removed,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_FILE_X_removed,
|
||||||
FileNameToShow);
|
FileNameToShow);
|
||||||
}
|
}
|
||||||
else // File / link not found
|
else // File / link not found
|
||||||
|
@ -6841,7 +6841,7 @@ void Brw_RemFolderFromTree (void)
|
||||||
Gbl.Usrs.Other.UsrDat.UsrCod);
|
Gbl.Usrs.Other.UsrDat.UsrCod);
|
||||||
|
|
||||||
/* Message of confirmation of successfull removing */
|
/* Message of confirmation of successfull removing */
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Folder_X_removed,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Folder_X_removed,
|
||||||
Gbl.FileBrowser.FilFolLnkName);
|
Gbl.FileBrowser.FilFolLnkName);
|
||||||
}
|
}
|
||||||
else // Folder not found
|
else // Folder not found
|
||||||
|
@ -6920,7 +6920,7 @@ void Brw_RemSubtreeInFileBrowser (void)
|
||||||
Brw_RemoveAffectedExpandedFolders (Gbl.FileBrowser.Priv.FullPathInTree);
|
Brw_RemoveAffectedExpandedFolders (Gbl.FileBrowser.Priv.FullPathInTree);
|
||||||
|
|
||||||
/***** Write message of confirmation *****/
|
/***** Write message of confirmation *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_Folder_X_and_all_its_contents_removed,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_Folder_X_and_all_its_contents_removed,
|
||||||
Gbl.FileBrowser.FilFolLnkName);
|
Gbl.FileBrowser.FilFolLnkName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -7232,14 +7232,14 @@ static void Brw_WriteCurrentClipboard (void)
|
||||||
Gbl.FileBrowser.Clipboard.FileName,
|
Gbl.FileBrowser.Clipboard.FileName,
|
||||||
FileNameToShow);
|
FileNameToShow);
|
||||||
|
|
||||||
Ale_ShowA_fmt (Ale_CLIPBOARD,"%s: %s, %s <strong>%s</strong>.",
|
Ale_ShowAlert (Ale_CLIPBOARD,"%s: %s, %s <strong>%s</strong>.",
|
||||||
Txt_Copy_source,TxtClipboardZone,
|
Txt_Copy_source,TxtClipboardZone,
|
||||||
TxtFileType[Gbl.FileBrowser.Clipboard.FileType],
|
TxtFileType[Gbl.FileBrowser.Clipboard.FileType],
|
||||||
FileNameToShow);
|
FileNameToShow);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
// The root folder
|
// The root folder
|
||||||
Ale_ShowA_fmt (Ale_CLIPBOARD,"%s: %s, %s.",
|
Ale_ShowAlert (Ale_CLIPBOARD,"%s: %s, %s.",
|
||||||
Txt_Copy_source,TxtClipboardZone,
|
Txt_Copy_source,TxtClipboardZone,
|
||||||
Txt_all_files_inside_the_root_folder);
|
Txt_all_files_inside_the_root_folder);
|
||||||
}
|
}
|
||||||
|
@ -7989,7 +7989,7 @@ void Brw_PasteIntoFileBrowser (void)
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
/***** Write message ******/
|
/***** Write message ******/
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_Nothing_has_been_pasted_because_the_clipboard_is_empty_);
|
Ale_ShowAlert (Ale_WARNING,Txt_Nothing_has_been_pasted_because_the_clipboard_is_empty_);
|
||||||
|
|
||||||
/***** Show again file browser *****/
|
/***** Show again file browser *****/
|
||||||
Brw_ShowAgainFileBrowserOrWorks ();
|
Brw_ShowAgainFileBrowserOrWorks ();
|
||||||
|
@ -8180,7 +8180,7 @@ static void Brw_PasteClipboard (void)
|
||||||
&FirstFilCod))
|
&FirstFilCod))
|
||||||
{
|
{
|
||||||
/***** Write message of success *****/
|
/***** Write message of success *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,"%s<br />"
|
Ale_ShowAlert (Ale_SUCCESS,"%s<br />"
|
||||||
"%s: %u<br />"
|
"%s: %u<br />"
|
||||||
"%s: %u<br />"
|
"%s: %u<br />"
|
||||||
"%s: %u",
|
"%s: %u",
|
||||||
|
@ -8330,15 +8330,15 @@ static bool Brw_PasteTreeIntoFolder (unsigned LevelOrg,
|
||||||
switch (FileType)
|
switch (FileType)
|
||||||
{
|
{
|
||||||
case Brw_IS_FILE:
|
case Brw_IS_FILE:
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_copy_has_stopped_when_trying_to_paste_the_file_X_because_it_would_exceed_the_maximum_allowed_number_of_levels,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_copy_has_stopped_when_trying_to_paste_the_file_X_because_it_would_exceed_the_maximum_allowed_number_of_levels,
|
||||||
FileNameToShow);
|
FileNameToShow);
|
||||||
break;
|
break;
|
||||||
case Brw_IS_FOLDER:
|
case Brw_IS_FOLDER:
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_copy_has_stopped_when_trying_to_paste_the_folder_X_because_it_would_exceed_the_maximum_allowed_number_of_levels,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_copy_has_stopped_when_trying_to_paste_the_folder_X_because_it_would_exceed_the_maximum_allowed_number_of_levels,
|
||||||
FileNameToShow);
|
FileNameToShow);
|
||||||
break;
|
break;
|
||||||
case Brw_IS_LINK:
|
case Brw_IS_LINK:
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_copy_has_stopped_when_trying_to_paste_the_link_X_because_it_would_exceed_the_maximum_allowed_number_of_levels,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_copy_has_stopped_when_trying_to_paste_the_link_X_because_it_would_exceed_the_maximum_allowed_number_of_levels,
|
||||||
FileNameToShow);
|
FileNameToShow);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
@ -8355,7 +8355,7 @@ static bool Brw_PasteTreeIntoFolder (unsigned LevelOrg,
|
||||||
/***** Check if exists the destination file */
|
/***** Check if exists the destination file */
|
||||||
if (Fil_CheckIfPathExists (PathDstWithFile))
|
if (Fil_CheckIfPathExists (PathDstWithFile))
|
||||||
{
|
{
|
||||||
Ale_ShowA_fmt (Ale_WARNING,FileType == Brw_IS_FILE ? Txt_The_copy_has_stopped_when_trying_to_paste_the_file_X_because_there_is_already_an_object_with_that_name :
|
Ale_ShowAlert (Ale_WARNING,FileType == Brw_IS_FILE ? Txt_The_copy_has_stopped_when_trying_to_paste_the_file_X_because_there_is_already_an_object_with_that_name :
|
||||||
Txt_The_copy_has_stopped_when_trying_to_paste_the_link_X_because_there_is_already_an_object_with_that_name,
|
Txt_The_copy_has_stopped_when_trying_to_paste_the_link_X_because_there_is_already_an_object_with_that_name,
|
||||||
FileNameToShow);
|
FileNameToShow);
|
||||||
CopyIsGoingSuccessful = false;
|
CopyIsGoingSuccessful = false;
|
||||||
|
@ -8372,7 +8372,7 @@ static bool Brw_PasteTreeIntoFolder (unsigned LevelOrg,
|
||||||
Mrk_CheckFileOfMarks (PathOrg,&Marks); // Gbl.Alert.Txt contains feedback text
|
Mrk_CheckFileOfMarks (PathOrg,&Marks); // Gbl.Alert.Txt contains feedback text
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_copy_has_stopped_when_trying_to_paste_the_file_X_because_you_can_not_paste_a_file_here_of_a_type_other_than_HTML,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_copy_has_stopped_when_trying_to_paste_the_file_X_because_you_can_not_paste_a_file_here_of_a_type_other_than_HTML,
|
||||||
FileNameToShow);
|
FileNameToShow);
|
||||||
CopyIsGoingSuccessful = false;
|
CopyIsGoingSuccessful = false;
|
||||||
}
|
}
|
||||||
|
@ -8385,7 +8385,7 @@ static bool Brw_PasteTreeIntoFolder (unsigned LevelOrg,
|
||||||
Gbl.FileBrowser.Size.TotalSiz += (unsigned long long) FileStatus.st_size;
|
Gbl.FileBrowser.Size.TotalSiz += (unsigned long long) FileStatus.st_size;
|
||||||
if (Brw_CheckIfQuotaExceded ())
|
if (Brw_CheckIfQuotaExceded ())
|
||||||
{
|
{
|
||||||
Ale_ShowA_fmt (Ale_WARNING,FileType == Brw_IS_FILE ? Txt_The_copy_has_stopped_when_trying_to_paste_the_file_X_because_it_would_exceed_the_disk_quota :
|
Ale_ShowAlert (Ale_WARNING,FileType == Brw_IS_FILE ? Txt_The_copy_has_stopped_when_trying_to_paste_the_file_X_because_it_would_exceed_the_disk_quota :
|
||||||
Txt_The_copy_has_stopped_when_trying_to_paste_the_link_X_because_it_would_exceed_the_disk_quota,
|
Txt_The_copy_has_stopped_when_trying_to_paste_the_link_X_because_it_would_exceed_the_disk_quota,
|
||||||
FileNameToShow);
|
FileNameToShow);
|
||||||
CopyIsGoingSuccessful = false;
|
CopyIsGoingSuccessful = false;
|
||||||
|
@ -8427,7 +8427,7 @@ static bool Brw_PasteTreeIntoFolder (unsigned LevelOrg,
|
||||||
Gbl.FileBrowser.Size.TotalSiz += (unsigned long long) FileStatus.st_size;
|
Gbl.FileBrowser.Size.TotalSiz += (unsigned long long) FileStatus.st_size;
|
||||||
if (Brw_CheckIfQuotaExceded ())
|
if (Brw_CheckIfQuotaExceded ())
|
||||||
{
|
{
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_copy_has_stopped_when_trying_to_paste_the_folder_X_because_it_would_exceed_the_disk_quota,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_copy_has_stopped_when_trying_to_paste_the_folder_X_because_it_would_exceed_the_disk_quota,
|
||||||
FileNameToShow);
|
FileNameToShow);
|
||||||
CopyIsGoingSuccessful = false;
|
CopyIsGoingSuccessful = false;
|
||||||
}
|
}
|
||||||
|
@ -8555,7 +8555,7 @@ static void Brw_PutFormToCreateAFolder (const char FileNameToShow[NAME_MAX + 1])
|
||||||
/***** Start box *****/
|
/***** Start box *****/
|
||||||
Box_StartBox (NULL,Txt_Create_folder,NULL,
|
Box_StartBox (NULL,Txt_Create_folder,NULL,
|
||||||
NULL,Box_NOT_CLOSABLE);
|
NULL,Box_NOT_CLOSABLE);
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_You_can_create_a_new_folder_inside_the_folder_X,
|
Ale_ShowAlert (Ale_INFO,Txt_You_can_create_a_new_folder_inside_the_folder_X,
|
||||||
FileNameToShow);
|
FileNameToShow);
|
||||||
|
|
||||||
/***** Folder *****/
|
/***** Folder *****/
|
||||||
|
@ -8593,7 +8593,7 @@ static void Brw_PutFormToUploadFilesUsingDropzone (const char *FileNameToShow)
|
||||||
NULL,Box_NOT_CLOSABLE);
|
NULL,Box_NOT_CLOSABLE);
|
||||||
|
|
||||||
/***** Help message *****/
|
/***** Help message *****/
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_or_you_can_upload_new_files_to_the_folder_X,
|
Ale_ShowAlert (Ale_INFO,Txt_or_you_can_upload_new_files_to_the_folder_X,
|
||||||
FileNameToShow);
|
FileNameToShow);
|
||||||
|
|
||||||
/***** Form to upload files using the library Dropzone.js *****/
|
/***** Form to upload files using the library Dropzone.js *****/
|
||||||
|
@ -8654,7 +8654,7 @@ static void Brw_PutFormToUploadOneFileClassic (const char *FileNameToShow)
|
||||||
NULL,Box_NOT_CLOSABLE);
|
NULL,Box_NOT_CLOSABLE);
|
||||||
|
|
||||||
/***** Help message *****/
|
/***** Help message *****/
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_or_you_can_upload_a_new_file_to_the_folder_X,
|
Ale_ShowAlert (Ale_INFO,Txt_or_you_can_upload_a_new_file_to_the_folder_X,
|
||||||
FileNameToShow);
|
FileNameToShow);
|
||||||
|
|
||||||
/***** Form to upload one files using the classic way *****/
|
/***** Form to upload one files using the classic way *****/
|
||||||
|
@ -8696,7 +8696,7 @@ static void Brw_PutFormToPasteAFileOrFolder (const char *FileNameToShow)
|
||||||
NULL,Box_NOT_CLOSABLE);
|
NULL,Box_NOT_CLOSABLE);
|
||||||
|
|
||||||
/***** Help message *****/
|
/***** Help message *****/
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_or_you_can_make_a_file_copy_to_the_folder_X,
|
Ale_ShowAlert (Ale_INFO,Txt_or_you_can_make_a_file_copy_to_the_folder_X,
|
||||||
FileNameToShow);
|
FileNameToShow);
|
||||||
|
|
||||||
/***** Send button and end box *****/
|
/***** Send button and end box *****/
|
||||||
|
@ -8731,7 +8731,7 @@ static void Brw_PutFormToCreateALink (const char *FileNameToShow)
|
||||||
NULL,Box_NOT_CLOSABLE);
|
NULL,Box_NOT_CLOSABLE);
|
||||||
|
|
||||||
/***** Help message *****/
|
/***** Help message *****/
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_or_you_can_create_a_new_link_inside_the_folder_X,
|
Ale_ShowAlert (Ale_INFO,Txt_or_you_can_create_a_new_link_inside_the_folder_X,
|
||||||
FileNameToShow);
|
FileNameToShow);
|
||||||
|
|
||||||
/***** URL *****/
|
/***** URL *****/
|
||||||
|
@ -8820,7 +8820,7 @@ void Brw_RecFolderFileBrowser (void)
|
||||||
if (Brw_CheckIfQuotaExceded ())
|
if (Brw_CheckIfQuotaExceded ())
|
||||||
{
|
{
|
||||||
Fil_RemoveTree (Path);
|
Fil_RemoveTree (Path);
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_Can_not_create_the_folder_X_because_it_would_exceed_the_disk_quota,
|
Ale_ShowAlert (Ale_WARNING,Txt_Can_not_create_the_folder_X_because_it_would_exceed_the_disk_quota,
|
||||||
Gbl.FileBrowser.NewFilFolLnkName);
|
Gbl.FileBrowser.NewFilFolLnkName);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -8847,7 +8847,7 @@ void Brw_RecFolderFileBrowser (void)
|
||||||
Brw_IS_FOLDER,
|
Brw_IS_FOLDER,
|
||||||
Gbl.FileBrowser.FilFolLnkName,
|
Gbl.FileBrowser.FilFolLnkName,
|
||||||
FileNameToShow);
|
FileNameToShow);
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_folder_X_has_been_created_inside_the_folder_Y,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_folder_X_has_been_created_inside_the_folder_Y,
|
||||||
Gbl.FileBrowser.NewFilFolLnkName,FileNameToShow);
|
Gbl.FileBrowser.NewFilFolLnkName,FileNameToShow);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -8856,7 +8856,7 @@ void Brw_RecFolderFileBrowser (void)
|
||||||
switch (errno)
|
switch (errno)
|
||||||
{
|
{
|
||||||
case EEXIST:
|
case EEXIST:
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_Can_not_create_the_folder_X_because_there_is_already_a_folder_or_a_file_with_that_name,
|
Ale_ShowAlert (Ale_WARNING,Txt_Can_not_create_the_folder_X_because_there_is_already_a_folder_or_a_file_with_that_name,
|
||||||
Gbl.FileBrowser.NewFilFolLnkName);
|
Gbl.FileBrowser.NewFilFolLnkName);
|
||||||
break;
|
break;
|
||||||
case EACCES:
|
case EACCES:
|
||||||
|
@ -8869,7 +8869,7 @@ void Brw_RecFolderFileBrowser (void)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else // Folder name not valid
|
else // Folder name not valid
|
||||||
Ale_ShowA_new (Ale_WARNING,Gbl.AlertToShowLater.Txt);
|
Ale_ShowDelayedAlert (Ale_WARNING,Gbl.DelayedAlert.Txt);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Lay_ShowErrorAndExit (Txt_You_can_not_create_folders_here); // It's difficult, but not impossible that a user sees this message
|
Lay_ShowErrorAndExit (Txt_You_can_not_create_folders_here); // It's difficult, but not impossible that a user sees this message
|
||||||
|
@ -8937,7 +8937,7 @@ void Brw_RenFolderFileBrowser (void)
|
||||||
case ENOTEMPTY:
|
case ENOTEMPTY:
|
||||||
case EEXIST:
|
case EEXIST:
|
||||||
case ENOTDIR:
|
case ENOTDIR:
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_folder_name_X_has_not_changed_because_there_is_already_a_folder_or_a_file_with_the_name_Y,
|
Ale_ShowAlert (Ale_WARNING,Txt_The_folder_name_X_has_not_changed_because_there_is_already_a_folder_or_a_file_with_the_name_Y,
|
||||||
Gbl.FileBrowser.FilFolLnkName,Gbl.FileBrowser.NewFilFolLnkName);
|
Gbl.FileBrowser.FilFolLnkName,Gbl.FileBrowser.NewFilFolLnkName);
|
||||||
break;
|
break;
|
||||||
case EACCES:
|
case EACCES:
|
||||||
|
@ -8971,18 +8971,18 @@ void Brw_RenFolderFileBrowser (void)
|
||||||
NewPathInTree);
|
NewPathInTree);
|
||||||
|
|
||||||
/* Write message of confirmation */
|
/* Write message of confirmation */
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_folder_name_X_has_changed_to_Y,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_folder_name_X_has_changed_to_Y,
|
||||||
Gbl.FileBrowser.FilFolLnkName,
|
Gbl.FileBrowser.FilFolLnkName,
|
||||||
Gbl.FileBrowser.NewFilFolLnkName);
|
Gbl.FileBrowser.NewFilFolLnkName);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
else // Names are equal. This may happens if we have press INTRO without changing the name
|
else // Names are equal. This may happens if we have press INTRO without changing the name
|
||||||
Ale_ShowA_fmt (Ale_INFO,Txt_The_folder_name_X_has_not_changed,
|
Ale_ShowAlert (Ale_INFO,Txt_The_folder_name_X_has_not_changed,
|
||||||
Gbl.FileBrowser.FilFolLnkName);
|
Gbl.FileBrowser.FilFolLnkName);
|
||||||
}
|
}
|
||||||
else // Folder name not valid
|
else // Folder name not valid
|
||||||
Ale_ShowA_new (Ale_WARNING,Gbl.AlertToShowLater.Txt);
|
Ale_ShowDelayedAlert (Ale_WARNING,Gbl.DelayedAlert.Txt);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Lay_ShowErrorAndExit (Txt_You_can_not_rename_this_folder);
|
Lay_ShowErrorAndExit (Txt_You_can_not_rename_this_folder);
|
||||||
|
@ -9086,7 +9086,7 @@ static bool Brw_RcvFileInFileBrw (Brw_UploadType_t UploadType)
|
||||||
/***** Check if uploading this kind of file is allowed *****/
|
/***** Check if uploading this kind of file is allowed *****/
|
||||||
if (Brw_CheckIfUploadIsAllowed (MIMEType)) // Gbl.Alert.Txt contains feedback text
|
if (Brw_CheckIfUploadIsAllowed (MIMEType)) // Gbl.Alert.Txt contains feedback text
|
||||||
{
|
{
|
||||||
if (Str_ConvertFilFolLnkNameToValid (Gbl.FileBrowser.NewFilFolLnkName)) // Gbl.AlertToShowLater.Txt contains feedback text
|
if (Str_ConvertFilFolLnkNameToValid (Gbl.FileBrowser.NewFilFolLnkName)) // Gbl.DelayedAlert.Txt contains feedback text
|
||||||
{
|
{
|
||||||
/* Gbl.FileBrowser.NewFilFolLnkName holds the name of the new file */
|
/* Gbl.FileBrowser.NewFilFolLnkName holds the name of the new file */
|
||||||
snprintf (Path,sizeof (Path),
|
snprintf (Path,sizeof (Path),
|
||||||
|
@ -9320,7 +9320,7 @@ void Brw_RecLinkFileBrowser (void)
|
||||||
|
|
||||||
/* Check if the URL file exists */
|
/* Check if the URL file exists */
|
||||||
if (Fil_CheckIfPathExists (Path))
|
if (Fil_CheckIfPathExists (Path))
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_Can_not_create_the_link_X_because_there_is_already_a_folder_or_a_link_with_that_name,
|
Ale_ShowAlert (Ale_WARNING,Txt_Can_not_create_the_link_X_because_there_is_already_a_folder_or_a_link_with_that_name,
|
||||||
FileName);
|
FileName);
|
||||||
else // URL file does not exist
|
else // URL file does not exist
|
||||||
{
|
{
|
||||||
|
@ -9339,7 +9339,7 @@ void Brw_RecLinkFileBrowser (void)
|
||||||
if (Brw_CheckIfQuotaExceded ())
|
if (Brw_CheckIfQuotaExceded ())
|
||||||
{
|
{
|
||||||
Fil_RemoveTree (Path);
|
Fil_RemoveTree (Path);
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_Can_not_create_the_link_X_because_it_would_exceed_the_disk_quota,
|
Ale_ShowAlert (Ale_WARNING,Txt_Can_not_create_the_link_X_because_it_would_exceed_the_disk_quota,
|
||||||
FileName);
|
FileName);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -9367,7 +9367,7 @@ void Brw_RecLinkFileBrowser (void)
|
||||||
Brw_IS_FOLDER,
|
Brw_IS_FOLDER,
|
||||||
Gbl.FileBrowser.FilFolLnkName,
|
Gbl.FileBrowser.FilFolLnkName,
|
||||||
FileNameToShow);
|
FileNameToShow);
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_link_X_has_been_placed_inside_the_folder_Y,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_link_X_has_been_placed_inside_the_folder_Y,
|
||||||
FileName,FileNameToShow);
|
FileName,FileNameToShow);
|
||||||
|
|
||||||
FileMetadata.FilCod = FilCod;
|
FileMetadata.FilCod = FilCod;
|
||||||
|
@ -9401,10 +9401,10 @@ void Brw_RecLinkFileBrowser (void)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else // Link URL not valid
|
else // Link URL not valid
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_UPLOAD_FILE_Invalid_link);
|
Ale_ShowAlert (Ale_WARNING,Txt_UPLOAD_FILE_Invalid_link);
|
||||||
}
|
}
|
||||||
else // Link URL not valid
|
else // Link URL not valid
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_UPLOAD_FILE_Invalid_link);
|
Ale_ShowAlert (Ale_WARNING,Txt_UPLOAD_FILE_Invalid_link);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Lay_ShowErrorAndExit (Txt_You_can_not_create_links_here); // It's difficult, but not impossible that a user sees this message
|
Lay_ShowErrorAndExit (Txt_You_can_not_create_links_here); // It's difficult, but not impossible that a user sees this message
|
||||||
|
@ -9504,7 +9504,7 @@ void Brw_SetDocumentAsVisible (void)
|
||||||
Gbl.FileBrowser.FileType,
|
Gbl.FileBrowser.FileType,
|
||||||
Gbl.FileBrowser.FilFolLnkName,
|
Gbl.FileBrowser.FilFolLnkName,
|
||||||
FileNameToShow);
|
FileNameToShow);
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_FILE_FOLDER_OR_LINK_X_is_now_visible,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_FILE_FOLDER_OR_LINK_X_is_now_visible,
|
||||||
FileNameToShow);
|
FileNameToShow);
|
||||||
|
|
||||||
/***** Show again the file browser *****/
|
/***** Show again the file browser *****/
|
||||||
|
@ -9540,7 +9540,7 @@ void Brw_SetDocumentAsHidden (void)
|
||||||
Gbl.FileBrowser.FileType,
|
Gbl.FileBrowser.FileType,
|
||||||
Gbl.FileBrowser.FilFolLnkName,
|
Gbl.FileBrowser.FilFolLnkName,
|
||||||
FileNameToShow);
|
FileNameToShow);
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_FILE_FOLDER_OR_LINK_X_is_now_hidden,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_FILE_FOLDER_OR_LINK_X_is_now_hidden,
|
||||||
FileNameToShow);
|
FileNameToShow);
|
||||||
|
|
||||||
/***** Show again the file browser *****/
|
/***** Show again the file browser *****/
|
||||||
|
@ -10024,7 +10024,7 @@ void Brw_ShowFileMetadata (void)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_file_of_folder_no_longer_exists_or_is_now_hidden);
|
Ale_ShowAlert (Ale_WARNING,Txt_The_file_of_folder_no_longer_exists_or_is_now_hidden);
|
||||||
}
|
}
|
||||||
|
|
||||||
/***** Show again the file browser *****/
|
/***** Show again the file browser *****/
|
||||||
|
@ -10183,7 +10183,7 @@ void Brw_DownloadFile (void)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
Ale_ShowA_fmt (Ale_WARNING,Txt_The_file_of_folder_no_longer_exists_or_is_now_hidden);
|
Ale_ShowAlert (Ale_WARNING,Txt_The_file_of_folder_no_longer_exists_or_is_now_hidden);
|
||||||
|
|
||||||
/***** Show again the file browser *****/
|
/***** Show again the file browser *****/
|
||||||
Brw_ShowAgainFileBrowserOrWorks ();
|
Brw_ShowAgainFileBrowserOrWorks ();
|
||||||
|
@ -10507,12 +10507,12 @@ void Brw_ChgFileMetadata (void)
|
||||||
}
|
}
|
||||||
|
|
||||||
/***** Write sucess message *****/
|
/***** Write sucess message *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,Txt_The_properties_of_file_X_have_been_saved,
|
Ale_ShowAlert (Ale_SUCCESS,Txt_The_properties_of_file_X_have_been_saved,
|
||||||
Gbl.FileBrowser.FilFolLnkName);
|
Gbl.FileBrowser.FilFolLnkName);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
/***** Write error message *****/
|
/***** Write error message *****/
|
||||||
Ale_ShowA_fmt (Ale_ERROR,Txt_You_dont_have_permission_to_change_the_properties_of_file_X,
|
Ale_ShowAlert (Ale_ERROR,Txt_You_dont_have_permission_to_change_the_properties_of_file_X,
|
||||||
Gbl.FileBrowser.FilFolLnkName);
|
Gbl.FileBrowser.FilFolLnkName);
|
||||||
|
|
||||||
/***** Show again the file browser *****/
|
/***** Show again the file browser *****/
|
||||||
|
@ -12500,7 +12500,7 @@ void Brw_RemoveOldFilesBriefcase (void)
|
||||||
Brw_RemoveOldFilesInBrowser (Months,&Removed);
|
Brw_RemoveOldFilesInBrowser (Months,&Removed);
|
||||||
|
|
||||||
/***** Success message *****/
|
/***** Success message *****/
|
||||||
Ale_ShowA_fmt (Ale_SUCCESS,"%s: %u<br />"
|
Ale_ShowAlert (Ale_SUCCESS,"%s: %u<br />"
|
||||||
"%s: %u<br />"
|
"%s: %u<br />"
|
||||||
"%s: %u",
|
"%s: %u",
|
||||||
Txt_Files_removed ,Removed.NumFiles,
|
Txt_Files_removed ,Removed.NumFiles,
|
||||||
|
|
|
@ -167,7 +167,7 @@ void Fol_SuggestUsrsToFollowMainZone (void)
|
||||||
Box_EndBoxTable ();
|
Box_EndBoxTable ();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_old (Ale_INFO,Txt_No_user_to_whom_you_can_follow_Try_again_later);
|
Ale_ShowAlert (Ale_INFO,Txt_No_user_to_whom_you_can_follow_Try_again_later);
|
||||||
|
|
||||||
/***** Free structure that stores the query result *****/
|
/***** Free structure that stores the query result *****/
|
||||||
DB_FreeMySQLResult (&mysql_res);
|
DB_FreeMySQLResult (&mysql_res);
|
||||||
|
@ -653,7 +653,7 @@ void Fol_ListFollowing (void)
|
||||||
if (Usr_ChkUsrCodAndGetAllUsrDataFromUsrCod (&Gbl.Usrs.Other.UsrDat))
|
if (Usr_ChkUsrCodAndGetAllUsrDataFromUsrCod (&Gbl.Usrs.Other.UsrDat))
|
||||||
Fol_ListFollowingUsr (&Gbl.Usrs.Other.UsrDat);
|
Fol_ListFollowingUsr (&Gbl.Usrs.Other.UsrDat);
|
||||||
else
|
else
|
||||||
Ale_ShowA_old (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
else // If user not specified, view my profile
|
else // If user not specified, view my profile
|
||||||
Fol_ListFollowingUsr (&Gbl.Usrs.Me.UsrDat);
|
Fol_ListFollowingUsr (&Gbl.Usrs.Me.UsrDat);
|
||||||
|
@ -719,7 +719,7 @@ static void Fol_ListFollowingUsr (struct UsrData *UsrDat)
|
||||||
DB_FreeMySQLResult (&mysql_res);
|
DB_FreeMySQLResult (&mysql_res);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_old (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
@ -738,7 +738,7 @@ void Fol_ListFollowers (void)
|
||||||
if (Usr_ChkUsrCodAndGetAllUsrDataFromUsrCod (&Gbl.Usrs.Other.UsrDat))
|
if (Usr_ChkUsrCodAndGetAllUsrDataFromUsrCod (&Gbl.Usrs.Other.UsrDat))
|
||||||
Fol_ListFollowersUsr (&Gbl.Usrs.Other.UsrDat);
|
Fol_ListFollowersUsr (&Gbl.Usrs.Other.UsrDat);
|
||||||
else
|
else
|
||||||
Ale_ShowA_old (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
else // If user not specified, view my profile
|
else // If user not specified, view my profile
|
||||||
Fol_ListFollowersUsr (&Gbl.Usrs.Me.UsrDat);
|
Fol_ListFollowersUsr (&Gbl.Usrs.Me.UsrDat);
|
||||||
|
@ -812,7 +812,7 @@ static void Fol_ListFollowersUsr (struct UsrData *UsrDat)
|
||||||
Gbl.Usrs.Me.UsrDat.UsrCod);
|
Gbl.Usrs.Me.UsrDat.UsrCod);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Ale_ShowA_old (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
Ale_ShowAlert (Ale_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
|
@ -972,7 +972,7 @@ static void For_ShowPostsOfAThread (Ale_AlertType_t AlertType,const char *Messag
|
||||||
Lay_StartSection (For_FORUM_POSTS_SECTION_ID);
|
Lay_StartSection (For_FORUM_POSTS_SECTION_ID);
|
||||||
if (Message)
|
if (Message)
|
||||||
if (Message[0])
|
if (Message[0])
|
||||||
Ale_ShowA_old (AlertType,Message);
|
Ale_ShowAlert (AlertType,Message);
|
||||||
|
|
||||||
/***** Start box *****/
|
/***** Start box *****/
|
||||||
snprintf (FrameTitle,sizeof (FrameTitle),
|
snprintf (FrameTitle,sizeof (FrameTitle),
|
||||||
|
@ -2541,7 +2541,7 @@ static void For_ShowForumThreadsHighlightingOneThread (long ThrCodHighlighted,
|
||||||
Lay_StartSection (For_FORUM_THREADS_SECTION_ID);
|
Lay_StartSection (For_FORUM_THREADS_SECTION_ID);
|
||||||
if (Message)
|
if (Message)
|
||||||
if (Message[0])
|
if (Message[0])
|
||||||
Ale_ShowA_old (AlertType,Message);
|
Ale_ShowAlert (AlertType,Message);
|
||||||
|
|
||||||
/***** Start box for threads of this forum *****/
|
/***** Start box for threads of this forum *****/
|
||||||
snprintf (FrameTitle,sizeof (FrameTitle),
|
snprintf (FrameTitle,sizeof (FrameTitle),
|
||||||
|
|
|
@ -116,7 +116,7 @@ struct Globals
|
||||||
Ale_AlertType_t Type;
|
Ale_AlertType_t Type;
|
||||||
char Txt[Ale_MAX_BYTES_ALERT + 1];
|
char Txt[Ale_MAX_BYTES_ALERT + 1];
|
||||||
const char *Section; // Where to display the alert
|
const char *Section; // Where to display the alert
|
||||||
} AlertToShowLater; // Used in a posteriori function to write success / warning message
|
} DelayedAlert; // Used in a posteriori function to write success / warning message
|
||||||
struct
|
struct
|
||||||
{
|
{
|
||||||
size_t ContentLength;
|
size_t ContentLength;
|
||||||
|
|
|
@ -527,9 +527,9 @@ bool Pwd_SlowCheckIfPasswordIsGood (const char *PlainPassword,
|
||||||
/***** Check if password is found in user's ID, first name or surnames of anybody *****/
|
/***** Check if password is found in user's ID, first name or surnames of anybody *****/
|
||||||
if (Pwd_CheckIfPasswdIsUsrIDorName (PlainPassword)) // PlainPassword is a user's ID, name or surname
|
if (Pwd_CheckIfPasswdIsUsrIDorName (PlainPassword)) // PlainPassword is a user's ID, name or surname
|
||||||
{
|
{
|
||||||
Gbl.Alert.Type = Ale_WARNING;
|
Gbl.DelayedAlert.Type = Ale_WARNING;
|
||||||
Gbl.Alert.Section = Pwd_PASSWORD_SECTION_ID;
|
Gbl.DelayedAlert.Section = Pwd_PASSWORD_SECTION_ID;
|
||||||
Str_Copy (Gbl.AlertToShowLater.Txt,Txt_The_password_is_too_trivial_,
|
Str_Copy (Gbl.DelayedAlert.Txt,Txt_The_password_is_too_trivial_,
|
||||||
Ale_MAX_BYTES_ALERT);
|
Ale_MAX_BYTES_ALERT);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@ -538,9 +538,9 @@ bool Pwd_SlowCheckIfPasswordIsGood (const char *PlainPassword,
|
||||||
if (Pwd_GetNumOtherUsrsWhoUseThisPassword (EncryptedPassword,UsrCod) >
|
if (Pwd_GetNumOtherUsrsWhoUseThisPassword (EncryptedPassword,UsrCod) >
|
||||||
Pwd_MAX_OTHER_USERS_USING_THE_SAME_PASSWORD)
|
Pwd_MAX_OTHER_USERS_USING_THE_SAME_PASSWORD)
|
||||||
{
|
{
|
||||||
Gbl.Alert.Type = Ale_WARNING;
|
Gbl.DelayedAlert.Type = Ale_WARNING;
|
||||||
Gbl.Alert.Section = Pwd_PASSWORD_SECTION_ID;
|
Gbl.DelayedAlert.Section = Pwd_PASSWORD_SECTION_ID;
|
||||||
Str_Copy (Gbl.AlertToShowLater.Txt,Txt_The_password_is_too_trivial_,
|
Str_Copy (Gbl.DelayedAlert.Txt,Txt_The_password_is_too_trivial_,
|
||||||
Ale_MAX_BYTES_ALERT);
|
Ale_MAX_BYTES_ALERT);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@ -622,9 +622,9 @@ bool Pwd_FastCheckIfPasswordSeemsGood (const char *PlainPassword)
|
||||||
/***** Check length of password *****/
|
/***** Check length of password *****/
|
||||||
if (LengthPassword < Pwd_MIN_BYTES_PLAIN_PASSWORD) // PlainPassword too short
|
if (LengthPassword < Pwd_MIN_BYTES_PLAIN_PASSWORD) // PlainPassword too short
|
||||||
{
|
{
|
||||||
Gbl.Alert.Type = Ale_WARNING;
|
Gbl.DelayedAlert.Type = Ale_WARNING;
|
||||||
Gbl.Alert.Section = Pwd_PASSWORD_SECTION_ID;
|
Gbl.DelayedAlert.Section = Pwd_PASSWORD_SECTION_ID;
|
||||||
snprintf (Gbl.Alert.Txt,sizeof (Gbl.Alert.Txt),
|
snprintf (Gbl.DelayedAlert.Txt,sizeof (Gbl.Alert.Txt),
|
||||||
Txt_The_password_must_be_at_least_X_characters,
|
Txt_The_password_must_be_at_least_X_characters,
|
||||||
Pwd_MIN_CHARS_PLAIN_PASSWORD);
|
Pwd_MIN_CHARS_PLAIN_PASSWORD);
|
||||||
return false;
|
return false;
|
||||||
|
@ -633,9 +633,9 @@ bool Pwd_FastCheckIfPasswordSeemsGood (const char *PlainPassword)
|
||||||
/***** Check spaces in password *****/
|
/***** Check spaces in password *****/
|
||||||
if (strchr (PlainPassword,(int) ' ') != NULL) // PlainPassword with spaces
|
if (strchr (PlainPassword,(int) ' ') != NULL) // PlainPassword with spaces
|
||||||
{
|
{
|
||||||
Gbl.Alert.Type = Ale_WARNING;
|
Gbl.DelayedAlert.Type = Ale_WARNING;
|
||||||
Gbl.Alert.Section = Pwd_PASSWORD_SECTION_ID;
|
Gbl.DelayedAlert.Section = Pwd_PASSWORD_SECTION_ID;
|
||||||
Str_Copy (Gbl.Alert.Txt,Txt_The_password_can_not_contain_spaces,
|
Str_Copy (Gbl.DelayedAlert.Txt,Txt_The_password_can_not_contain_spaces,
|
||||||
Ale_MAX_BYTES_ALERT);
|
Ale_MAX_BYTES_ALERT);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@ -648,9 +648,9 @@ bool Pwd_FastCheckIfPasswordSeemsGood (const char *PlainPassword)
|
||||||
ItsANumber = false;
|
ItsANumber = false;
|
||||||
if (ItsANumber)
|
if (ItsANumber)
|
||||||
{
|
{
|
||||||
Gbl.Alert.Type = Ale_WARNING;
|
Gbl.DelayedAlert.Type = Ale_WARNING;
|
||||||
Gbl.Alert.Section = Pwd_PASSWORD_SECTION_ID;
|
Gbl.DelayedAlert.Section = Pwd_PASSWORD_SECTION_ID;
|
||||||
Str_Copy (Gbl.Alert.Txt,Txt_The_password_can_not_consist_only_of_digits,
|
Str_Copy (Gbl.DelayedAlert.Txt,Txt_The_password_can_not_consist_only_of_digits,
|
||||||
Ale_MAX_BYTES_ALERT);
|
Ale_MAX_BYTES_ALERT);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1379,7 +1379,7 @@ static void Sta_ShowHits (Sta_GlobalOrCourseAccesses_t GlobalOrCourse)
|
||||||
/***** Write query for debug *****/
|
/***** Write query for debug *****/
|
||||||
/*
|
/*
|
||||||
if (Gbl.Usrs.Me.Role.Logged == Rol_SYS_ADM)
|
if (Gbl.Usrs.Me.Role.Logged == Rol_SYS_ADM)
|
||||||
Ale_ShowAlert (Ale_INFO,Query);
|
Ale_ShowFixedAlert (Ale_INFO,Query);
|
||||||
*/
|
*/
|
||||||
/***** Make the query *****/
|
/***** Make the query *****/
|
||||||
NumRows = DB_QuerySELECT (&mysql_res,"can not get clicks",
|
NumRows = DB_QuerySELECT (&mysql_res,"can not get clicks",
|
||||||
|
|
|
@ -2706,7 +2706,7 @@ int Str_ReadFileUntilBoundaryStr (FILE *FileSrc,char *StrDst,
|
||||||
/****** Convert invalid characters in a file name to valid characters ********/
|
/****** Convert invalid characters in a file name to valid characters ********/
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
// Return true if the name of the file o folder is valid
|
// Return true if the name of the file o folder is valid
|
||||||
// If the name is not valid, Gbl.AlertToShowLater.Txt will contain feedback text
|
// If the name is not valid, Gbl.DelayedAlert.Txt will contain feedback text
|
||||||
// File names with heading and trailing spaces are allowed
|
// File names with heading and trailing spaces are allowed
|
||||||
|
|
||||||
bool Str_ConvertFilFolLnkNameToValid (char *FileName)
|
bool Str_ConvertFilFolLnkNameToValid (char *FileName)
|
||||||
|
@ -2797,13 +2797,13 @@ bool Str_ConvertFilFolLnkNameToValid (char *FileName)
|
||||||
if (NumAlfanum)
|
if (NumAlfanum)
|
||||||
FileNameIsOK = true;
|
FileNameIsOK = true;
|
||||||
else
|
else
|
||||||
snprintf (Gbl.AlertToShowLater.Txt,sizeof (Gbl.AlertToShowLater.Txt),
|
snprintf (Gbl.DelayedAlert.Txt,sizeof (Gbl.DelayedAlert.Txt),
|
||||||
Gbl.FileBrowser.UploadingWithDropzone ? Txt_UPLOAD_FILE_X_invalid_name_NO_HTML :
|
Gbl.FileBrowser.UploadingWithDropzone ? Txt_UPLOAD_FILE_X_invalid_name_NO_HTML :
|
||||||
Txt_UPLOAD_FILE_X_invalid_name,
|
Txt_UPLOAD_FILE_X_invalid_name,
|
||||||
FileName);
|
FileName);
|
||||||
}
|
}
|
||||||
else // FileName is empty
|
else // FileName is empty
|
||||||
Str_Copy (Gbl.AlertToShowLater.Txt,
|
Str_Copy (Gbl.DelayedAlert.Txt,
|
||||||
Gbl.FileBrowser.UploadingWithDropzone ? Txt_UPLOAD_FILE_Invalid_name_NO_HTML :
|
Gbl.FileBrowser.UploadingWithDropzone ? Txt_UPLOAD_FILE_Invalid_name_NO_HTML :
|
||||||
Txt_UPLOAD_FILE_Invalid_name,
|
Txt_UPLOAD_FILE_Invalid_name,
|
||||||
Ale_MAX_BYTES_ALERT);
|
Ale_MAX_BYTES_ALERT);
|
||||||
|
|
|
@ -2404,7 +2404,7 @@ void Usr_Logout (void)
|
||||||
// extern const char *Txt_The_session_has_been_closed;
|
// extern const char *Txt_The_session_has_been_closed;
|
||||||
|
|
||||||
/***** Confirmation message *****/
|
/***** Confirmation message *****/
|
||||||
// Ale_ShowAlert (Ale_INFO,Txt_The_session_has_been_closed);
|
// Ale_ShowFixedAlert (Ale_INFO,Txt_The_session_has_been_closed);
|
||||||
|
|
||||||
/***** Form to log in *****/
|
/***** Form to log in *****/
|
||||||
Usr_WriteFormLogin (ActLogIn,NULL);
|
Usr_WriteFormLogin (ActLogIn,NULL);
|
||||||
|
@ -2566,7 +2566,7 @@ void Usr_WelcomeUsr (void)
|
||||||
|
|
||||||
/***** Institutional video *****/
|
/***** Institutional video *****/
|
||||||
/*
|
/*
|
||||||
Ale_ShowAlert (Ale_INFO,
|
Ale_ShowFixedAlert (Ale_INFO,
|
||||||
"<a href=\"https://abierta.ugr.es/creative_commons/\" target=\"_blank\">"
|
"<a href=\"https://abierta.ugr.es/creative_commons/\" target=\"_blank\">"
|
||||||
"Curso MOOC LICENCIAS CREATIVE COMMONS Y OER</a><br />"
|
"Curso MOOC LICENCIAS CREATIVE COMMONS Y OER</a><br />"
|
||||||
"Reconocimiento de 1 crédito por actividades universitarias<br />"
|
"Reconocimiento de 1 crédito por actividades universitarias<br />"
|
||||||
|
|
Loading…
Reference in New Issue