diff --git a/swad_action.c b/swad_action.c index 35df6c07..43a90cf6 100644 --- a/swad_action.c +++ b/swad_action.c @@ -99,7 +99,6 @@ System: 11. ActSeeCty List countries 12. ActSeePen List pending institutions, centres, degrees and courses 13. ActReqRemOldCrs Request the total removal of old courses - 14. ActSeeDegTyp List types of degrees 15. ActSeeBan See banners 16. ActSeeLnk See institutional links 17. ActLstPlg List plugins @@ -107,13 +106,15 @@ System: 19. ActSeeCalSys Show the academic calendar 21. ActSysSch Search for courses, teachers, documents... - 22. ActEdiDegTyp Request edition of types of degrees + 23. ActEdiCty Edit countries 24. ActNewCty Request the creation of a country 25. ActRemCty Remove a country 26. ActRenCty Change the name of a country 27. ActChgCtyWWW Change web of country + 14. ActSeeDegTyp List types of degrees + 22. ActEdiDegTyp Request edition of types of degrees 28. ActNewDegTyp Request the creation of a type of degree 29. ActRemDegTyp Request the removal of a type of degree 30. ActRenDegTyp Request renaming of a type of degree @@ -1519,16 +1520,14 @@ struct Act_Actions Act_Actions[Act_NUM_ACTIONS] = /* ActSeeCty */{ 862, 1,TabSys,ActSeeCty , 0, 0, 0, 0, 0, 0,0x1FF,Act_CONT_NORM,Act_THIS_WINDOW,Cty_ListCountries1 ,Cty_ListCountries2 ,"earth64x64.gif" }, /* ActSeePen */{1060, 2,TabSys,ActSeePen , 0, 0, 0, 0, 0, 0,0x1E0,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Deg_SeePending ,"hierarchy64x64.png" }, /* ActReqRemOldCrs */{1109, 3,TabSys,ActReqRemOldCrs , 0, 0, 0, 0, 0, 0,0x100,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Crs_AskRemoveOldCrss ,"removeusers64x64.gif" }, - /* ActSeeDegTyp */{1013, 4,TabSys,ActSeeDegTyp , 0, 0, 0, 0, 0, 0,0x100,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,DT_SeeDegreeTypesInSysTab ,"grouptypes64x64.gif" }, - /* ActSeeBan */{1137, 5,TabSys,ActSeeBan , 0, 0, 0, 0, 0, 0,0x100,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Ban_SeeBanners ,"picture64x64.gif" }, - /* ActSeeLnk */{ 748, 6,TabSys,ActSeeLnk , 0, 0, 0, 0, 0, 0,0x1FF,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Lnk_SeeLinks ,"link64x64.gif" }, - /* ActLstPlg */{ 777, 7,TabSys,ActLstPlg , 0, 0, 0, 0, 0, 0,0x100,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Plg_ListPlugins ,"blocks64x64.gif" }, - /* ActSetUp */{ 840, 8,TabSys,ActSetUp , 0, 0, 0, 0, 0, 0,0x100,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Set_Setup ,"lightning64x64.gif" }, - /* ActSeeCalSys */{1622, 9,TabSys,ActSeeCalSys , 0, 0, 0, 0, 0, 0,0x1FF,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Cal_DrawCalendarSys ,"calendar64x64.png" }, + /* ActSeeBan */{1137, 4,TabSys,ActSeeBan , 0, 0, 0, 0, 0, 0,0x100,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Ban_SeeBanners ,"picture64x64.gif" }, + /* ActSeeLnk */{ 748, 5,TabSys,ActSeeLnk , 0, 0, 0, 0, 0, 0,0x1FF,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Lnk_SeeLinks ,"link64x64.gif" }, + /* ActLstPlg */{ 777, 6,TabSys,ActLstPlg , 0, 0, 0, 0, 0, 0,0x100,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Plg_ListPlugins ,"blocks64x64.gif" }, + /* ActSetUp */{ 840, 7,TabSys,ActSetUp , 0, 0, 0, 0, 0, 0,0x100,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Set_Setup ,"lightning64x64.gif" }, + /* ActSeeCalSys */{1622, 8,TabSys,ActSeeCalSys , 0, 0, 0, 0, 0, 0,0x1FF,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Cal_DrawCalendarSys ,"calendar64x64.png" }, // Actions not in menu: /* ActSysSch */{ 628,-1,TabUnk,ActSysReqSch , 0, 0, 0, 0, 0, 0,0x1FF,Act_CONT_NORM,Act_THIS_WINDOW,Sch_GetParamsSearch ,Sch_SysSearch ,NULL}, - /* ActEdiDegTyp */{ 573,-1,TabUnk,ActSeeDegTyp , 0, 0, 0, 0, 0, 0,0x100,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,DT_ReqEditDegreeTypes ,NULL}, /* ActEdiCty */{ 863,-1,TabUnk,ActSeeCty , 0, 0, 0, 0, 0, 0,0x100,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Cty_EditCountries ,NULL}, /* ActNewCty */{ 864,-1,TabUnk,ActSeeCty , 0, 0, 0, 0, 0, 0,0x100,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Cty_RecFormNewCountry ,NULL}, @@ -1536,10 +1535,6 @@ struct Act_Actions Act_Actions[Act_NUM_ACTIONS] = /* ActRenCty */{ 866,-1,TabUnk,ActSeeCty , 0, 0, 0, 0, 0, 0,0x100,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Cty_RenameCountry ,NULL}, /* ActChgCtyWWW */{1157,-1,TabUnk,ActSeeCty , 0, 0, 0, 0, 0, 0,0x100,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Cty_ChangeCtyWWW ,NULL}, - /* ActNewDegTyp */{ 537,-1,TabUnk,ActSeeDegTyp , 0, 0, 0, 0, 0, 0,0x100,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,DT_RecFormNewDegreeType ,NULL}, - /* ActRemDegTyp */{ 545,-1,TabUnk,ActSeeDegTyp , 0, 0, 0, 0, 0, 0,0x100,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,DT_RemoveDegreeType ,NULL}, - /* ActRenDegTyp */{ 538,-1,TabUnk,ActSeeDegTyp , 0, 0, 0, 0, 0, 0,0x100,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,DT_RenameDegreeType ,NULL}, - /* ActRemOldCrs */{1110,-1,TabUnk,ActReqRemOldCrs , 0, 0, 0, 0, 0, 0,0x100,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Crs_RemoveOldCrss ,NULL}, /* ActEdiBan */{1138,-1,TabUnk,ActSeeBan , 0, 0, 0, 0, 0, 0,0x100,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Ban_EditBanners ,NULL}, @@ -1678,6 +1673,12 @@ struct Act_Actions Act_Actions[Act_NUM_ACTIONS] = /* ActRecCtrPho */{1161,-1,TabUnk,ActSeeCtrInf , 0, 0, 0,0x1C0, 0, 0, 0,Act_CONT_DATA,Act_THIS_WINDOW,NULL ,Ctr_ReceivePhoto ,NULL}, /* ActChgCtrPhoAtt */{1159,-1,TabUnk,ActSeeCtrInf , 0, 0, 0,0x1C0, 0, 0, 0,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Ctr_ChangeCtrPhotoAttribution ,NULL}, + /* ActSeeDegTyp */{1013,-1,TabUnk,ActSeeDeg , 0, 0, 0,0x1FF, 0, 0, 0,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,DT_SeeDegreeTypesInDegTab ,NULL}, + /* ActEdiDegTyp */{ 573,-1,TabUnk,ActSeeDeg , 0, 0, 0,0x100, 0, 0, 0,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,DT_ReqEditDegreeTypes ,NULL}, + /* ActNewDegTyp */{ 537,-1,TabUnk,ActSeeDeg , 0, 0, 0,0x100, 0, 0, 0,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,DT_RecFormNewDegreeType ,NULL}, + /* ActRemDegTyp */{ 545,-1,TabUnk,ActSeeDeg , 0, 0, 0,0x100, 0, 0, 0,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,DT_RemoveDegreeType ,NULL}, + /* ActRenDegTyp */{ 538,-1,TabUnk,ActSeeDeg , 0, 0, 0,0x100, 0, 0, 0,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,DT_RenameDegreeType ,NULL}, + /* ActEdiDeg */{ 536,-1,TabUnk,ActSeeDeg , 0, 0, 0,0x1FE, 0, 0, 0,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Deg_EditDegrees ,NULL}, /* ActReqDeg */{1206,-1,TabUnk,ActSeeDeg , 0, 0, 0,0x1FE, 0, 0, 0,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Deg_RecFormReqDeg ,NULL}, /* ActNewDeg */{ 540,-1,TabUnk,ActSeeDeg , 0, 0, 0,0x1C0, 0, 0, 0,Act_CONT_NORM,Act_THIS_WINDOW,NULL ,Deg_RecFormNewDeg ,NULL}, diff --git a/swad_action.h b/swad_action.h index e4121d0b..a56c4eb5 100644 --- a/swad_action.h +++ b/swad_action.h @@ -57,7 +57,7 @@ typedef enum typedef signed int Act_Action_t; // Must be a signed type, because -1 is used to indicate obsolete action -#define Act_NUM_ACTIONS (1 + 9 + 48 + 17 + 47 + 27 + 24 + 115 + 54 + 416 + 159 + 172 + 42 + 31 + 96) +#define Act_NUM_ACTIONS (1 + 9 + 43 + 17 + 47 + 32 + 24 + 115 + 54 + 416 + 159 + 172 + 42 + 31 + 96) #define Act_MAX_ACTION_COD 1636 @@ -91,58 +91,52 @@ typedef signed int Act_Action_t; // Must be a signed type, because -1 is used to #define ActSeeCty (ActWebSvc + 2) #define ActSeePen (ActWebSvc + 3) #define ActReqRemOldCrs (ActWebSvc + 4) -#define ActSeeDegTyp (ActWebSvc + 5) -#define ActSeeBan (ActWebSvc + 6) -#define ActSeeLnk (ActWebSvc + 7) -#define ActLstPlg (ActWebSvc + 8) -#define ActSetUp (ActWebSvc + 9) -#define ActSeeCalSys (ActWebSvc + 10) +#define ActSeeBan (ActWebSvc + 5) +#define ActSeeLnk (ActWebSvc + 6) +#define ActLstPlg (ActWebSvc + 7) +#define ActSetUp (ActWebSvc + 8) +#define ActSeeCalSys (ActWebSvc + 9) // Secondary actions -#define ActSysSch (ActWebSvc + 11) -#define ActEdiDegTyp (ActWebSvc + 12) -#define ActEdiCty (ActWebSvc + 13) -#define ActNewCty (ActWebSvc + 14) -#define ActRemCty (ActWebSvc + 15) -#define ActRenCty (ActWebSvc + 16) -#define ActChgCtyWWW (ActWebSvc + 17) +#define ActSysSch (ActWebSvc + 10) +#define ActEdiCty (ActWebSvc + 11) +#define ActNewCty (ActWebSvc + 12) +#define ActRemCty (ActWebSvc + 13) +#define ActRenCty (ActWebSvc + 14) +#define ActChgCtyWWW (ActWebSvc + 15) -#define ActNewDegTyp (ActWebSvc + 18) -#define ActRemDegTyp (ActWebSvc + 19) -#define ActRenDegTyp (ActWebSvc + 20) +#define ActRemOldCrs (ActWebSvc + 16) -#define ActRemOldCrs (ActWebSvc + 21) +#define ActEdiBan (ActWebSvc + 17) +#define ActNewBan (ActWebSvc + 18) +#define ActRemBan (ActWebSvc + 19) +#define ActShoBan (ActWebSvc + 20) +#define ActHidBan (ActWebSvc + 21) +#define ActRenBanSho (ActWebSvc + 22) +#define ActRenBanFul (ActWebSvc + 23) +#define ActChgBanImg (ActWebSvc + 24) +#define ActChgBanWWW (ActWebSvc + 25) +#define ActClkBan (ActWebSvc + 26) -#define ActEdiBan (ActWebSvc + 22) -#define ActNewBan (ActWebSvc + 23) -#define ActRemBan (ActWebSvc + 24) -#define ActShoBan (ActWebSvc + 25) -#define ActHidBan (ActWebSvc + 26) -#define ActRenBanSho (ActWebSvc + 27) -#define ActRenBanFul (ActWebSvc + 28) -#define ActChgBanImg (ActWebSvc + 29) -#define ActChgBanWWW (ActWebSvc + 30) -#define ActClkBan (ActWebSvc + 31) +#define ActEdiLnk (ActWebSvc + 27) +#define ActNewLnk (ActWebSvc + 28) +#define ActRemLnk (ActWebSvc + 29) +#define ActRenLnkSho (ActWebSvc + 30) +#define ActRenLnkFul (ActWebSvc + 31) +#define ActChgLnkWWW (ActWebSvc + 32) -#define ActEdiLnk (ActWebSvc + 32) -#define ActNewLnk (ActWebSvc + 33) -#define ActRemLnk (ActWebSvc + 34) -#define ActRenLnkSho (ActWebSvc + 35) -#define ActRenLnkFul (ActWebSvc + 36) -#define ActChgLnkWWW (ActWebSvc + 37) +#define ActEdiPlg (ActWebSvc + 33) +#define ActNewPlg (ActWebSvc + 34) +#define ActRemPlg (ActWebSvc + 35) +#define ActRenPlg (ActWebSvc + 36) +#define ActChgPlgDes (ActWebSvc + 37) +#define ActChgPlgLog (ActWebSvc + 38) +#define ActChgPlgAppKey (ActWebSvc + 39) +#define ActChgPlgURL (ActWebSvc + 40) +#define ActChgPlgIP (ActWebSvc + 41) -#define ActEdiPlg (ActWebSvc + 38) -#define ActNewPlg (ActWebSvc + 39) -#define ActRemPlg (ActWebSvc + 40) -#define ActRenPlg (ActWebSvc + 41) -#define ActChgPlgDes (ActWebSvc + 42) -#define ActChgPlgLog (ActWebSvc + 43) -#define ActChgPlgAppKey (ActWebSvc + 44) -#define ActChgPlgURL (ActWebSvc + 45) -#define ActChgPlgIP (ActWebSvc + 46) - -#define ActPrnCalSys (ActWebSvc + 47) -#define ActChgCalSys1stDay (ActWebSvc + 48) +#define ActPrnCalSys (ActWebSvc + 42) +#define ActChgCalSys1stDay (ActWebSvc + 43) /*****************************************************************************/ /******************************** Country tab ********************************/ @@ -252,18 +246,24 @@ typedef signed int Act_Action_t; // Must be a signed type, because -1 is used to #define ActRecCtrPho (ActChgCalIns1stDay + 15) #define ActChgCtrPhoAtt (ActChgCalIns1stDay + 16) -#define ActEdiDeg (ActChgCalIns1stDay + 17) -#define ActReqDeg (ActChgCalIns1stDay + 18) -#define ActNewDeg (ActChgCalIns1stDay + 19) -#define ActRemDeg (ActChgCalIns1stDay + 20) -#define ActRenDegSho (ActChgCalIns1stDay + 21) -#define ActRenDegFul (ActChgCalIns1stDay + 22) -#define ActChgDegTyp (ActChgCalIns1stDay + 23) -#define ActChgDegWWW (ActChgCalIns1stDay + 24) -#define ActChgDegSta (ActChgCalIns1stDay + 25) +#define ActSeeDegTyp (ActChgCalIns1stDay + 17) +#define ActEdiDegTyp (ActChgCalIns1stDay + 18) +#define ActNewDegTyp (ActChgCalIns1stDay + 19) +#define ActRemDegTyp (ActChgCalIns1stDay + 20) +#define ActRenDegTyp (ActChgCalIns1stDay + 21) -#define ActPrnCalCtr (ActChgCalIns1stDay + 26) -#define ActChgCalCtr1stDay (ActChgCalIns1stDay + 27) +#define ActEdiDeg (ActChgCalIns1stDay + 22) +#define ActReqDeg (ActChgCalIns1stDay + 23) +#define ActNewDeg (ActChgCalIns1stDay + 24) +#define ActRemDeg (ActChgCalIns1stDay + 25) +#define ActRenDegSho (ActChgCalIns1stDay + 26) +#define ActRenDegFul (ActChgCalIns1stDay + 27) +#define ActChgDegTyp (ActChgCalIns1stDay + 28) +#define ActChgDegWWW (ActChgCalIns1stDay + 29) +#define ActChgDegSta (ActChgCalIns1stDay + 30) + +#define ActPrnCalCtr (ActChgCalIns1stDay + 31) +#define ActChgCalCtr1stDay (ActChgCalIns1stDay + 32) /*****************************************************************************/ /********************************* Degree tab ********************************/ diff --git a/swad_changelog.h b/swad_changelog.h index 88bddd4f..0a3f9c9d 100644 --- a/swad_changelog.h +++ b/swad_changelog.h @@ -211,13 +211,14 @@ /****************************** Public constants *****************************/ /*****************************************************************************/ -#define Log_PLATFORM_VERSION "SWAD 16.168.1 (2017-03-26)" +#define Log_PLATFORM_VERSION "SWAD 16.169 (2017-03-26)" #define CSS_FILE "swad16.166.css" #define JS_FILE "swad16.144.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.169: Mar 26, 2017 Action to view degree types removed from main menu. (217660 lines) Version 16.168.1: Mar 26, 2017 Link to view degree types in degrees. (217694 lines) Version 16.168: Mar 26, 2017 Action to view places removed from main menu. (217679 lines) Version 16.167.16:Mar 26, 2017 Link to view places in centres. (217718 lines) diff --git a/swad_degree.c b/swad_degree.c index e0a0bd83..68fd28f8 100644 --- a/swad_degree.c +++ b/swad_degree.c @@ -699,7 +699,8 @@ static void Deg_ListDegreesForEdition (void) /***** Write heading *****/ sprintf (Gbl.Title,Txt_Degrees_of_CENTRE_X, Gbl.CurrentCtr.Ctr.ShrtName); - Lay_StartRoundFrameTable (NULL,Gbl.Title,NULL,Hlp_CENTRE_Degrees,2); + Lay_StartRoundFrameTable (NULL,Gbl.Title,DT_PutIconToViewDegreeTypes, + Hlp_CENTRE_Degrees,2); Deg_PutHeadDegreesForEdition (); /***** List the degrees *****/ @@ -949,6 +950,15 @@ static void Deg_PutFormToCreateDegree (void) struct DegreeType *DegTyp; unsigned NumDegTyp; + /***** Degree data *****/ + Deg = &Gbl.Degs.EditingDeg; + + /***** Start of frame *****/ + sprintf (Gbl.Title,Txt_New_degree_of_CENTRE_X, + Gbl.CurrentCtr.Ctr.ShrtName); + Lay_StartRoundFrame (NULL,Gbl.Title,DT_PutIconToViewDegreeTypes, + Hlp_CENTRE_Degrees); + /***** Start form *****/ if (Gbl.Usrs.Me.LoggedRole >= Rol_CTR_ADM) Act_FormStart (ActNewDeg); @@ -957,15 +967,10 @@ static void Deg_PutFormToCreateDegree (void) else Lay_ShowErrorAndExit ("You can not edit degrees."); - /***** Degree data *****/ - Deg = &Gbl.Degs.EditingDeg; + /***** Start table *****/ + fprintf (Gbl.F.Out,"