mirror of
https://github.com/acanas/swad-core.git
synced 2024-06-07 17:25:23 +02:00
Version19.156.1
This commit is contained in:
parent
536d042416
commit
5d3fb638ec
|
@ -13249,7 +13249,7 @@ INSERT INTO log SELECT * FROM log_full WHERE YEAR(ClickTime) = 2009; Hecho
|
||||||
INSERT INTO log SELECT * FROM log_full WHERE YEAR(ClickTime) = 2010; Hecho
|
INSERT INTO log SELECT * FROM log_full WHERE YEAR(ClickTime) = 2010; Hecho
|
||||||
INSERT INTO log SELECT * FROM log_full WHERE YEAR(ClickTime) = 2011; Hecho
|
INSERT INTO log SELECT * FROM log_full WHERE YEAR(ClickTime) = 2011; Hecho
|
||||||
INSERT INTO log SELECT * FROM log_full WHERE YEAR(ClickTime) = 2012; Hecho
|
INSERT INTO log SELECT * FROM log_full WHERE YEAR(ClickTime) = 2012; Hecho
|
||||||
INSERT INTO log SELECT * FROM log_full WHERE YEAR(ClickTime) = 2013;
|
INSERT INTO log SELECT * FROM log_full WHERE YEAR(ClickTime) = 2013; Hecho
|
||||||
INSERT INTO log SELECT * FROM log_full WHERE YEAR(ClickTime) = 2014;
|
INSERT INTO log SELECT * FROM log_full WHERE YEAR(ClickTime) = 2014;
|
||||||
INSERT INTO log SELECT * FROM log_full WHERE YEAR(ClickTime) = 2015;
|
INSERT INTO log SELECT * FROM log_full WHERE YEAR(ClickTime) = 2015;
|
||||||
INSERT INTO log SELECT * FROM log_full WHERE YEAR(ClickTime) = 2016;
|
INSERT INTO log SELECT * FROM log_full WHERE YEAR(ClickTime) = 2016;
|
||||||
|
@ -13262,5 +13262,8 @@ INSERT INTO log SELECT * FROM log_full WHERE YEAR(ClickTime) = 2019;
|
||||||
INSERT INTO log SELECT * FROM log_full WHERE YEAR(ClickTime) = 2020;
|
INSERT INTO log SELECT * FROM log_full WHERE YEAR(ClickTime) = 2020;
|
||||||
INSERT INTO log SELECT * FROM log_full WHERE YEAR(ClickTime) > 2020;
|
INSERT INTO log SELECT * FROM log_full WHERE YEAR(ClickTime) > 2020;
|
||||||
|
|
||||||
|
Si se quieren eliminar todos los datos de una partición:
|
||||||
|
ALTER TABLE log TRUNCATE PARTITION p2014;
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -580,7 +580,7 @@ static void Agd_WriteHeaderListEvents (Agd_AgendaType_t AgendaType)
|
||||||
/***** Table head *****/
|
/***** Table head *****/
|
||||||
HTM_TR_Begin (NULL);
|
HTM_TR_Begin (NULL);
|
||||||
|
|
||||||
for (Order = Agd_ORDER_BY_START_DATE;
|
for (Order = Agd_ORDER_BY_START_DATE;
|
||||||
Order <= Agd_ORDER_BY_END_DATE;
|
Order <= Agd_ORDER_BY_END_DATE;
|
||||||
Order++)
|
Order++)
|
||||||
{
|
{
|
||||||
|
|
|
@ -208,7 +208,7 @@ static void Asg_PutHeadForSeeing (bool PrintView)
|
||||||
HTM_TR_Begin (NULL);
|
HTM_TR_Begin (NULL);
|
||||||
|
|
||||||
HTM_TH (1,1,"CONTEXT_COL",NULL); // Column for contextual icons
|
HTM_TH (1,1,"CONTEXT_COL",NULL); // Column for contextual icons
|
||||||
for (Order = Dat_START_TIME;
|
for (Order = Dat_START_TIME;
|
||||||
Order <= Dat_END_TIME;
|
Order <= Dat_END_TIME;
|
||||||
Order++)
|
Order++)
|
||||||
{
|
{
|
||||||
|
|
|
@ -226,7 +226,7 @@ static void Att_ShowAllAttEvents (void)
|
||||||
HTM_TR_Begin (NULL);
|
HTM_TR_Begin (NULL);
|
||||||
|
|
||||||
HTM_TH (1,1,"CONTEXT_COL",NULL); // Column for contextual icons
|
HTM_TH (1,1,"CONTEXT_COL",NULL); // Column for contextual icons
|
||||||
for (Order = Dat_START_TIME;
|
for (Order = Dat_START_TIME;
|
||||||
Order <= Dat_END_TIME;
|
Order <= Dat_END_TIME;
|
||||||
Order++)
|
Order++)
|
||||||
{
|
{
|
||||||
|
|
|
@ -528,6 +528,7 @@ Param
|
||||||
El examen se muestra en pantalla tomándolo del examen en la base de datos, no del formulario.
|
El examen se muestra en pantalla tomándolo del examen en la base de datos, no del formulario.
|
||||||
Cuando el alumno pulsa en "He terminado" se le pregunta si está seguro y se vuelve a mostrar el examen cogiéndolo de la base de datos.
|
Cuando el alumno pulsa en "He terminado" se le pregunta si está seguro y se vuelve a mostrar el examen cogiéndolo de la base de datos.
|
||||||
|
|
||||||
|
Version 19.156.1: Mar 29, 2020 List of test exams with start date and end date. (284557 lines)
|
||||||
Version 19.156: Mar 28, 2020 New action to confirm assessment of test exam.
|
Version 19.156: Mar 28, 2020 New action to confirm assessment of test exam.
|
||||||
Code refactoring in test and matches. (284544 lines)
|
Code refactoring in test and matches. (284544 lines)
|
||||||
5 changes necessary in database:
|
5 changes necessary in database:
|
||||||
|
|
|
@ -120,7 +120,7 @@ void Dat_PutBoxToSelectDateFormat (void)
|
||||||
Format <= (Dat_Format_t) (Dat_NUM_OPTIONS_FORMAT - 1);
|
Format <= (Dat_Format_t) (Dat_NUM_OPTIONS_FORMAT - 1);
|
||||||
Format++)
|
Format++)
|
||||||
{
|
{
|
||||||
HTM_LI_Begin ("class=\%s\"",(Format == Gbl.Prefs.DateFormat) ? "DAT_N LIGHT_BLUE" :
|
HTM_LI_Begin ("class=\"%s\"",(Format == Gbl.Prefs.DateFormat) ? "DAT_N LIGHT_BLUE" :
|
||||||
"DAT");
|
"DAT");
|
||||||
HTM_LABEL_Begin (NULL);
|
HTM_LABEL_Begin (NULL);
|
||||||
HTM_INPUT_RADIO ("DateFormat",true,
|
HTM_INPUT_RADIO ("DateFormat",true,
|
||||||
|
|
|
@ -978,7 +978,7 @@ static void Hld_PutFormToCreateHoliday (void)
|
||||||
HTM_TH (1,1,"LM",Txt_Place);
|
HTM_TH (1,1,"LM",Txt_Place);
|
||||||
HTM_TH (1,1,"LM",Txt_Type);
|
HTM_TH (1,1,"LM",Txt_Type);
|
||||||
HTM_TH (1,1,"LM",Txt_START_END_TIME[Dat_START_TIME]);
|
HTM_TH (1,1,"LM",Txt_START_END_TIME[Dat_START_TIME]);
|
||||||
HTM_TH (1,1,"LM",Txt_START_END_TIME[Dat_END_TIME]);
|
HTM_TH (1,1,"LM",Txt_START_END_TIME[Dat_END_TIME ]);
|
||||||
HTM_TH (1,1,"LM",Txt_Holiday);
|
HTM_TH (1,1,"LM",Txt_Holiday);
|
||||||
|
|
||||||
HTM_TR_End ();
|
HTM_TR_End ();
|
||||||
|
@ -1070,7 +1070,7 @@ static void Hld_PutHeadHolidays (void)
|
||||||
HTM_TH (1,1,"LM",Txt_Place);
|
HTM_TH (1,1,"LM",Txt_Place);
|
||||||
HTM_TH (1,1,"LM",Txt_Type);
|
HTM_TH (1,1,"LM",Txt_Type);
|
||||||
HTM_TH (1,1,"LM",Txt_START_END_TIME[Dat_START_TIME]);
|
HTM_TH (1,1,"LM",Txt_START_END_TIME[Dat_START_TIME]);
|
||||||
HTM_TH (1,1,"LM",Txt_START_END_TIME[Dat_END_TIME]);
|
HTM_TH (1,1,"LM",Txt_START_END_TIME[Dat_END_TIME ]);
|
||||||
HTM_TH (1,1,"LM",Txt_Holiday);
|
HTM_TH (1,1,"LM",Txt_Holiday);
|
||||||
|
|
||||||
HTM_TR_End ();
|
HTM_TR_End ();
|
||||||
|
|
|
@ -501,7 +501,7 @@ static void Mch_ListOneOrMoreMatchesHeading (bool ICanEditMatches)
|
||||||
/***** The rest of columns *****/
|
/***** The rest of columns *****/
|
||||||
HTM_TH (1,1,"LT",Txt_ROLES_SINGUL_Abc[Rol_TCH][Usr_SEX_UNKNOWN]);
|
HTM_TH (1,1,"LT",Txt_ROLES_SINGUL_Abc[Rol_TCH][Usr_SEX_UNKNOWN]);
|
||||||
HTM_TH (1,1,"LT",Txt_START_END_TIME[Gam_ORDER_BY_START_DATE]);
|
HTM_TH (1,1,"LT",Txt_START_END_TIME[Gam_ORDER_BY_START_DATE]);
|
||||||
HTM_TH (1,1,"LT",Txt_START_END_TIME[Gam_ORDER_BY_END_DATE]);
|
HTM_TH (1,1,"LT",Txt_START_END_TIME[Gam_ORDER_BY_END_DATE ]);
|
||||||
HTM_TH (1,1,"LT",Txt_Match);
|
HTM_TH (1,1,"LT",Txt_Match);
|
||||||
HTM_TH (1,1,"RT",Txt_Players);
|
HTM_TH (1,1,"RT",Txt_Players);
|
||||||
HTM_TH (1,1,"CT",Txt_Status);
|
HTM_TH (1,1,"CT",Txt_Status);
|
||||||
|
|
|
@ -612,7 +612,7 @@ static void McR_ShowHeaderMchResults (Usr_MeOrOther_t MeOrOther)
|
||||||
HTM_TH (1,2,"CT",Txt_User[MeOrOther == Usr_ME ? Gbl.Usrs.Me.UsrDat.Sex :
|
HTM_TH (1,2,"CT",Txt_User[MeOrOther == Usr_ME ? Gbl.Usrs.Me.UsrDat.Sex :
|
||||||
Usr_SEX_UNKNOWN]);
|
Usr_SEX_UNKNOWN]);
|
||||||
HTM_TH (1,1,"LT",Txt_START_END_TIME[Dat_START_TIME]);
|
HTM_TH (1,1,"LT",Txt_START_END_TIME[Dat_START_TIME]);
|
||||||
HTM_TH (1,1,"LT",Txt_START_END_TIME[Dat_END_TIME]);
|
HTM_TH (1,1,"LT",Txt_START_END_TIME[Dat_END_TIME ]);
|
||||||
HTM_TH (1,1,"LT",Txt_Match);
|
HTM_TH (1,1,"LT",Txt_Match);
|
||||||
HTM_TH (1,1,"RT",Txt_Questions);
|
HTM_TH (1,1,"RT",Txt_Questions);
|
||||||
HTM_TH (1,1,"RT",Txt_Non_blank_BR_questions);
|
HTM_TH (1,1,"RT",Txt_Non_blank_BR_questions);
|
||||||
|
|
|
@ -266,7 +266,7 @@ static void TsR_ShowUsrsTstResults (void)
|
||||||
static void TsR_ShowHeaderTestResults (void)
|
static void TsR_ShowHeaderTestResults (void)
|
||||||
{
|
{
|
||||||
extern const char *Txt_User[Usr_NUM_SEXS];
|
extern const char *Txt_User[Usr_NUM_SEXS];
|
||||||
extern const char *Txt_Date;
|
extern const char *Txt_START_END_TIME[Dat_NUM_START_END_TIME];
|
||||||
extern const char *Txt_Questions;
|
extern const char *Txt_Questions;
|
||||||
extern const char *Txt_Non_blank_BR_questions;
|
extern const char *Txt_Non_blank_BR_questions;
|
||||||
extern const char *Txt_Score;
|
extern const char *Txt_Score;
|
||||||
|
@ -276,7 +276,8 @@ static void TsR_ShowHeaderTestResults (void)
|
||||||
HTM_TR_Begin (NULL);
|
HTM_TR_Begin (NULL);
|
||||||
|
|
||||||
HTM_TH (1,2,"CT",Txt_User[Usr_SEX_UNKNOWN]);
|
HTM_TH (1,2,"CT",Txt_User[Usr_SEX_UNKNOWN]);
|
||||||
HTM_TH (1,1,"RT",Txt_Date);
|
HTM_TH (1,1,"LT",Txt_START_END_TIME[Dat_START_TIME]);
|
||||||
|
HTM_TH (1,1,"LT",Txt_START_END_TIME[Dat_END_TIME ]);
|
||||||
HTM_TH (1,1,"RT",Txt_Questions);
|
HTM_TH (1,1,"RT",Txt_Questions);
|
||||||
HTM_TH (1,1,"RT",Txt_Non_blank_BR_questions);
|
HTM_TH (1,1,"RT",Txt_Non_blank_BR_questions);
|
||||||
HTM_TH (1,1,"RT",Txt_Score);
|
HTM_TH (1,1,"RT",Txt_Score);
|
||||||
|
@ -299,6 +300,7 @@ static void TsR_ShowTstResults (struct UsrData *UsrDat)
|
||||||
unsigned NumExams;
|
unsigned NumExams;
|
||||||
unsigned NumTest;
|
unsigned NumTest;
|
||||||
static unsigned UniqueId = 0;
|
static unsigned UniqueId = 0;
|
||||||
|
Dat_StartEndTime_t StartEndTime;
|
||||||
char *Id;
|
char *Id;
|
||||||
long TstCod;
|
long TstCod;
|
||||||
struct TsR_Result Result;
|
struct TsR_Result Result;
|
||||||
|
@ -312,6 +314,11 @@ static void TsR_ShowTstResults (struct UsrData *UsrDat)
|
||||||
char *ClassDat;
|
char *ClassDat;
|
||||||
|
|
||||||
/***** Make database query *****/
|
/***** Make database query *****/
|
||||||
|
/* From here... ...to here
|
||||||
|
___________|_____ _____|___________
|
||||||
|
-----|______Exam_|_____|-----------------|_____|_Exam______|-----> time
|
||||||
|
Start | End Start | End
|
||||||
|
*/
|
||||||
NumExams =
|
NumExams =
|
||||||
(unsigned) DB_QuerySELECT (&mysql_res,"can not get test exams of a user",
|
(unsigned) DB_QuerySELECT (&mysql_res,"can not get test exams of a user",
|
||||||
"SELECT TstCod," // row[0]
|
"SELECT TstCod," // row[0]
|
||||||
|
@ -323,8 +330,8 @@ static void TsR_ShowTstResults (struct UsrData *UsrDat)
|
||||||
"Score" // row[6]
|
"Score" // row[6]
|
||||||
" FROM tst_exams"
|
" FROM tst_exams"
|
||||||
" WHERE CrsCod=%ld AND UsrCod=%ld"
|
" WHERE CrsCod=%ld AND UsrCod=%ld"
|
||||||
" AND TstTime>=FROM_UNIXTIME(%ld)"
|
" AND EndTime>=FROM_UNIXTIME(%ld)"
|
||||||
" AND TstTime<=FROM_UNIXTIME(%ld)"
|
" AND StartTime<=FROM_UNIXTIME(%ld)"
|
||||||
" ORDER BY TstCod",
|
" ORDER BY TstCod",
|
||||||
Gbl.Hierarchy.Crs.CrsCod,
|
Gbl.Hierarchy.Crs.CrsCod,
|
||||||
UsrDat->UsrCod,
|
UsrDat->UsrCod,
|
||||||
|
@ -386,15 +393,20 @@ static void TsR_ShowTstResults (struct UsrData *UsrDat)
|
||||||
Result.TimeUTC[Dat_START_TIME] = Dat_GetUNIXTimeFromStr (row[1]);
|
Result.TimeUTC[Dat_START_TIME] = Dat_GetUNIXTimeFromStr (row[1]);
|
||||||
Result.TimeUTC[Dat_END_TIME ] = Dat_GetUNIXTimeFromStr (row[2]);
|
Result.TimeUTC[Dat_END_TIME ] = Dat_GetUNIXTimeFromStr (row[2]);
|
||||||
UniqueId++;
|
UniqueId++;
|
||||||
if (asprintf (&Id,"tst_date_%u",UniqueId) < 0)
|
for (StartEndTime = (Dat_StartEndTime_t) 0;
|
||||||
Lay_NotEnoughMemoryExit ();
|
StartEndTime <= (Dat_StartEndTime_t) (Dat_NUM_START_END_TIME - 1);
|
||||||
HTM_TD_Begin ("id=\"%s\" class=\"%s RT COLOR%u\"",
|
StartEndTime++)
|
||||||
Id,ClassDat,Gbl.RowEvenOdd);
|
{
|
||||||
Dat_WriteLocalDateHMSFromUTC (Id,Result.TimeUTC[Dat_END_TIME],
|
if (asprintf (&Id,"tst_date_%u_%u",(unsigned) StartEndTime,UniqueId) < 0)
|
||||||
Gbl.Prefs.DateFormat,Dat_SEPARATOR_COMMA,
|
Lay_NotEnoughMemoryExit ();
|
||||||
true,true,false,0x7);
|
HTM_TD_Begin ("id=\"%s\" class=\"%s LT COLOR%u\"",
|
||||||
HTM_TD_End ();
|
Id,ClassDat,Gbl.RowEvenOdd);
|
||||||
free (Id);
|
Dat_WriteLocalDateHMSFromUTC (Id,Result.TimeUTC[StartEndTime],
|
||||||
|
Gbl.Prefs.DateFormat,Dat_SEPARATOR_BREAK,
|
||||||
|
true,true,false,0x7);
|
||||||
|
HTM_TD_End ();
|
||||||
|
free (Id);
|
||||||
|
}
|
||||||
|
|
||||||
/* Get number of questions (row[3]) */
|
/* Get number of questions (row[3]) */
|
||||||
if (sscanf (row[3],"%u",&Result.NumQsts) != 1)
|
if (sscanf (row[3],"%u",&Result.NumQsts) != 1)
|
||||||
|
@ -542,7 +554,7 @@ static void TsR_ShowTestResultsSummaryRow (bool ItsMe,
|
||||||
HTM_TR_Begin (NULL);
|
HTM_TR_Begin (NULL);
|
||||||
|
|
||||||
/***** Row title *****/
|
/***** Row title *****/
|
||||||
HTM_TD_Begin ("class=\"DAT_N_LINE_TOP RM COLOR%u\"",Gbl.RowEvenOdd);
|
HTM_TD_Begin ("colspan=\"2\" class=\"DAT_N_LINE_TOP RM COLOR%u\"",Gbl.RowEvenOdd);
|
||||||
HTM_TxtColonNBSP (Txt_Visible_tests);
|
HTM_TxtColonNBSP (Txt_Visible_tests);
|
||||||
HTM_Unsigned (NumExams);
|
HTM_Unsigned (NumExams);
|
||||||
HTM_TD_End ();
|
HTM_TD_End ();
|
||||||
|
|
Loading…
Reference in New Issue
Block a user