swad-core/swad_degree.h

92 lines
3.2 KiB
C
Raw Normal View History

2014-12-01 23:55:08 +01:00
// swad_degree.h: degrees
#ifndef _SWAD_DEG
#define _SWAD_DEG
/*
SWAD (Shared Workspace At a Distance in Spanish),
is a web platform developed at the University of Granada (Spain),
and used to support university teaching.
This file is part of SWAD core.
Copyright (C) 1999-2024 Antonio Ca<EFBFBD>as Vargas
2014-12-01 23:55:08 +01:00
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as
published by the Free Software Foundation, either version 3 of the
License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*****************************************************************************/
/********************************* Headers ***********************************/
/*****************************************************************************/
2018-10-31 13:00:40 +01:00
#include <mysql/mysql.h> // To access MySQL databases
2014-12-01 23:55:08 +01:00
#include "swad_action.h"
#include "swad_constant.h"
#include "swad_figure_cache.h"
#include "swad_hierarchy_type.h"
#include "swad_name.h"
2016-12-13 13:32:19 +01:00
#include "swad_role_type.h"
2014-12-01 23:55:08 +01:00
#include "swad_string.h"
/*****************************************************************************/
/***************************** Public constants ******************************/
/*****************************************************************************/
2017-01-13 01:51:23 +01:00
#define Deg_MAX_YEARS_PER_DEGREE 12 // Max number of academic years per degree
2014-12-01 23:55:08 +01:00
/*****************************************************************************/
/***************************** Public prototypes *****************************/
/*****************************************************************************/
void Deg_SeeDegWithPendingCrss (void);
void Deg_DrawDegreeLogoAndNameWithLink (struct Hie_Node *Deg,Act_Action_t Action,
const char *IconClass);
2015-11-19 20:04:41 +01:00
2016-11-14 16:47:46 +01:00
void Deg_WriteSelectorOfDegree (void);
2014-12-01 23:55:08 +01:00
void Deg_ShowDegsOfCurrentCtr (void);
unsigned Deg_ConvStrToYear (const char *StrYear);
void Deg_EditDegrees (void);
2018-11-15 12:52:56 +01:00
void Deg_PutIconToViewDegrees (void);
void Deg_GetListAllDegsWithStds (struct Hie_List *Degs);
2020-01-05 12:52:03 +01:00
void Deg_GetListDegsInCurrentCtr (void);
void Deg_FreeListAllDegsWithStds (struct Hie_List *Degs);
2014-12-01 23:55:08 +01:00
void Deg_ReceiveReqDeg (void);
void Deg_ReceiveNewDeg (void);
void Deg_RemoveDeg (void);
2014-12-01 23:55:08 +01:00
bool Deg_GetDegreeDataByCod (struct Hie_Node *Node);
2016-03-20 16:30:52 +01:00
void Deg_RemoveDegreeCompletely (long DegCod);
void Deg_RenameDegShrt (void);
void Deg_RenameDegFull (void);
void Deg_RenameDegree (struct Hie_Node *Deg,Nam_ShrtOrFullName_t ShrtOrFull);
void Deg_ChangeDegTyp (void);
2014-12-01 23:55:08 +01:00
void Deg_ChangeDegWWW (void);
void Deg_ChangeDegStatus (void);
2019-04-08 14:52:13 +02:00
void Deg_ContEditAfterChgDeg (void);
2016-03-20 16:30:52 +01:00
unsigned Deg_GetCachedNumDegsWithUsrs (Rol_Role_t Role);
2014-12-01 23:55:08 +01:00
2018-10-30 17:47:57 +01:00
void Deg_ListDegsFound (MYSQL_RES **mysql_res,unsigned NumCrss);
2014-12-01 23:55:08 +01:00
void Deg_GetUsrMainDeg (long UsrCod,
char ShrtName[Nam_MAX_BYTES_SHRT_NAME + 1],
Rol_Role_t *MaxRole);
2014-12-01 23:55:08 +01:00
#endif