Version 15.246.1

This commit is contained in:
Antonio Cañas Vargas 2016-07-26 02:41:31 +02:00
parent b80475ac0e
commit 8bb17ae3ae
3 changed files with 40 additions and 37 deletions

View File

@ -1923,13 +1923,14 @@ static void Att_ListAttStudents (struct AttendanceEvent *Att)
NumStd < Gbl.Usrs.LstUsrs[Rol_STUDENT].NumUsrs; NumStd < Gbl.Usrs.LstUsrs[Rol_STUDENT].NumUsrs;
NumStd++) NumStd++)
{ {
UsrDat.UsrCod = Gbl.Usrs.LstUsrs[Rol_STUDENT].Lst[NumStd].UsrCod; /* Copy user's basic data from list */
if (Usr_ChkUsrCodAndGetAllUsrDataFromUsrCod (&UsrDat)) // If user's data exist... Usr_CopyBasicUsrDataFromList (&UsrDat,&Gbl.Usrs.LstUsrs[Rol_STUDENT].Lst[NumStd]);
{
UsrDat.Accepted = Gbl.Usrs.LstUsrs[Rol_STUDENT].Lst[NumStd].Accepted; /* Get list of user's IDs */
ID_GetListIDsFromUsrCod (&UsrDat);
Att_WriteRowStdToCallTheRoll (NumStd + 1,&UsrDat,Att); Att_WriteRowStdToCallTheRoll (NumStd + 1,&UsrDat,Att);
} }
}
/* Send button and end frame */ /* Send button and end frame */
Lay_EndRoundFrameTableWithButton (Lay_CONFIRM_BUTTON,Txt_Save); Lay_EndRoundFrameTableWithButton (Lay_CONFIRM_BUTTON,Txt_Save);
@ -2226,7 +2227,7 @@ void Att_RegisterStudentsInAttEvent (void)
{ {
Par_GetNextStrUntilSeparParamMult (&Ptr,UsrData.EncryptedUsrCod,Cry_LENGTH_ENCRYPTED_STR_SHA256_BASE64); Par_GetNextStrUntilSeparParamMult (&Ptr,UsrData.EncryptedUsrCod,Cry_LENGTH_ENCRYPTED_STR_SHA256_BASE64);
Usr_GetUsrCodFromEncryptedUsrCod (&UsrData); Usr_GetUsrCodFromEncryptedUsrCod (&UsrData);
if (Usr_ChkUsrCodAndGetAllUsrDataFromUsrCod (&UsrData)) // Get student's data from the database if (UsrData.UsrCod > 0) // Student exists in database
/***** Mark student to not be removed *****/ /***** Mark student to not be removed *****/
for (NumStd = 0; for (NumStd = 0;
NumStd < Gbl.Usrs.LstUsrs[Rol_STUDENT].NumUsrs; NumStd < Gbl.Usrs.LstUsrs[Rol_STUDENT].NumUsrs;

View File

@ -136,13 +136,14 @@
/****************************** Public constants *****************************/ /****************************** Public constants *****************************/
/*****************************************************************************/ /*****************************************************************************/
#define Log_PLATFORM_VERSION "SWAD 15.246 (2016-07-26)" #define Log_PLATFORM_VERSION "SWAD 15.246.1 (2016-07-26)"
#define CSS_FILE "swad15.229.css" #define CSS_FILE "swad15.229.css"
#define JS_FILE "swad15.238.1.js" #define JS_FILE "swad15.238.1.js"
// Number of lines (includes comments but not blank lines) has been got with the following command: // 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 // nl swad*.c swad*.h css/swad*.css py/swad*.py js/swad*.js soap/swad*.h sql/swad*.sql | tail -1
/* /*
Version 15.246.1: Jul 26, 2016 Attendance of users and e-mail to users use the list filled instead of querying database a second time to get all user's data. (204093 lines)
Version 15.246: Jul 26, 2016 Classphoto of users uses the list filled instead of querying database a second time to get all user's data. Version 15.246: Jul 26, 2016 Classphoto of users uses the list filled instead of querying database a second time to get all user's data.
Origin place is removed from classphoto. (204094 lines) Origin place is removed from classphoto. (204094 lines)
Version 15.245.5: Jul 26, 2016 Fixed bug in user's data. (204116 lines) Version 15.245.5: Jul 26, 2016 Fixed bug in user's data. (204116 lines)

View File

@ -815,10 +815,12 @@ void Mai_ListEMails (void)
NumUsr < Gbl.Usrs.LstUsrs[Rol_STUDENT].NumUsrs; NumUsr < Gbl.Usrs.LstUsrs[Rol_STUDENT].NumUsrs;
NumUsr++) NumUsr++)
{ {
UsrDat.UsrCod = Gbl.Usrs.LstUsrs[Rol_STUDENT].Lst[NumUsr].UsrCod; /* Copy user's basic data from list */
if (Usr_ChkUsrCodAndGetAllUsrDataFromUsrCod (&UsrDat)) // If user's data exist... Usr_CopyBasicUsrDataFromList (&UsrDat,&Gbl.Usrs.LstUsrs[Rol_STUDENT].Lst[NumUsr]);
{
UsrDat.Accepted = Gbl.Usrs.LstUsrs[Rol_STUDENT].Lst[NumUsr].Accepted; /* Get user's e-mail */
Mai_GetEmailFromUsrCod (&UsrDat);
if (UsrDat.Email[0]) if (UsrDat.Email[0])
{ {
NumStdsWithEmail++; NumStdsWithEmail++;
@ -846,7 +848,6 @@ void Mai_ListEMails (void)
} }
} }
} }
}
fprintf (Gbl.F.Out,"</td>" fprintf (Gbl.F.Out,"</td>"
"</tr>"); "</tr>");