Version 15.225.4

This commit is contained in:
Antonio Cañas Vargas 2016-06-15 13:20:07 +02:00
parent 5d4be4f3c1
commit 5a286d9445
6 changed files with 94 additions and 6 deletions

View File

@ -1055,6 +1055,8 @@ Users:
882. ActReqRemOldUsr Request the complete elimination of old users 882. ActReqRemOldUsr Request the complete elimination of old users
883. ActRemOldUsr Eliminate completely old users 883. ActRemOldUsr Eliminate completely old users
NEW. ActLstDupUsr List possible duplicate users
884. ActLstClk List last clicks in real time 884. ActLstClk List last clicks in real time
Social: Social:
885. ActSeeSocTmlGbl Show social timeline (global) 885. ActSeeSocTmlGbl Show social timeline (global)
@ -2449,6 +2451,8 @@ struct Act_Actions Act_Actions[Act_NUM_ACTIONS] =
/* ActReqRemOldUsr */{ 590,-1,TabUsr,ActLstOth ,0x100,0x100,0x100,Act_CONTENT_NORM,Act_MAIN_WINDOW,NULL ,Enr_AskRemoveOldUsrs ,NULL}, /* ActReqRemOldUsr */{ 590,-1,TabUsr,ActLstOth ,0x100,0x100,0x100,Act_CONTENT_NORM,Act_MAIN_WINDOW,NULL ,Enr_AskRemoveOldUsrs ,NULL},
/* ActRemOldUsr */{ 773,-1,TabUsr,ActLstOth ,0x100,0x100,0x100,Act_CONTENT_NORM,Act_MAIN_WINDOW,NULL ,Enr_RemoveOldUsrs ,NULL}, /* ActRemOldUsr */{ 773,-1,TabUsr,ActLstOth ,0x100,0x100,0x100,Act_CONTENT_NORM,Act_MAIN_WINDOW,NULL ,Enr_RemoveOldUsrs ,NULL},
/* ActLstDupUsr */{1578,-1,TabUsr,ActLstOth ,0x100,0x100,0x100,Act_CONTENT_NORM,Act_MAIN_WINDOW,NULL ,Usr_ListDuplicateUsrs ,NULL},
/* ActLstClk */{ 989,-1,TabUsr,ActLstCon ,0x1FE,0x1FE,0x1FE,Act_CONTENT_NORM,Act_MAIN_WINDOW,NULL ,Con_ShowLastClicks ,NULL}, /* ActLstClk */{ 989,-1,TabUsr,ActLstCon ,0x1FE,0x1FE,0x1FE,Act_CONTENT_NORM,Act_MAIN_WINDOW,NULL ,Con_ShowLastClicks ,NULL},
// TabSoc ****************************************************************** // TabSoc ******************************************************************
@ -4412,6 +4416,7 @@ Act_Action_t Act_FromActCodToAction[1+Act_MAX_ACTION_COD] = // Do not reuse uniq
ActReqRemStdPho, // #1575 ActReqRemStdPho, // #1575
ActReqRemTchPho, // #1576 ActReqRemTchPho, // #1576
ActReqRemMyPho, // #1577 ActReqRemMyPho, // #1577
ActLstDupUsr, // #1578
}; };
/*****************************************************************************/ /*****************************************************************************/

View File

@ -72,9 +72,9 @@ typedef enum
typedef int Act_Action_t; // Must be a signed type, because -1 is used to indicate obsolete action typedef int Act_Action_t; // Must be a signed type, because -1 is used to indicate obsolete action
#define Act_NUM_ACTIONS (1+9+51+15+90+70+67+246+186+153+172+36+28+84) #define Act_NUM_ACTIONS (1+9+51+15+90+70+67+246+186+154+172+36+28+84)
#define Act_MAX_ACTION_COD 1577 #define Act_MAX_ACTION_COD 1578
#define Act_MAX_OPTIONS_IN_MENU_PER_TAB 20 #define Act_MAX_OPTIONS_IN_MENU_PER_TAB 20
@ -1094,7 +1094,9 @@ typedef int Act_Action_t; // Must be a signed type, because -1 is used to indica
#define ActReqRemOldUsr (ActChgNumRowFooGrp+151) #define ActReqRemOldUsr (ActChgNumRowFooGrp+151)
#define ActRemOldUsr (ActChgNumRowFooGrp+152) #define ActRemOldUsr (ActChgNumRowFooGrp+152)
#define ActLstClk (ActChgNumRowFooGrp+153) #define ActLstDupUsr (ActChgNumRowFooGrp+153)
#define ActLstClk (ActChgNumRowFooGrp+154)
/*****************************************************************************/ /*****************************************************************************/
/******************************** Social tab *********************************/ /******************************** Social tab *********************************/

View File

@ -128,13 +128,17 @@
/****************************** Public constants *****************************/ /****************************** Public constants *****************************/
/*****************************************************************************/ /*****************************************************************************/
#define Log_PLATFORM_VERSION "SWAD 15.225.3 (2016-06-15)" #define Log_PLATFORM_VERSION "SWAD 15.225.4 (2016-06-15)"
#define CSS_FILE "swad15.224.3.css" #define CSS_FILE "swad15.224.3.css"
#define JS_FILE "swad15.216.js" #define JS_FILE "swad15.216.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 15.225.4: Jun 15, 2016 Listing possible duplicate users. Not finished. (202623 lines)
1 change necessary in database:
INSERT INTO actions (ActCod,Language,Obsolete,Txt) VALUES ('1578','es','N','Listar usuarios duplicados');
Version 15.225.3: Jun 15, 2016 New database table to report users as possible duplicates. (202550 lines) Version 15.225.3: Jun 15, 2016 New database table to report users as possible duplicates. (202550 lines)
1 change necessary in database: 1 change necessary in database:
CREATE TABLE IF NOT EXISTS usr_duplicated (UsrCod INT NOT NULL,InformerCod INT NOT NULL,InformTime DATETIME NOT NULL,UNIQUE INDEX(UsrCod,InformerCod),INDEX(UsrCod)); CREATE TABLE IF NOT EXISTS usr_duplicated (UsrCod INT NOT NULL,InformerCod INT NOT NULL,InformTime DATETIME NOT NULL,UNIQUE INDEX(UsrCod,InformerCod),INDEX(UsrCod));

View File

@ -9559,6 +9559,27 @@ const char *Txt_downloads = // As a noun
"downloads"; "downloads";
#endif #endif
const char *Txt_Duplicate_USERS =
#if L==1
"Duplicats";
#elif L==2
"Doppelte";
#elif L==3
"Duplicates";
#elif L==4
"Duplicados";
#elif L==5
"En double";
#elif L==6
"Duplicados"; // Okoteve traducción
#elif L==7
"Duplicati";
#elif L==8
"Duplikaty";
#elif L==9
"Duplicados";
#endif
const char *Txt_Edit = const char *Txt_Edit =
#if L==1 #if L==1
"Editar"; "Editar";
@ -28456,6 +28477,27 @@ const char *Txt_Plugins =
"Plugins"; "Plugins";
#endif #endif
const char *Txt_Possibly_duplicate_users =
#if L==1
"Usuaris possiblement duplicats";
#elif L==2
"Mögliche doppelte Benutzer";
#elif L==3
"Possibly duplicate users";
#elif L==4
"Usuarios posiblemente duplicados";
#elif L==5
"Possibles utilisateurs en double";
#elif L==6
"Usuarios posiblemente duplicados"; // Okoteve traducción
#elif L==7
"Possibili utenti duplicati";
#elif L==8
"Możliwe duplikaty użytkowników";
#elif L==9
"Usuários possivelmente duplicados";
#endif
const char *Txt_Post_X_allowed = // Warning: it is very important to include %u in the following sentences const char *Txt_Post_X_allowed = // Warning: it is very important to include %u in the following sentences
#if L==1 #if L==1
"Mensaje %u permitido."; // Necessita traduccio "Mensaje %u permitido."; // Necessita traduccio

View File

@ -6099,6 +6099,9 @@ void Usr_ListDataAdms (void)
/* Put link to go to admin one user */ /* Put link to go to admin one user */
Enr_PutLinkToAdminOneUsr (ActReqMdfOneOth); Enr_PutLinkToAdminOneUsr (ActReqMdfOneOth);
/* Put link to list possible duplicate users */
Usr_PutLinkToListDupUsrs ();
/* Put link to remove old users */ /* Put link to remove old users */
Enr_PutLinkToRemOldUsrs (); Enr_PutLinkToRemOldUsrs ();
@ -6132,7 +6135,7 @@ void Usr_ListDataAdms (void)
/***** Get and order list of administrators *****/ /***** Get and order list of administrators *****/
Usr_GetAdmsLst (Gbl.Scope.Current); Usr_GetAdmsLst (Gbl.Scope.Current);
/***** Start table with list of administrators *****/ /***** Start frame with list of administrators *****/
Lay_StartRoundFrame (NULL,Txt_ROLES_PLURAL_Abc[Rol_DEG_ADM][Usr_SEX_UNKNOWN],NULL); Lay_StartRoundFrame (NULL,Txt_ROLES_PLURAL_Abc[Rol_DEG_ADM][Usr_SEX_UNKNOWN],NULL);
/***** Form to select range of administrators *****/ /***** Form to select range of administrators *****/
@ -6193,7 +6196,7 @@ void Usr_ListDataAdms (void)
else // Gbl.Usrs.LstAdms.NumUsrs == 0 else // Gbl.Usrs.LstAdms.NumUsrs == 0
Lay_ShowAlert (Lay_INFO,Txt_No_users_found[Rol_DEG_ADM]); Lay_ShowAlert (Lay_INFO,Txt_No_users_found[Rol_DEG_ADM]);
/***** End of frame *****/ /***** End frame *****/
Lay_EndRoundFrame (); Lay_EndRoundFrame ();
/***** Free memory for teachers list *****/ /***** Free memory for teachers list *****/
@ -7877,3 +7880,33 @@ void Usr_ReportUsrAsPossibleDuplicate (void)
else else
Lay_ShowAlert (Lay_WARNING,Txt_User_not_found_or_you_do_not_have_permission_); Lay_ShowAlert (Lay_WARNING,Txt_User_not_found_or_you_do_not_have_permission_);
} }
/*****************************************************************************/
/************ Put a link (form) to list possible duplicate users *************/
/*****************************************************************************/
void Usr_PutLinkToListDupUsrs (void)
{
extern const char *Txt_Duplicate_USERS;
/***** Put form to remove old users *****/
Lay_PutContextualLink (ActLstDupUsr,NULL,"usrs64x64.gif",
Txt_Duplicate_USERS,Txt_Duplicate_USERS);
}
/*****************************************************************************/
/*********************** List possible duplicate users ***********************/
/*****************************************************************************/
void Usr_ListDuplicateUsrs (void)
{
extern const char *Txt_Possibly_duplicate_users;
/***** Start frame with list of possible duplicate users *****/
Lay_StartRoundFrame (NULL,Txt_Possibly_duplicate_users,NULL);
Lay_ShowAlert (Lay_INFO,"Option under development."); // TODO: Write listing of users
/***** End frame *****/
Lay_EndRoundFrame ();
}

View File

@ -351,5 +351,7 @@ bool Usr_CheckIfUsrBanned (long UsrCod);
void Usr_RemoveUsrFromUsrBanned (long UsrCod); void Usr_RemoveUsrFromUsrBanned (long UsrCod);
void Usr_ReportUsrAsPossibleDuplicate (void); void Usr_ReportUsrAsPossibleDuplicate (void);
void Usr_PutLinkToListDupUsrs (void);
void Usr_ListDuplicateUsrs (void);
#endif #endif