Version 16.215.4

This commit is contained in:
Antonio Cañas Vargas 2017-05-18 13:36:23 +02:00
parent 31e252dd88
commit bf2c0b5ab4
11 changed files with 19 additions and 107 deletions

View File

@ -418,7 +418,7 @@ static void Asg_ShowOneAssignment (long AsgCod,bool PrintView)
fprintf (Gbl.F.Out,"</td>");
/* Send work? */
fprintf (Gbl.F.Out,"<td rowspan=\"2\" class=\"%s CENTER_TOP",
fprintf (Gbl.F.Out,"<td class=\"%s CENTER_TOP",
(Asg.SendWork == Asg_SEND_WORK) ? "DAT_N" :
"DAT");
if (!PrintView)
@ -437,7 +437,7 @@ static void Asg_ShowOneAssignment (long AsgCod,bool PrintView)
Txt_No);
/* Assignment folder */
fprintf (Gbl.F.Out,"<td rowspan=\"2\" class=\"DAT LEFT_TOP");
fprintf (Gbl.F.Out,"<td class=\"DAT LEFT_TOP");
if (!PrintView)
fprintf (Gbl.F.Out," COLOR%u",Gbl.RowEvenOdd);
fprintf (Gbl.F.Out,"\">");
@ -463,7 +463,7 @@ static void Asg_ShowOneAssignment (long AsgCod,bool PrintView)
Str_ChangeFormat (Str_FROM_HTML,Str_TO_RIGOROUS_HTML,
Txt,Cns_MAX_BYTES_TEXT,false); // Convert from HTML to recpectful HTML
Str_InsertLinks (Txt,Cns_MAX_BYTES_TEXT,60); // Insert links
fprintf (Gbl.F.Out,"<td class=\"LEFT_TOP");
fprintf (Gbl.F.Out,"<td colspan=\"3\" class=\"LEFT_TOP");
if (!PrintView)
fprintf (Gbl.F.Out," COLOR%u",Gbl.RowEvenOdd);
fprintf (Gbl.F.Out,"\">");
@ -1436,7 +1436,6 @@ void Asg_RecFormAssignment (void)
/***** Notify by email about the new assignment *****/
if ((NumUsrsToBeNotifiedByEMail = Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_ASSIGNMENT,NewAsg.AsgCod)))
Asg_UpdateNumUsrsNotifiedByEMailAboutAssignment (NewAsg.AsgCod,NumUsrsToBeNotifiedByEMail);
Ntf_ShowAlertNumUsrsToBeNotifiedByEMail (NumUsrsToBeNotifiedByEMail);
/***** Show assignments again *****/
Asg_SeeAssignments ();

View File

@ -233,13 +233,15 @@
/****************************** Public constants *****************************/
/*****************************************************************************/
#define Log_PLATFORM_VERSION "SWAD 16.215.3 (2017-05-15)"
#define Log_PLATFORM_VERSION "SWAD 16.215.4 (2017-05-18)"
#define CSS_FILE "swad16.209.3.css"
#define JS_FILE "swad16.206.3.js"
// Number of lines (includes comments but not blank lines) has been got with the following command:
// nl swad*.c swad*.h css/swad*.css py/swad*.py js/swad*.js soap/swad*?.h sql/swad*.sql | tail -1
/*
Version 16.215.4: May 18, 2017 Changed layout of assignments.
Removed alert with number of users notified via email. (218868 lines)
Version 16.215.3: May 15, 2017 Fixed bug in layout of alerts. (218950 lines)
Version 16.215.2: May 13, 2017 Default theme: grey. (218946 lines)
Version 16.215.1: May 12, 2017 Fixed bug in layout of indicators. (218946 lines)

View File

@ -1864,7 +1864,6 @@ void Enr_SignUpInCrs (void)
MYSQL_ROW row;
Rol_Role_t RoleFromForm;
long ReqCod = -1L;
unsigned NumUsrsToBeNotifiedByEMail;
/***** Check if I already belong to course *****/
if (Gbl.Usrs.Me.UsrDat.RoleInCurrentCrsDB >= Rol_STUDENT)
@ -1935,10 +1934,7 @@ void Enr_SignUpInCrs (void)
// If this course has teachers ==> send notification to teachers
// If this course has no teachers and I want to be a teacher ==> send notification to administrators or superusers
if (Gbl.CurrentCrs.Crs.NumTchs || RoleFromForm == Rol_TEACHER)
{
NumUsrsToBeNotifiedByEMail = Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_ENROLMENT_REQUEST,ReqCod);
Ntf_ShowAlertNumUsrsToBeNotifiedByEMail (NumUsrsToBeNotifiedByEMail);
}
Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_ENROLMENT_REQUEST,ReqCod);
}
}

View File

@ -299,7 +299,6 @@ void Exa_ReceiveExamAnnouncement2 (void)
/***** Notify by email about the new exam announcement *****/
if ((NumUsrsToBeNotifiedByEMail = Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_EXAM_ANNOUNCEMENT,Gbl.ExamAnns.ExaDat.ExaCod)))
Exa_UpdateNumUsrsNotifiedByEMailAboutExamAnnouncement (Gbl.ExamAnns.ExaDat.ExaCod,NumUsrsToBeNotifiedByEMail);
Ntf_ShowAlertNumUsrsToBeNotifiedByEMail (NumUsrsToBeNotifiedByEMail);
/***** Create a new social note about the new exam announcement *****/
Soc_StoreAndPublishSocialNote (Soc_NOTE_EXAM_ANNOUNCEMENT,Gbl.ExamAnns.ExaDat.ExaCod,&SocPub);

View File

@ -7437,7 +7437,6 @@ static void Brw_PasteClipboard (void)
struct Brw_NumObjects Pasted;
long FirstFilCod = -1L; // First file code of the first file or link pasted. Important: initialize here to -1L
struct FileMetadata FileMetadata;
unsigned NumUsrsToBeNotifiedByEMail;
Pasted.NumFiles =
Pasted.NumLinks =
@ -7579,23 +7578,19 @@ static void Brw_PasteClipboard (void)
{
case Brw_ADMI_DOCUM_CRS:
case Brw_ADMI_DOCUM_GRP:
NumUsrsToBeNotifiedByEMail = Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_DOCUMENT_FILE,FirstFilCod);
Ntf_ShowAlertNumUsrsToBeNotifiedByEMail (NumUsrsToBeNotifiedByEMail);
Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_DOCUMENT_FILE,FirstFilCod);
break;
case Brw_ADMI_TEACH_CRS:
case Brw_ADMI_TEACH_GRP:
NumUsrsToBeNotifiedByEMail = Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_TEACHERS_FILE,FirstFilCod);
Ntf_ShowAlertNumUsrsToBeNotifiedByEMail (NumUsrsToBeNotifiedByEMail);
Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_TEACHERS_FILE,FirstFilCod);
break;
case Brw_ADMI_SHARE_CRS:
case Brw_ADMI_SHARE_GRP:
NumUsrsToBeNotifiedByEMail = Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_SHARED_FILE,FirstFilCod);
Ntf_ShowAlertNumUsrsToBeNotifiedByEMail (NumUsrsToBeNotifiedByEMail);
Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_SHARED_FILE,FirstFilCod);
break;
case Brw_ADMI_MARKS_CRS:
case Brw_ADMI_MARKS_GRP:
NumUsrsToBeNotifiedByEMail = Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_MARKS_FILE,FirstFilCod);
Ntf_ShowAlertNumUsrsToBeNotifiedByEMail (NumUsrsToBeNotifiedByEMail);
Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_MARKS_FILE,FirstFilCod);
break;
default:
break;
@ -8424,7 +8419,6 @@ static bool Brw_RcvFileInFileBrw (Brw_UploadType_t UploadType)
long FilCod = -1L; // Code of new file in database
struct FileMetadata FileMetadata;
struct MarksProperties Marks;
unsigned NumUsrsToBeNotifiedByEMail;
char FileNameToShow[NAME_MAX + 1];
bool UploadSucessful = false;
@ -8540,27 +8534,19 @@ static bool Brw_RcvFileInFileBrw (Brw_UploadType_t UploadType)
{
case Brw_ADMI_DOCUM_CRS:
case Brw_ADMI_DOCUM_GRP:
NumUsrsToBeNotifiedByEMail = Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_DOCUMENT_FILE,FilCod);
if (UploadType == Brw_CLASSIC_UPLOAD)
Ntf_ShowAlertNumUsrsToBeNotifiedByEMail (NumUsrsToBeNotifiedByEMail);
Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_DOCUMENT_FILE,FilCod);
break;
case Brw_ADMI_TEACH_CRS:
case Brw_ADMI_TEACH_GRP:
NumUsrsToBeNotifiedByEMail = Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_TEACHERS_FILE,FilCod);
if (UploadType == Brw_CLASSIC_UPLOAD)
Ntf_ShowAlertNumUsrsToBeNotifiedByEMail (NumUsrsToBeNotifiedByEMail);
Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_TEACHERS_FILE,FilCod);
break;
case Brw_ADMI_SHARE_CRS:
case Brw_ADMI_SHARE_GRP:
NumUsrsToBeNotifiedByEMail = Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_SHARED_FILE,FilCod);
if (UploadType == Brw_CLASSIC_UPLOAD)
Ntf_ShowAlertNumUsrsToBeNotifiedByEMail (NumUsrsToBeNotifiedByEMail);
Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_SHARED_FILE,FilCod);
break;
case Brw_ADMI_MARKS_CRS:
case Brw_ADMI_MARKS_GRP:
NumUsrsToBeNotifiedByEMail = Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_MARKS_FILE,FilCod);
if (UploadType == Brw_CLASSIC_UPLOAD)
Ntf_ShowAlertNumUsrsToBeNotifiedByEMail (NumUsrsToBeNotifiedByEMail);
Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_MARKS_FILE,FilCod);
break;
default:
break;
@ -8605,7 +8591,6 @@ void Brw_RecLinkFileBrowser (void)
long FilCod = -1L; // Code of new file in database
char FileNameToShow[NAME_MAX + 1];
struct FileMetadata FileMetadata;
unsigned NumUsrsToBeNotifiedByEMail;
/***** Get parameters related to file browser *****/
Brw_GetParAndInitFileBrowser ();
@ -8718,23 +8703,19 @@ void Brw_RecLinkFileBrowser (void)
{
case Brw_ADMI_DOCUM_CRS:
case Brw_ADMI_DOCUM_GRP:
NumUsrsToBeNotifiedByEMail = Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_DOCUMENT_FILE,FilCod);
Ntf_ShowAlertNumUsrsToBeNotifiedByEMail (NumUsrsToBeNotifiedByEMail);
Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_DOCUMENT_FILE,FilCod);
break;
case Brw_ADMI_TEACH_CRS:
case Brw_ADMI_TEACH_GRP:
NumUsrsToBeNotifiedByEMail = Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_TEACHERS_FILE,FilCod);
Ntf_ShowAlertNumUsrsToBeNotifiedByEMail (NumUsrsToBeNotifiedByEMail);
Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_TEACHERS_FILE,FilCod);
break;
case Brw_ADMI_SHARE_CRS:
case Brw_ADMI_SHARE_GRP:
NumUsrsToBeNotifiedByEMail = Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_SHARED_FILE,FilCod);
Ntf_ShowAlertNumUsrsToBeNotifiedByEMail (NumUsrsToBeNotifiedByEMail);
Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_SHARED_FILE,FilCod);
break;
case Brw_ADMI_MARKS_CRS:
case Brw_ADMI_MARKS_GRP:
NumUsrsToBeNotifiedByEMail = Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_MARKS_FILE,FilCod);
Ntf_ShowAlertNumUsrsToBeNotifiedByEMail (NumUsrsToBeNotifiedByEMail);
Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_MARKS_FILE,FilCod);
break;
default:
break;

View File

@ -631,7 +631,6 @@ void Msg_RecMsgFromUsr (void)
extern const char *Txt_message_sent_to_X_notified_by_email;
extern const char *Txt_message_sent_to_X_not_notified_by_email;
extern const char *Txt_Error_getting_data_from_a_recipient;
extern const char *Txt_Do_not_reload_this_page_because_the_message_will_be_sent_again_;
extern const char *Txt_The_message_has_not_been_sent_to_any_recipient;
extern const char *Txt_The_message_has_been_sent_to_1_recipient;
extern const char *Txt_The_message_has_been_sent_to_X_recipients;
@ -815,10 +814,6 @@ void Msg_RecMsgFromUsr (void)
(unsigned) NumRecipients);
Ale_ShowAlert (Ale_SUCCESS,Gbl.Alert.Txt);
}
/***** Show message about number of users to be notified *****/
Ntf_ShowAlertNumUsrsToBeNotifiedByEMail (NumRecipientsToBeNotifiedByEMail);
Ale_ShowAlert (Ale_INFO,Txt_Do_not_reload_this_page_because_the_message_will_be_sent_again_);
}
else
Ale_ShowAlert (Ale_WARNING,Txt_The_message_has_not_been_sent_to_any_recipient);

View File

@ -147,7 +147,6 @@ void Not_ReceiveNotice (void)
/***** Notify by email about the new notice *****/
if ((NumUsrsToBeNotifiedByEMail = Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_NOTICE,NotCod)))
Not_UpdateNumUsrsNotifiedByEMailAboutNotice (NotCod,NumUsrsToBeNotifiedByEMail);
Ntf_ShowAlertNumUsrsToBeNotifiedByEMail (NumUsrsToBeNotifiedByEMail);
/***** Create a new social note about the new notice *****/
Soc_StoreAndPublishSocialNote (Soc_NOTE_NOTICE,NotCod,&SocPub);

View File

@ -1786,19 +1786,6 @@ Ntf_NotifyEvent_t Ntf_GetNotifyEventFromDB (const char *Str)
return Ntf_EVENT_UNKNOWN;
}
/*****************************************************************************/
/******** Show an alert with the number of users notified by email ***********/
/*****************************************************************************/
void Ntf_ShowAlertNumUsrsToBeNotifiedByEMail (unsigned NumUsrsToBeNotifiedByEMail)
{
extern const char *Txt_No_of_users_who_will_be_notified_by_email;
sprintf (Gbl.Alert.Txt,"%s: %u",
Txt_No_of_users_who_will_be_notified_by_email,NumUsrsToBeNotifiedByEMail);
Ale_ShowAlert (Ale_INFO,Gbl.Alert.Txt);
}
/*****************************************************************************/
/************* Get number of events notified and emails sent *****************/
/*****************************************************************************/

View File

@ -135,7 +135,6 @@ void Ntf_StoreNotifyEventToOneUser (Ntf_NotifyEvent_t NotifyEvent,
long Cod,Ntf_Status_t Status);
void Ntf_SendPendingNotifByEMailToAllUsrs (void);
Ntf_NotifyEvent_t Ntf_GetNotifyEventFromDB (const char *Str);
void Ntf_ShowAlertNumUsrsToBeNotifiedByEMail (unsigned NumUsrsToBeNotifiedByEMail);
void Ntf_MarkAllNotifAsSeen (void);
void Ntf_PutFormChangeNotifSentByEMail (void);
void Ntf_ChangeNotifyEvents (void);

View File

@ -2168,11 +2168,8 @@ void Svy_RecFormSurvey (void)
/***** Notify by email about the new survey *****/
if (NewSvy.Scope == Sco_SCOPE_CRS) // Notify only the surveys for a course, not for a degree or global
{
if ((NumUsrsToBeNotifiedByEMail = Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_SURVEY,NewSvy.SvyCod)))
Svy_UpdateNumUsrsNotifiedByEMailAboutSurvey (NewSvy.SvyCod,NumUsrsToBeNotifiedByEMail);
Ntf_ShowAlertNumUsrsToBeNotifiedByEMail (NumUsrsToBeNotifiedByEMail);
}
/***** Show surveys again *****/
Svy_ListAllSurveys (&SvyQst);

View File

@ -8589,27 +8589,6 @@ const char *Txt_distributed_by =
"distribu&iacute;do por";
#endif
const char *Txt_Do_not_reload_this_page_because_the_message_will_be_sent_again_ =
#if L==1
"No recargue esta p&aacute;gina, pues el mensaje se enviar&iacute;a de nuevo y llegar&iacute;a repetido."; // Necessita traduccio
#elif L==2
"Do not reload this page because the message would be sent again and would arrive repeated."; // Need Übersetzung
#elif L==3
"Do not reload this page because the message would be sent again and would arrive repeated.";
#elif L==4
"No recargue esta p&aacute;gina, pues el mensaje se enviar&iacute;a de nuevo y llegar&iacute;a repetido.";
#elif L==5
"Do not reload this page because the message would be sent again and would arrive repeated."; // Besoin de traduction
#elif L==6
"No recargue esta p&aacute;gina, pues el mensaje se enviar&iacute;a de nuevo y llegar&iacute;a repetido."; // Okoteve traducción
#elif L==7
"Non ricaricare questa pagina perch&egrave; il messaggio sar&agrave; nuovamente inviato.";
#elif L==8
"Nie przeladuj strone, poniewaz wiadomosc zostanie wyslana ponownie przyjedzie powtarzane.";
#elif L==9
"Do not reload this page because the message would be sent again and would arrive repeated."; // Necessita de tradução
#endif
const char *Txt_Do_not_show_again =
#if L==1
"No mostrar de nou";
@ -25272,27 +25251,6 @@ const char *Txt_No_of_users =
"N&ordm; de utilizadores";
#endif
const char *Txt_No_of_users_who_will_be_notified_by_email =
#if L==1
"N&ordm; de usuarios que ser&aacute;n notificados por correo"; // Necessita traduccio
#elif L==2
"Anzahl der Benutzer, um benachrichtigt zu werden per E-Mail";
#elif L==3
"No. of users who will be notified by email";
#elif L==4
"N&ordm; de usuarios que ser&aacute;n notificados por correo";
#elif L==5
"Nombre d'utilisateurs qui seront notifi&eacute;s par email";
#elif L==6
"N&ordm; de usuarios que ser&aacute;n notificados por correo"; // Okoteve traducción
#elif L==7
"Numero di utenti che saranno notificati via email";
#elif L==8
"Liczba uzytkownik&oacute;w, kt&oacute;rzy zostana powiadomieni przez email";
#elif L==9
"N&ordm; de utilizadores que ser&atilde;o notificados por email";
#endif
const char *Txt_No_questions_found_matching_your_search_criteria =
#if L==1
"No hay preguntas con el criterio de b&uacute;squeda seleccionado."; // Necessita traduccio