mirror of
https://github.com/acanas/swad-core.git
synced 2024-06-05 00:05:23 +02:00
Version 16.41.1
This commit is contained in:
parent
2201a0aaa6
commit
9d11e9bff3
|
@ -150,13 +150,14 @@
|
|||
/****************************** Public constants *****************************/
|
||||
/*****************************************************************************/
|
||||
|
||||
#define Log_PLATFORM_VERSION "SWAD 16.41 (2016-10-23)"
|
||||
#define Log_PLATFORM_VERSION "SWAD 16.41.1 (2016-10-23)"
|
||||
#define CSS_FILE "swad16.32.1.css"
|
||||
#define JS_FILE "swad15.238.1.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.41.1: Oct 23, 2016 Code refactoring in courses. (205443 lines)
|
||||
Version 16.41: Oct 23, 2016 New form in degree configuration to change short name. (205453 lines)
|
||||
1 change necessary in database:
|
||||
INSERT INTO actions (ActCod,Language,Obsolete,Txt) VALUES ('1601','es','N','Cambiar nombre breve asignatura');
|
||||
|
|
|
@ -104,7 +104,6 @@ static void Crs_UpdateCrsYear (struct Course *Crs,unsigned NewYear);
|
|||
|
||||
static void Crs_EmptyCourseCompletely (long CrsCod);
|
||||
|
||||
static void Crs_GetCrsCodFromForm (void);
|
||||
static void Crs_RenameCourse (struct Course *Crs,Cns_ShortOrFullName_t ShortOrFullName);
|
||||
static void Crs_PutButtonToGoToCrs (struct Course *Crs);
|
||||
static void Crs_PutButtonToRegisterInCrs (struct Course *Crs);
|
||||
|
@ -1980,8 +1979,7 @@ void Crs_RemoveCourse (void)
|
|||
struct Course Crs;
|
||||
|
||||
/***** Get course code *****/
|
||||
if ((Crs.CrsCod = Crs_GetParamOtherCrsCod ()) == -1L)
|
||||
Lay_ShowErrorAndExit ("Code of course is missing.");
|
||||
Crs.CrsCod = Crs_GetParamOtherCrsCod ();
|
||||
|
||||
/***** Get data of the course from database *****/
|
||||
Crs_GetDataOfCourseByCod (&Crs);
|
||||
|
@ -2374,8 +2372,7 @@ void Crs_ChangeInsCrsCod (void)
|
|||
|
||||
/***** Get parameters from form *****/
|
||||
/* Get course code */
|
||||
if ((Crs->CrsCod = Crs_GetParamOtherCrsCod ()) == -1L)
|
||||
Lay_ShowErrorAndExit ("Code of course is missing.");
|
||||
Crs->CrsCod = Crs_GetParamOtherCrsCod ();
|
||||
|
||||
/* Get institutional code */
|
||||
Par_GetParToText ("InsCrsCod",NewInstitutionalCrsCod,Crs_LENGTH_INSTITUTIONAL_CRS_COD);
|
||||
|
@ -2558,8 +2555,7 @@ void Crs_ChangeCrsYear (void)
|
|||
|
||||
/***** Get parameters from form *****/
|
||||
/* Get course code */
|
||||
if ((Crs->CrsCod = Crs_GetParamOtherCrsCod ()) == -1L)
|
||||
Lay_ShowErrorAndExit ("Code of course is missing.");
|
||||
Crs->CrsCod = Crs_GetParamOtherCrsCod ();
|
||||
|
||||
/* Get parameter with year */
|
||||
Par_GetParToText ("OthCrsYear",YearStr,2);
|
||||
|
@ -2653,7 +2649,7 @@ void Crs_UpdateInstitutionalCrsCod (struct Course *Crs,const char *NewInstitutio
|
|||
|
||||
void Crs_RenameCourseShort (void)
|
||||
{
|
||||
Crs_GetCrsCodFromForm ();
|
||||
Gbl.Degs.EditingCrs.CrsCod = Crs_GetParamOtherCrsCod ();
|
||||
Crs_RenameCourse (&Gbl.Degs.EditingCrs,Cns_SHORT_NAME);
|
||||
}
|
||||
|
||||
|
@ -2668,7 +2664,7 @@ void Crs_RenameCourseShortInConfig (void)
|
|||
|
||||
void Crs_RenameCourseFull (void)
|
||||
{
|
||||
Crs_GetCrsCodFromForm ();
|
||||
Gbl.Degs.EditingCrs.CrsCod = Crs_GetParamOtherCrsCod ();
|
||||
Crs_RenameCourse (&Gbl.Degs.EditingCrs,Cns_FULL_NAME);
|
||||
}
|
||||
|
||||
|
@ -2677,17 +2673,6 @@ void Crs_RenameCourseFullInConfig (void)
|
|||
Crs_RenameCourse (&Gbl.CurrentCrs.Crs,Cns_FULL_NAME);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
/************************ Get the code of the course *************************/
|
||||
/*****************************************************************************/
|
||||
|
||||
static void Crs_GetCrsCodFromForm (void)
|
||||
{
|
||||
/***** Get the code of the course *****/
|
||||
if ((Gbl.Degs.EditingCrs.CrsCod = Crs_GetParamOtherCrsCod ()) < 0)
|
||||
Lay_ShowErrorAndExit ("Code of course is missing.");
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
/************************ Change the name of a course ************************/
|
||||
/*****************************************************************************/
|
||||
|
@ -2796,8 +2781,7 @@ void Crs_ChangeCrsStatus (void)
|
|||
|
||||
/***** Get parameters from form *****/
|
||||
/* Get course code */
|
||||
if ((Crs->CrsCod = Crs_GetParamOtherCrsCod ()) == -1L)
|
||||
Lay_ShowErrorAndExit ("Code of course is missing.");
|
||||
Crs->CrsCod = Crs_GetParamOtherCrsCod ();
|
||||
|
||||
/* Get parameter with status */
|
||||
Par_GetParToText ("Status",UnsignedNum,1);
|
||||
|
@ -3000,10 +2984,14 @@ static void Crs_PutParamOtherCrsCod (long CrsCod)
|
|||
static long Crs_GetParamOtherCrsCod (void)
|
||||
{
|
||||
char LongStr[1+10+1];
|
||||
long CrsCod;
|
||||
|
||||
/***** Get parameter with code of course *****/
|
||||
Par_GetParToText ("OthCrsCod",LongStr,1+10);
|
||||
return Str_ConvertStrCodToLongCod (LongStr);
|
||||
if ((CrsCod = Str_ConvertStrCodToLongCod (LongStr)) < 0)
|
||||
Lay_ShowErrorAndExit ("Code of course is missing.");
|
||||
|
||||
return CrsCod;
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
|
|
Loading…
Reference in New Issue
Block a user