mirror of https://github.com/acanas/swad-core.git
Version 17.4.1
This commit is contained in:
parent
ce3c69241e
commit
ea4c3d5703
|
@ -252,13 +252,14 @@
|
||||||
/****************************** Public constants *****************************/
|
/****************************** Public constants *****************************/
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
||||||
#define Log_PLATFORM_VERSION "SWAD 17.4 (2017-09-20)"
|
#define Log_PLATFORM_VERSION "SWAD 17.4.1 (2017-09-20)"
|
||||||
#define CSS_FILE "swad17.0.css"
|
#define CSS_FILE "swad17.0.css"
|
||||||
#define JS_FILE "swad16.206.3.js"
|
#define JS_FILE "swad16.206.3.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 17.4.1: Sep 20, 2017 Changes adding users to a project. Not finished. (230141 lines)
|
||||||
Version 17.4: Sep 20, 2017 Actions to add users to a project. (230137 lines)
|
Version 17.4: Sep 20, 2017 Actions to add users to a project. (230137 lines)
|
||||||
6 changes necessary in database:
|
6 changes necessary in database:
|
||||||
INSERT INTO actions (ActCod,Language,Obsolete,Txt) VALUES ('1684','es','N','Solicitar ID añadir estudiante a proyecto');
|
INSERT INTO actions (ActCod,Language,Obsolete,Txt) VALUES ('1684','es','N','Solicitar ID añadir estudiante a proyecto');
|
||||||
|
|
|
@ -346,10 +346,10 @@ static void Enr_NotifyAfterEnrolment (struct UsrData *UsrDat,Rol_Role_t NewRole)
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
/****** Write a form to request another user's ID, @nickname or email *******/
|
/****** Write a form to request another user's ID, @nickname or email ********/
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
||||||
void Enr_WriteFormToReqAnotherUsrID (Act_Action_t NextAction)
|
void Enr_WriteFormToReqAnotherUsrID (Act_Action_t NextAction,void (*FuncParams) ())
|
||||||
{
|
{
|
||||||
extern const char *The_ClassForm[The_NUM_THEMES];
|
extern const char *The_ClassForm[The_NUM_THEMES];
|
||||||
extern const char *Txt_nick_email_or_ID;
|
extern const char *Txt_nick_email_or_ID;
|
||||||
|
@ -357,6 +357,8 @@ void Enr_WriteFormToReqAnotherUsrID (Act_Action_t NextAction)
|
||||||
|
|
||||||
/***** Form to request user's ID, @nickname or email address *****/
|
/***** Form to request user's ID, @nickname or email address *****/
|
||||||
Act_FormStart (NextAction);
|
Act_FormStart (NextAction);
|
||||||
|
if (FuncParams)
|
||||||
|
FuncParams ();
|
||||||
fprintf (Gbl.F.Out,"<label class=\"%s RIGHT_MIDDLE\">"
|
fprintf (Gbl.F.Out,"<label class=\"%s RIGHT_MIDDLE\">"
|
||||||
"%s: "
|
"%s: "
|
||||||
"<input type=\"text\" name=\"OtherUsrIDNickOrEMail\""
|
"<input type=\"text\" name=\"OtherUsrIDNickOrEMail\""
|
||||||
|
@ -3152,7 +3154,7 @@ static void Enr_ReqAnotherUsrIDToRegisterRemove (Rol_Role_t Role)
|
||||||
Lay_ShowErrorAndExit ("Wrong role.");
|
Lay_ShowErrorAndExit ("Wrong role.");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
Enr_WriteFormToReqAnotherUsrID (NextAction);
|
Enr_WriteFormToReqAnotherUsrID (NextAction,NULL);
|
||||||
|
|
||||||
/***** End box *****/
|
/***** End box *****/
|
||||||
Box_EndBox ();
|
Box_EndBox ();
|
||||||
|
|
|
@ -79,7 +79,7 @@ void Enr_ModifyRoleInCurrentCrs (struct UsrData *UsrDat,Rol_Role_t NewRole);
|
||||||
void Enr_RegisterUsrInCurrentCrs (struct UsrData *UsrDat,Rol_Role_t NewRole,
|
void Enr_RegisterUsrInCurrentCrs (struct UsrData *UsrDat,Rol_Role_t NewRole,
|
||||||
Enr_KeepOrSetAccepted_t KeepOrSetAccepted);
|
Enr_KeepOrSetAccepted_t KeepOrSetAccepted);
|
||||||
|
|
||||||
void Enr_WriteFormToReqAnotherUsrID (Act_Action_t NextAction);
|
void Enr_WriteFormToReqAnotherUsrID (Act_Action_t NextAction,void (*FuncParams) ());
|
||||||
|
|
||||||
void Enr_ReqAcceptRegisterInCrs (void);
|
void Enr_ReqAcceptRegisterInCrs (void);
|
||||||
void Enr_GetNotifEnrolment (char SummaryStr[Ntf_MAX_BYTES_SUMMARY + 1],
|
void Enr_GetNotifEnrolment (char SummaryStr[Ntf_MAX_BYTES_SUMMARY + 1],
|
||||||
|
|
|
@ -85,7 +85,7 @@ static void Prj_ShowOneProjectUsrsRow (const struct Project *Prj,bool PrintView,
|
||||||
const char *Label,Prj_RoleInProject_t RoleInProject);
|
const char *Label,Prj_RoleInProject_t RoleInProject);
|
||||||
static void Prj_WriteUsrs (long PrjCod,Prj_RoleInProject_t RoleInProject);
|
static void Prj_WriteUsrs (long PrjCod,Prj_RoleInProject_t RoleInProject);
|
||||||
static void Prj_ReqAnotherUsrID (Prj_RoleInProject_t RoleInProject);
|
static void Prj_ReqAnotherUsrID (Prj_RoleInProject_t RoleInProject);
|
||||||
static void Prj_AddUsrToProject (Prj_RoleInProject_t RoleInProject)
|
static void Prj_AddUsrToProject (Prj_RoleInProject_t RoleInProject);
|
||||||
|
|
||||||
static void Prj_GetParamPrjOrder (void);
|
static void Prj_GetParamPrjOrder (void);
|
||||||
|
|
||||||
|
@ -549,7 +549,7 @@ static void Prj_WriteUsrs (long PrjCod,Prj_RoleInProject_t RoleInProject)
|
||||||
bool UsrValid;
|
bool UsrValid;
|
||||||
bool ShowPhoto;
|
bool ShowPhoto;
|
||||||
char PhotoURL[PATH_MAX + 1];
|
char PhotoURL[PATH_MAX + 1];
|
||||||
Act_Action_t ActionReqAddUsr[Prj_NUM_ROLES_IN_PROJECT] =
|
static Act_Action_t ActionReqAddUsr[Prj_NUM_ROLES_IN_PROJECT] =
|
||||||
{
|
{
|
||||||
ActUnk, // Prj_ROLE_UNK, Unknown
|
ActUnk, // Prj_ROLE_UNK, Unknown
|
||||||
ActReqAddStdPrj, // Prj_ROLE_STD, Student
|
ActReqAddStdPrj, // Prj_ROLE_STD, Student
|
||||||
|
@ -673,15 +673,11 @@ void Prj_ReqAddRev (void)
|
||||||
Prj_ReqAnotherUsrID (Prj_ROLE_REV);
|
Prj_ReqAnotherUsrID (Prj_ROLE_REV);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****************************************************************************/
|
|
||||||
/****** Write a form to request another user's ID, @nickname or email ********/
|
|
||||||
/*****************************************************************************/
|
|
||||||
|
|
||||||
static void Prj_ReqAnotherUsrID (Prj_RoleInProject_t RoleInProject)
|
static void Prj_ReqAnotherUsrID (Prj_RoleInProject_t RoleInProject)
|
||||||
{
|
{
|
||||||
extern const char *Hlp_ASSESSMENT_Projects_add_user;
|
extern const char *Hlp_ASSESSMENT_Projects_add_user;
|
||||||
extern const char *Txt_Add_user;
|
extern const char *Txt_Add_user;
|
||||||
Act_Action_t ActionAddUsr[Prj_NUM_ROLES_IN_PROJECT] =
|
static Act_Action_t ActionAddUsr[Prj_NUM_ROLES_IN_PROJECT] =
|
||||||
{
|
{
|
||||||
ActUnk, // Prj_ROLE_UNK, Unknown
|
ActUnk, // Prj_ROLE_UNK, Unknown
|
||||||
ActAddStdPrj, // Prj_ROLE_STD, Student
|
ActAddStdPrj, // Prj_ROLE_STD, Student
|
||||||
|
@ -689,12 +685,16 @@ static void Prj_ReqAnotherUsrID (Prj_RoleInProject_t RoleInProject)
|
||||||
ActAddRevPrj, // Prj_ROLE_REV, Reviewer
|
ActAddRevPrj, // Prj_ROLE_REV, Reviewer
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/***** Get project code *****/
|
||||||
|
if ((Gbl.Prjs.PrjCodToEdit = Prj_GetParamPrjCod ()) == -1L)
|
||||||
|
Lay_ShowErrorAndExit ("Code of project is missing.");
|
||||||
|
|
||||||
/***** Start box *****/
|
/***** Start box *****/
|
||||||
Box_StartBox (NULL,Txt_Add_user,NULL,
|
Box_StartBox (NULL,Txt_Add_user,NULL,
|
||||||
Hlp_ASSESSMENT_Projects_add_user,Box_NOT_CLOSABLE);
|
Hlp_ASSESSMENT_Projects_add_user,Box_NOT_CLOSABLE);
|
||||||
|
|
||||||
/***** Write form to request another user's ID *****/
|
/***** Write form to request another user's ID *****/
|
||||||
Enr_WriteFormToReqAnotherUsrID (ActionAddUsr[RoleInProject]);
|
Enr_WriteFormToReqAnotherUsrID (ActionAddUsr[RoleInProject],Prj_PutParams);
|
||||||
|
|
||||||
/***** End box *****/
|
/***** End box *****/
|
||||||
Box_EndBox ();
|
Box_EndBox ();
|
||||||
|
@ -721,7 +721,8 @@ void Prj_AddRev (void)
|
||||||
|
|
||||||
static void Prj_AddUsrToProject (Prj_RoleInProject_t RoleInProject)
|
static void Prj_AddUsrToProject (Prj_RoleInProject_t RoleInProject)
|
||||||
{
|
{
|
||||||
Ale_ShowAlert (Ale_WARNING,"Not yet implemented.");
|
if (RoleInProject != Prj_ROLE_UNK) // TODO: Remove
|
||||||
|
Ale_ShowAlert (Ale_WARNING,"Not yet implemented.");
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
Loading…
Reference in New Issue