mirror of https://github.com/acanas/swad-core.git
Version 18.10.1
This commit is contained in:
parent
e9cb6f21dc
commit
482e2f27c8
|
@ -233,7 +233,7 @@ unsigned ID_GetListUsrCodsFromUsrID (struct UsrData *UsrDat,
|
|||
Str_Concat (Query," AND Confirmed='Y'",
|
||||
MaxLength);
|
||||
|
||||
ListUsrCods->NumUsrs = (unsigned) DB_QuerySELECT (Query,&mysql_res,"can not get user's codes");
|
||||
ListUsrCods->NumUsrs = (unsigned) DB_QuerySELECT (&Query,&mysql_res,"can not get user's codes");
|
||||
if (ListUsrCods->NumUsrs)
|
||||
{
|
||||
/***** Allocate space for the list of users' codes *****/
|
||||
|
|
|
@ -2452,7 +2452,7 @@ static unsigned Att_GetNumStdsFromAListWhoAreInAttEvent (long AttCod,long LstSel
|
|||
MaxLength);
|
||||
|
||||
|
||||
NumStdsInAttEvent = (unsigned) DB_QueryCOUNT_new ("can not get number of students from a list who are registered in an event");
|
||||
NumStdsInAttEvent = (unsigned) DB_QueryCOUNT (&Query,"can not get number of students from a list who are registered in an event");
|
||||
}
|
||||
return NumStdsInAttEvent;
|
||||
}
|
||||
|
|
|
@ -355,10 +355,11 @@ En OpenSWAD:
|
|||
ps2pdf source.ps destination.pdf
|
||||
*/
|
||||
|
||||
#define Log_PLATFORM_VERSION "SWAD 18.10 (2018-10-30)"
|
||||
#define Log_PLATFORM_VERSION "SWAD 18.10.1 (2018-10-30)"
|
||||
#define CSS_FILE "swad18.4.css"
|
||||
#define JS_FILE "swad17.17.1.js"
|
||||
/*
|
||||
Version 18.10.1: Oct 30, 2018 Fixed bugs in access to database. (235399 lines)
|
||||
Version 18.10: Oct 30, 2018 Fixing bugs in access to database. Not finished. (235399 lines)
|
||||
Version 18.9.10: Oct 30, 2018 Some sprintf for database queries changed by asprintf. (235311 lines)
|
||||
Version 18.9.8: Oct 30, 2018 Cleaning unused functions. (235694 lines)
|
||||
|
|
|
@ -349,7 +349,7 @@ void Sta_LogAccess (const char *Comments)
|
|||
Str_Concat (Query,"')",
|
||||
MaxLength);
|
||||
|
||||
DB_QueryINSERT (Query,"can not log access (comments)");
|
||||
DB_QueryINSERT (&Query,"can not log access (comments)");
|
||||
}
|
||||
|
||||
if (Gbl.Search.LogSearch && Gbl.Search.Str[0])
|
||||
|
@ -370,7 +370,7 @@ void Sta_LogAccess (const char *Comments)
|
|||
Str_Concat (Query,"')",
|
||||
MaxLength);
|
||||
|
||||
DB_QueryINSERT (Query,"can not log access (search)");
|
||||
DB_QueryINSERT (&Query,"can not log access (search)");
|
||||
}
|
||||
|
||||
if (Gbl.WebService.IsWebService)
|
||||
|
@ -1484,7 +1484,7 @@ static void Sta_ShowHits (Sta_GlobalOrCourseAccesses_t GlobalOrCourse)
|
|||
Ale_ShowAlert (Ale_INFO,Query);
|
||||
*/
|
||||
/***** Make the query *****/
|
||||
NumRows = DB_QuerySELECT (Query,&mysql_res,"can not get clicks");
|
||||
NumRows = DB_QuerySELECT (&Query,&mysql_res,"can not get clicks");
|
||||
|
||||
/***** Count the number of rows in result *****/
|
||||
if (NumRows == 0)
|
||||
|
|
|
@ -2635,7 +2635,7 @@ static unsigned long Tst_GetQuestions (MYSQL_RES **mysql_res)
|
|||
}
|
||||
|
||||
/* Make the query */
|
||||
NumRows = DB_QuerySELECT (Query,mysql_res,"can not get questions");
|
||||
NumRows = DB_QuerySELECT (&Query,mysql_res,"can not get questions");
|
||||
|
||||
if (NumRows == 0)
|
||||
Ale_ShowAlert (Ale_INFO,Txt_No_questions_found_matching_your_search_criteria);
|
||||
|
@ -2771,7 +2771,7 @@ static unsigned long Tst_GetQuestionsForTest (MYSQL_RES **mysql_res)
|
|||
Lay_ShowAlert (Lay_INFO,Query);
|
||||
*/
|
||||
/* Make the query */
|
||||
return DB_QuerySELECT (Query,mysql_res,"can not get questions");
|
||||
return DB_QuerySELECT (&Query,mysql_res,"can not get questions");
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
|
|
|
@ -4177,10 +4177,6 @@ static void Usr_BuildQueryToGetUsrsLstCrs (char **Query,Rol_Role_t Role)
|
|||
return;
|
||||
}
|
||||
|
||||
/***** Get list of groups types in current course *****/
|
||||
if (!Gbl.Usrs.ClassPhoto.AllGroups)
|
||||
Grp_GetListGrpTypesInThisCrs (Grp_ONLY_GROUP_TYPES_WITH_GROUPS);
|
||||
|
||||
/***** Allocate space for query *****/
|
||||
if ((*Query = (char *) malloc (Usr_MAX_BYTES_QUERY_GET_LIST_USRS + 1)) == NULL)
|
||||
Lay_NotEnoughMemoryExit ();
|
||||
|
@ -4209,6 +4205,9 @@ static void Usr_BuildQueryToGetUsrsLstCrs (char **Query,Rol_Role_t Role)
|
|||
/***** Select users in selected groups *****/
|
||||
if (!Gbl.Usrs.ClassPhoto.AllGroups)
|
||||
{
|
||||
/***** Get list of groups types in current course *****/
|
||||
Grp_GetListGrpTypesInThisCrs (Grp_ONLY_GROUP_TYPES_WITH_GROUPS);
|
||||
|
||||
/***** Allocate memory for list of booleans AddStdsWithoutGroupOf *****/
|
||||
if ((AddStdsWithoutGroupOf = (bool *) calloc (Gbl.CurrentCrs.Grps.GrpTypes.Num,sizeof (bool))) == NULL)
|
||||
Lay_NotEnoughMemoryExit ();
|
||||
|
|
|
@ -2779,7 +2779,7 @@ int swad__sendAttendanceUsers (struct soap *soap,
|
|||
Str_Concat (Query,")",
|
||||
Length);
|
||||
|
||||
DB_QueryUPDATE (Query,"can not set other users as absent");
|
||||
DB_QueryUPDATE (&Query,"can not set other users as absent");
|
||||
|
||||
/* Clean table att_usr */
|
||||
Att_RemoveUsrsAbsentWithoutCommentsFromAttEvent (Att.AttCod);
|
||||
|
@ -3296,7 +3296,7 @@ int swad__sendMessage (struct soap *soap,
|
|||
if (ReplyUsrCod > 0 || ThereAreNicknames) // There are a recipient to reply or nicknames in "to"
|
||||
{
|
||||
/***** Get users *****/
|
||||
NumRows = DB_QuerySELECT (Query,&mysql_res,"can not get users");
|
||||
NumRows = DB_QuerySELECT (&Query,&mysql_res,"can not get users");
|
||||
|
||||
sendMessageOut->numUsers = (int) NumRows;
|
||||
sendMessageOut->usersArray.__size = (int) NumRows;
|
||||
|
|
Loading…
Reference in New Issue