mirror of https://github.com/acanas/swad-core.git
Version 16.81.5
This commit is contained in:
parent
f9db381e94
commit
d8d90370fd
Binary file not shown.
After Width: | Height: | Size: 468 B |
|
@ -2774,7 +2774,7 @@ struct Act_Actions Act_Actions[Act_NUM_ACTIONS] =
|
||||||
/* ActFrmRolSes */{ 843, 1,TabPrf,ActFrmRolSes ,0x1FE,0x1FE,0x1FE,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Usr_WriteFormLogout ,"keyuser64x64.gif" },
|
/* ActFrmRolSes */{ 843, 1,TabPrf,ActFrmRolSes ,0x1FE,0x1FE,0x1FE,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Usr_WriteFormLogout ,"keyuser64x64.gif" },
|
||||||
/* ActMyCrs */{ 987, 2,TabPrf,ActMyCrs ,0x1FE,0x1FE,0x1FE,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Crs_ReqSelectOneOfMyCourses ,"mygroups64x64.gif" },
|
/* ActMyCrs */{ 987, 2,TabPrf,ActMyCrs ,0x1FE,0x1FE,0x1FE,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Crs_ReqSelectOneOfMyCourses ,"mygroups64x64.gif" },
|
||||||
/* ActSeeMyTT */{ 408, 3,TabPrf,ActSeeMyTT ,0x1FE,0x1FE,0x1FE,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,TT_ShowClassTimeTable ,"clock64x64.gif" },
|
/* ActSeeMyTT */{ 408, 3,TabPrf,ActSeeMyTT ,0x1FE,0x1FE,0x1FE,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,TT_ShowClassTimeTable ,"clock64x64.gif" },
|
||||||
/* ActSeeMyAgd */{1602, 5,TabPrf,ActSeeMyAgd ,0x100,0x100,0x100,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Agd_SeeEvents ,"date64x64.gif" },
|
/* ActSeeMyAgd */{1602, 5,TabPrf,ActSeeMyAgd ,0x100,0x100,0x100,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Agd_SeeEvents ,"date64x64.gif" },
|
||||||
/* ActFrmMyAcc */{ 36, 6,TabPrf,ActFrmMyAcc ,0x1FF,0x1FF,0x1FF,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Acc_ShowFormMyAccount ,"arroba64x64.gif" },
|
/* ActFrmMyAcc */{ 36, 6,TabPrf,ActFrmMyAcc ,0x1FF,0x1FF,0x1FF,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Acc_ShowFormMyAccount ,"arroba64x64.gif" },
|
||||||
/* ActReqEdiRecCom */{ 285, 7,TabPrf,ActReqEdiRecCom ,0x1FE,0x1FE,0x1FE,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Rec_ShowFormMySharedRecord ,"card64x64.gif" },
|
/* ActReqEdiRecCom */{ 285, 7,TabPrf,ActReqEdiRecCom ,0x1FE,0x1FE,0x1FE,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Rec_ShowFormMySharedRecord ,"card64x64.gif" },
|
||||||
/* ActEdiPrf */{ 673, 8,TabPrf,ActEdiPrf ,0x1FF,0x1FF,0x1FF,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Pre_EditPrefs ,"heart64x64.gif" },
|
/* ActEdiPrf */{ 673, 8,TabPrf,ActEdiPrf ,0x1FF,0x1FF,0x1FF,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Pre_EditPrefs ,"heart64x64.gif" },
|
||||||
|
|
|
@ -185,13 +185,17 @@
|
||||||
/****************************** Public constants *****************************/
|
/****************************** Public constants *****************************/
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
||||||
#define Log_PLATFORM_VERSION "SWAD 16.81.4 (2016-12-01)"
|
#define Log_PLATFORM_VERSION "SWAD 16.81.5 (2016-12-01)"
|
||||||
#define CSS_FILE "swad16.69.css"
|
#define CSS_FILE "swad16.69.css"
|
||||||
#define JS_FILE "swad16.46.1.js"
|
#define JS_FILE "swad16.46.1.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 16.81.5: Dec 01, 2016 Link in teacher's record card to show agenda. (209313 lines)
|
||||||
|
Copy the following icon to icon public directory:
|
||||||
|
sudo cp icon/date64x64.gif /var/www/html/swad/icon/
|
||||||
|
|
||||||
Version 16.81.4: Dec 01, 2016 Changes in texts related to agenda. (209268 lines)
|
Version 16.81.4: Dec 01, 2016 Changes in texts related to agenda. (209268 lines)
|
||||||
Version 16.81.3: Dec 01, 2016 Icon view replaced by lock in agenda.
|
Version 16.81.3: Dec 01, 2016 Icon view replaced by lock in agenda.
|
||||||
Changes in texts related to agenda. (209227 lines)
|
Changes in texts related to agenda. (209227 lines)
|
||||||
|
|
|
@ -2306,6 +2306,7 @@ static void Rec_PutIconsCommands (void)
|
||||||
extern struct Act_Actions Act_Actions[Act_NUM_ACTIONS];
|
extern struct Act_Actions Act_Actions[Act_NUM_ACTIONS];
|
||||||
extern const char *Txt_Edit_my_personal_data;
|
extern const char *Txt_Edit_my_personal_data;
|
||||||
extern const char *Txt_View_record_for_this_course;
|
extern const char *Txt_View_record_for_this_course;
|
||||||
|
extern const char *Txt_View_agenda;
|
||||||
extern const char *Txt_Admin_user;
|
extern const char *Txt_Admin_user;
|
||||||
extern const char *Txt_Write_a_message;
|
extern const char *Txt_Write_a_message;
|
||||||
extern const char *Txt_View_homework;
|
extern const char *Txt_View_homework;
|
||||||
|
@ -2317,8 +2318,12 @@ static void Rec_PutIconsCommands (void)
|
||||||
bool IAmLoggedAsStudent = (Gbl.Usrs.Me.LoggedRole == Rol_STUDENT); // My current role is student
|
bool IAmLoggedAsStudent = (Gbl.Usrs.Me.LoggedRole == Rol_STUDENT); // My current role is student
|
||||||
bool IAmLoggedAsTeacher = (Gbl.Usrs.Me.LoggedRole == Rol_TEACHER); // My current role is teacher
|
bool IAmLoggedAsTeacher = (Gbl.Usrs.Me.LoggedRole == Rol_TEACHER); // My current role is teacher
|
||||||
bool IAmLoggedAsSysAdm = (Gbl.Usrs.Me.LoggedRole == Rol_SYS_ADM); // My current role is superuser
|
bool IAmLoggedAsSysAdm = (Gbl.Usrs.Me.LoggedRole == Rol_SYS_ADM); // My current role is superuser
|
||||||
|
bool IBelongToCurrentCrs = (Gbl.Usrs.Me.UsrDat.RoleInCurrentCrsDB == Rol_STUDENT ||
|
||||||
|
Gbl.Usrs.Me.UsrDat.RoleInCurrentCrsDB == Rol_TEACHER);
|
||||||
bool HeBelongsToCurrentCrs = (Gbl.Record.UsrDat->RoleInCurrentCrsDB == Rol_STUDENT ||
|
bool HeBelongsToCurrentCrs = (Gbl.Record.UsrDat->RoleInCurrentCrsDB == Rol_STUDENT ||
|
||||||
Gbl.Record.UsrDat->RoleInCurrentCrsDB == Rol_TEACHER);
|
Gbl.Record.UsrDat->RoleInCurrentCrsDB == Rol_TEACHER);
|
||||||
|
bool HeIsATeacherInAnyCrs = (Gbl.Record.UsrDat->Roles & (1 << Rol_TEACHER));
|
||||||
|
bool ICanViewAgenda;
|
||||||
|
|
||||||
if (!Gbl.Form.Inside && // Only if not inside another form
|
if (!Gbl.Form.Inside && // Only if not inside another form
|
||||||
Act_Actions[Gbl.Action.Act].BrowserWindow == Act_THIS_WINDOW && // Only in main window
|
Act_Actions[Gbl.Action.Act].BrowserWindow == Act_THIS_WINDOW && // Only in main window
|
||||||
|
@ -2336,10 +2341,7 @@ static void Rec_PutIconsCommands (void)
|
||||||
/***** Button to view user's record card in course when:
|
/***** Button to view user's record card in course when:
|
||||||
- a course is selected && the user belongs to it &&
|
- a course is selected && the user belongs to it &&
|
||||||
- I can view user's record card in course *****/
|
- I can view user's record card in course *****/
|
||||||
if (HeBelongsToCurrentCrs &&
|
if (HeBelongsToCurrentCrs && (IBelongToCurrentCrs || IAmLoggedAsSysAdm))
|
||||||
(IAmLoggedAsStudent ||
|
|
||||||
IAmLoggedAsTeacher ||
|
|
||||||
IAmLoggedAsSysAdm))
|
|
||||||
Lay_PutContextualLink (Gbl.Record.UsrDat->RoleInCurrentCrsDB == Rol_STUDENT ? ActSeeRecOneStd :
|
Lay_PutContextualLink (Gbl.Record.UsrDat->RoleInCurrentCrsDB == Rol_STUDENT ? ActSeeRecOneStd :
|
||||||
ActSeeRecOneTch,
|
ActSeeRecOneTch,
|
||||||
Rec_PutParamUsrCodEncrypted,
|
Rec_PutParamUsrCodEncrypted,
|
||||||
|
@ -2347,6 +2349,32 @@ static void Rec_PutIconsCommands (void)
|
||||||
Txt_View_record_for_this_course,NULL,
|
Txt_View_record_for_this_course,NULL,
|
||||||
NULL);
|
NULL);
|
||||||
|
|
||||||
|
/***** Button to view teacher's agenda when:
|
||||||
|
- he/she is a teacher and I share any course with him/her *****/
|
||||||
|
if (HeIsATeacherInAnyCrs)
|
||||||
|
{
|
||||||
|
if (ItsMe)
|
||||||
|
Lay_PutContextualLink (ActSeeMyAgd,
|
||||||
|
NULL,
|
||||||
|
"date64x64.gif",
|
||||||
|
Txt_View_agenda,NULL,
|
||||||
|
NULL);
|
||||||
|
else // Not me
|
||||||
|
{
|
||||||
|
if (!(ICanViewAgenda = (IBelongToCurrentCrs &&
|
||||||
|
HeBelongsToCurrentCrs) || // Course selected and we both belong to it
|
||||||
|
IAmLoggedAsSysAdm)) // I am system admin
|
||||||
|
// The following slow check is made only if the previous fails
|
||||||
|
ICanViewAgenda = Usr_CheckIfUsrSharesAnyOfMyCrs (Gbl.Record.UsrDat->UsrCod);
|
||||||
|
if (ICanViewAgenda)
|
||||||
|
Lay_PutContextualLink (ActSeeMyAgd,
|
||||||
|
Rec_PutParamUsrCodEncrypted,
|
||||||
|
"date64x64.gif",
|
||||||
|
Txt_View_agenda,NULL,
|
||||||
|
NULL);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/***** Button to admin user *****/
|
/***** Button to admin user *****/
|
||||||
if (ItsMe ||
|
if (ItsMe ||
|
||||||
(Gbl.CurrentCrs.Crs.CrsCod > 0 && Gbl.Usrs.Me.LoggedRole == Rol_TEACHER) ||
|
(Gbl.CurrentCrs.Crs.CrsCod > 0 && Gbl.Usrs.Me.LoggedRole == Rol_TEACHER) ||
|
||||||
|
@ -2391,23 +2419,18 @@ static void Rec_PutIconsCommands (void)
|
||||||
NULL);
|
NULL);
|
||||||
|
|
||||||
/***** Button to view user's attendance *****/
|
/***** Button to view user's attendance *****/
|
||||||
if (IAmLoggedAsStudent ||
|
if (ItsMe && IAmLoggedAsStudent)
|
||||||
IAmLoggedAsTeacher ||
|
// As student, I can see my attendance
|
||||||
IAmLoggedAsSysAdm)
|
Lay_PutContextualLink (ActSeeLstMyAtt,NULL,
|
||||||
{
|
"rollcall64x64.png",
|
||||||
if (IAmLoggedAsStudent)
|
Txt_View_attendance,NULL,
|
||||||
// As student, I can see my attendance
|
NULL);
|
||||||
Lay_PutContextualLink (ActSeeLstMyAtt,NULL,
|
else if (IAmLoggedAsTeacher || IAmLoggedAsSysAdm)
|
||||||
"rollcall64x64.png",
|
// As teacher, I can see attendance of the student
|
||||||
Txt_View_attendance,NULL,
|
Lay_PutContextualLink (ActSeeLstStdAtt,Rec_PutParamsStudent,
|
||||||
NULL);
|
"rollcall64x64.png",
|
||||||
else // IAmLoggedAsTeacher || IAmLoggedAsSysAdm
|
Txt_View_attendance,NULL,
|
||||||
// As teacher, I can see attendance of the student
|
NULL);
|
||||||
Lay_PutContextualLink (ActSeeLstStdAtt,Rec_PutParamsStudent,
|
|
||||||
"rollcall64x64.png",
|
|
||||||
Txt_View_attendance,NULL,
|
|
||||||
NULL);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/***** Button to send a message *****/
|
/***** Button to send a message *****/
|
||||||
|
|
21
swad_text.c
21
swad_text.c
|
@ -50170,6 +50170,27 @@ const char *Txt_View =
|
||||||
"Ver";
|
"Ver";
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
const char *Txt_View_agenda =
|
||||||
|
#if L==1
|
||||||
|
"Veure agenda";
|
||||||
|
#elif L==2
|
||||||
|
"Siehe Organizer";
|
||||||
|
#elif L==3
|
||||||
|
"View agenda";
|
||||||
|
#elif L==4
|
||||||
|
"Ver agenda";
|
||||||
|
#elif L==5
|
||||||
|
"Voir agenda";
|
||||||
|
#elif L==6
|
||||||
|
"Ver agenda"; // Okoteve traducción
|
||||||
|
#elif L==7
|
||||||
|
"Vedi agenda";
|
||||||
|
#elif L==8
|
||||||
|
"Wiadomości pamiętnik";
|
||||||
|
#elif L==9
|
||||||
|
"Veja agenda";
|
||||||
|
#endif
|
||||||
|
|
||||||
const char *Txt_View_all_recipients =
|
const char *Txt_View_all_recipients =
|
||||||
#if L==1
|
#if L==1
|
||||||
"Ver todos los destinatarios"; // Necessita traduccio
|
"Ver todos los destinatarios"; // Necessita traduccio
|
||||||
|
|
Loading…
Reference in New Issue