Version 16.144.3

This commit is contained in:
Antonio Cañas Vargas 2017-03-01 17:36:49 +01:00
parent e88236c9db
commit 3dd1d4a271
3 changed files with 47 additions and 10 deletions

View File

@ -194,19 +194,18 @@
// TODO: Un administrador de institución, ¿debería poder cambiar la contraseña de un usuario de esa institución? No lo tengo claro. // TODO: Un administrador de institución, ¿debería poder cambiar la contraseña de un usuario de esa institución? No lo tengo claro.
// TODO: Poner botón de crear lugares si no se ha creado ningún lugar
/*****************************************************************************/ /*****************************************************************************/
/****************************** Public constants *****************************/ /****************************** Public constants *****************************/
/*****************************************************************************/ /*****************************************************************************/
#define Log_PLATFORM_VERSION "SWAD 16.144.2 (2017-03-01)" #define Log_PLATFORM_VERSION "SWAD 16.144.3 (2017-03-01)"
#define CSS_FILE "swad16.144.css" #define CSS_FILE "swad16.144.css"
#define JS_FILE "swad16.144.js" #define JS_FILE "swad16.144.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.144.3: Mar 01, 2017 Button to create a new place when no places have been created. (213334 lines)
Version 16.144.2: Mar 01, 2017 Button to create a new group when no groups have been created. (213300 lines) Version 16.144.2: Mar 01, 2017 Button to create a new group when no groups have been created. (213300 lines)
Version 16.144.1: Mar 01, 2017 Zoom photo even if user has no photo. Version 16.144.1: Mar 01, 2017 Zoom photo even if user has no photo.
Country name is cached. (213290 lines) Country name is cached. (213290 lines)

View File

@ -80,13 +80,18 @@ void Plc_SeePlaces (void)
extern const char *Txt_PLACES_ORDER[2]; extern const char *Txt_PLACES_ORDER[2];
extern const char *Txt_Other_places; extern const char *Txt_Other_places;
extern const char *Txt_Place_unspecified; extern const char *Txt_Place_unspecified;
extern const char *Txt_Create_another_place;
extern const char *Txt_Create_place;
Plc_Order_t Order; Plc_Order_t Order;
unsigned NumPlc; unsigned NumPlc;
unsigned NumCtrsWithPlc = 0; unsigned NumCtrsWithPlc = 0;
unsigned NumCtrsInOtherPlcs; unsigned NumCtrsInOtherPlcs;
bool ICanEdit;
if (Gbl.CurrentIns.Ins.InsCod > 0) if (Gbl.CurrentIns.Ins.InsCod > 0)
{ {
ICanEdit = (Gbl.Usrs.Me.LoggedRole >= Rol_INS_ADM);
/***** Get parameter with the type of order in the list of places *****/ /***** Get parameter with the type of order in the list of places *****/
Plc_GetParamPlcOrder (); Plc_GetParamPlcOrder ();
@ -94,11 +99,12 @@ void Plc_SeePlaces (void)
Plc_GetListPlaces (); Plc_GetListPlaces ();
/***** Table head *****/ /***** Table head *****/
Lay_StartRoundFrameTable (NULL,Txt_Places, Lay_StartRoundFrame (NULL,Txt_Places,
Gbl.Usrs.Me.LoggedRole >= Rol_INS_ADM ? Plc_PutIconToEditPlaces : ICanEdit ? Plc_PutIconToEditPlaces :
NULL, NULL,
Hlp_INSTITUTION_Places,2); Hlp_INSTITUTION_Places);
fprintf (Gbl.F.Out,"<tr>"); fprintf (Gbl.F.Out,"<table class=\"FRAME_TBL CELLS_PAD_2\">"
"<tr>");
for (Order = Plc_ORDER_BY_PLACE; for (Order = Plc_ORDER_BY_PLACE;
Order <= Plc_ORDER_BY_NUM_CTRS; Order <= Plc_ORDER_BY_NUM_CTRS;
Order++) Order++)
@ -170,8 +176,19 @@ void Plc_SeePlaces (void)
Ctr_GetNumCtrsInIns (Gbl.CurrentIns.Ins.InsCod) - Ctr_GetNumCtrsInIns (Gbl.CurrentIns.Ins.InsCod) -
NumCtrsWithPlc); NumCtrsWithPlc);
fprintf (Gbl.F.Out,"</table>");
/***** Button to create place *****/
if (ICanEdit)
{
Act_FormStart (ActEdiPlc);
Lay_PutConfirmButton (Gbl.Plcs.Num ? Txt_Create_another_place :
Txt_Create_place);
Act_FormEnd ();
}
/***** End table *****/ /***** End table *****/
Lay_EndRoundFrameTable (); Lay_EndRoundFrame ();
/***** Free list of places *****/ /***** Free list of places *****/
Plc_FreeListPlaces (); Plc_FreeListPlaces ();

View File

@ -6033,6 +6033,27 @@ const char *Txt_Create_another_institution =
"Criar uma outra institu&ccedil;&atilde;o"; "Criar uma outra institu&ccedil;&atilde;o";
#endif #endif
const char *Txt_Create_another_place =
#if L==1
"Crear un altre lloc";
#elif L==2
"Erstellen Sie einen anderen Standort";
#elif L==3
"Create another place";
#elif L==4
"Crear otro lugar";
#elif L==5
"Cr&eacute;er un autre emplacement";
#elif L==6
"Crear otro lugar"; // Okoteve traducción
#elif L==7
"Crea una altra localit&grave;";
#elif L==8
"Tworzenie innego miejsca";
#elif L==9
"Criar uma outra localiza&ccedil;&atilde;o";
#endif
const char *Txt_Create_assignment = const char *Txt_Create_assignment =
#if L==1 #if L==1
"Crear actividad"; // Necessita traduccio "Crear actividad"; // Necessita traduccio
@ -6413,7 +6434,7 @@ const char *Txt_Create_password =
const char *Txt_Create_place = const char *Txt_Create_place =
#if L==1 #if L==1
"Crear lugar"; // Necessita traduccio "Crear lloc";
#elif L==2 #elif L==2
"Standort eingeben"; "Standort eingeben";
#elif L==3 #elif L==3