Version18.68.1

This commit is contained in:
Antonio Cañas Vargas 2019-03-08 01:18:31 +01:00
parent 7f459e65fa
commit 1559be56e0
2 changed files with 7 additions and 16 deletions

View File

@ -447,10 +447,11 @@ En OpenSWAD:
ps2pdf source.ps destination.pdf
*/
#define Log_PLATFORM_VERSION "SWAD 18.68 (2019-03-07)"
#define Log_PLATFORM_VERSION "SWAD 18.68.1 (2019-03-08)"
#define CSS_FILE "swad18.67.css"
#define JS_FILE "swad18.64.js"
/*
Version 18.68.1: Mar 08, 2019 A teacher can register students in groups, even if he/she doesn't belong to them. (238910 lines)
Version 18.68: Mar 07, 2019 Photo is zoomed even in record card.
Teachers record cards are only visible inside courses.
Fixed bug in notifications. (238918 lines)

View File

@ -2085,7 +2085,7 @@ static bool Grp_ListGrpsForChangeMySelection (struct GroupType *GrpTyp,
/*****************************************************************************/
/*************** Show list of groups to register/remove users ****************/
/*****************************************************************************/
// If UsrCod > 0 ==> mark her/his groups as checked
// If UsrCod > 0 ==> mark her/his groups as checked
// If UsrCod <= 0 ==> do not mark any group as checked
void Grp_ShowLstGrpsToChgOtherUsrsGrps (long UsrCod)
@ -2118,26 +2118,20 @@ void Grp_ShowLstGrpsToChgOtherUsrsGrps (long UsrCod)
/*****************************************************************************/
/*************** List groups of a type to add or remove users ****************/
/*****************************************************************************/
// If UsrCod > 0 ==> mark her/his groups as checked
// If UsrCod > 0 ==> mark her/his groups as checked
// If UsrCod <= 0 ==> do not mark any group as checked
static void Grp_ListGrpsToAddOrRemUsrs (struct GroupType *GrpTyp,long UsrCod)
{
struct ListCodGrps LstGrpsIBelong;
struct ListCodGrps LstGrpsUsrBelongs;
unsigned NumGrpThisType;
bool IBelongToThisGroup;
bool UsrBelongsToThisGroup;
struct Group *Grp;
/***** Write heading *****/
Grp_WriteGrpHead (GrpTyp);
/***** Query from the database the groups of this type which I belong to *****/
Grp_GetLstCodGrpsUsrBelongs (Gbl.CurrentCrs.Crs.CrsCod,GrpTyp->GrpTypCod,
Gbl.Usrs.Me.UsrDat.UsrCod,&LstGrpsIBelong);
/***** Query from the database the groups of this type which I belong to *****/
/***** Query the groups of this type which the user belongs to *****/
if (UsrCod > 0)
Grp_GetLstCodGrpsUsrBelongs (Gbl.CurrentCrs.Crs.CrsCod,GrpTyp->GrpTypCod,
Gbl.Usrs.Other.UsrDat.UsrCod,&LstGrpsUsrBelongs);
@ -2148,7 +2142,6 @@ static void Grp_ListGrpsToAddOrRemUsrs (struct GroupType *GrpTyp,long UsrCod)
NumGrpThisType++)
{
Grp = &(GrpTyp->LstGrps[NumGrpThisType]);
IBelongToThisGroup = Grp_CheckIfGrpIsInList (Grp->GrpCod,&LstGrpsIBelong);
UsrBelongsToThisGroup = (UsrCod > 0) ? Grp_CheckIfGrpIsInList (Grp->GrpCod,&LstGrpsUsrBelongs) :
false;
@ -2164,10 +2157,8 @@ static void Grp_ListGrpsToAddOrRemUsrs (struct GroupType *GrpTyp,long UsrCod)
Grp->GrpCod);
if (UsrBelongsToThisGroup)
fprintf (Gbl.F.Out," checked=\"checked\"");
if (!(IBelongToThisGroup ||
Gbl.Usrs.Me.Role.Logged == Rol_SYS_ADM))
fprintf (Gbl.F.Out," disabled=\"disabled\"");
fprintf (Gbl.F.Out," /></td>");
fprintf (Gbl.F.Out," />"
"</td>");
Grp_WriteRowGrp (Grp,UsrBelongsToThisGroup);
@ -2177,7 +2168,6 @@ static void Grp_ListGrpsToAddOrRemUsrs (struct GroupType *GrpTyp,long UsrCod)
/***** Free memory with the lists of groups *****/
if (UsrCod > 0)
Grp_FreeListCodGrp (&LstGrpsUsrBelongs);
Grp_FreeListCodGrp (&LstGrpsIBelong);
}
/*****************************************************************************/