Version 15.77.4

This commit is contained in:
Antonio Cañas Vargas 2015-12-29 01:28:17 +01:00
parent 32e742535b
commit dbc97595fc
7 changed files with 24 additions and 15 deletions

View File

@ -1672,12 +1672,14 @@ a:hover img.CENTRE_PHOTO_SHOW
display:inline-block;
text-align:left;
vertical-align:top;
width:64px;
width:60px;
height:90px;
}
.SOCIAL_RIGHT_CONTAINER
{
display:inline-block;
padding:0 0 10px 10px;
width:400px;
}
.SOCIAL_RIGHT_AUTHOR
{

View File

@ -114,12 +114,14 @@
/****************************** Public constants *****************************/
/*****************************************************************************/
#define Log_PLATFORM_VERSION "SWAD 15.77.3 (2015-12-28)"
#define CSS_FILE "swad15.77.2.css"
#define Log_PLATFORM_VERSION "SWAD 15.77.4 (2015-12-29)"
#define CSS_FILE "swad15.77.4.css"
// 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 15.77.4: Dec 29, 2015 Insert social event when publishing a new notice.
Changes in CSS related to social activity. (188410 lines)
Version 15.77.3: Dec 28, 2015 Insert social event when changing file from private to public. (188402 lines)
Version 15.77.2: Dec 28, 2015 Changes in CSS related to social activity. (188368 lines)
Version 15.77.1: Dec 28, 2015 Insert social event when posting in a global forum. (188342 lines)

View File

@ -36,6 +36,7 @@
#include "swad_notification.h"
#include "swad_parameter.h"
#include "swad_RSS.h"
#include "swad_social.h"
/*****************************************************************************/
/************** External global variables from others modules ****************/
@ -153,6 +154,9 @@ void Not_ReceiveNotice (void)
if ((NumUsrsToBeNotifiedByEMail = Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_NOTICE,NotCod)))
Not_UpdateNumUsrsNotifiedByEMailAboutNotice (NotCod,NumUsrsToBeNotifiedByEMail);
Ntf_ShowAlertNumUsrsToBeNotifiedByEMail (NumUsrsToBeNotifiedByEMail);
/***** Create a new social event about the new notice *****/
Soc_StoreSocialEvent (Soc_EVENT_NOTICE,NotCod);
}
/*****************************************************************************/
@ -719,11 +723,12 @@ static void Not_DrawANotice (Not_Listing_t TypeNoticesListing,
}
/*****************************************************************************/
/********************* Write first characters of a notice *******************/
/******************* Get summary and content for a notice ********************/
/*****************************************************************************/
// This function may be called inside a web service, so don't report error
void Not_GetNotifNotice (char *SummaryStr,char **ContentStr,long NotCod,unsigned MaxChars,bool GetContent)
void Not_GetSummaryAndContentNotice (char *SummaryStr,char **ContentStr,
long NotCod,unsigned MaxChars,bool GetContent)
{
char Query[512];
MYSQL_RES *mysql_res;

View File

@ -68,7 +68,8 @@ void Not_RemoveNotice (void);
void Not_GetNotToShowHighlighted (void);
void Not_ShowNotices (Not_Listing_t TypeNoticesListing,bool ICanEditNotices);
void Not_GetNotifNotice (char *SummaryStr,char **ContentStr,long NotCod,unsigned MaxChars,bool GetContent);
void Not_GetSummaryAndContentNotice (char *SummaryStr,char **ContentStr,
long NotCod,unsigned MaxChars,bool GetContent);
unsigned Not_GetNumNotices (Sco_Scope_t Scope,Not_Status_t Status,unsigned *NumNotif);
unsigned Not_GetNumNoticesDeleted (Sco_Scope_t Scope,unsigned *NumNotif);

View File

@ -755,7 +755,7 @@ void Ntf_GetNotifSummaryAndContent (char *SummaryStr,char **ContentStr,Ntf_Notif
Enr_GetNotifEnrollmentRequest (SummaryStr,ContentStr,Cod,MaxChars,GetContent);
break;
case Ntf_EVENT_NOTICE:
Not_GetNotifNotice (SummaryStr,ContentStr,Cod,MaxChars,GetContent);
Not_GetSummaryAndContentNotice (SummaryStr,ContentStr,Cod,MaxChars,GetContent);
break;
case Ntf_EVENT_FORUM_POST_COURSE:
case Ntf_EVENT_FORUM_REPLY:

View File

@ -33,6 +33,7 @@
#include "swad_database.h"
#include "swad_global.h"
#include "swad_layout.h"
#include "swad_notice.h"
#include "swad_social.h"
/*****************************************************************************/
@ -43,7 +44,7 @@
/***************************** Private constants *****************************/
/*****************************************************************************/
#define Soc_MAX_BYTES_SUMMARY 200
#define Soc_MAX_BYTES_SUMMARY 100
/*****************************************************************************/
/****************************** Internal types *******************************/
@ -358,11 +359,10 @@ static void Soc_GetEventSummary (Soc_SocialEvent_t SocialEvent,long Cod,
break;
case Soc_EVENT_EXAM_ANNOUNCEMENT:
break;
case Soc_EVENT_MARKS_FILE:
break;
case Soc_EVENT_SOCIAL_POST:
break;
case Soc_EVENT_NOTICE:
Not_GetSummaryAndContentNotice (SummaryStr,NULL,Cod,MaxChars,false);
break;
case Soc_EVENT_FORUM_POST:
For_GetSummaryAndContentForumPst (SummaryStr,NULL,Cod,MaxChars,false);

View File

@ -35,7 +35,7 @@
/******************************** Public types *******************************/
/*****************************************************************************/
#define Soc_NUM_SOCIAL_EVENTS 14
#define Soc_NUM_SOCIAL_EVENTS 13
// If the numbers assigned to each event type change,
// it is necessary to change old numbers to new ones in database table social
@ -61,16 +61,15 @@ typedef enum
/* Assessment tab */
Soc_EVENT_EXAM_ANNOUNCEMENT = 9,
Soc_EVENT_MARKS_FILE = 10,
/* Enrollment tab */
/* Social tab */
Soc_EVENT_SOCIAL_POST = 11,
Soc_EVENT_SOCIAL_POST = 10,
/* Messages tab */
Soc_EVENT_NOTICE = 12,
Soc_EVENT_FORUM_POST = 13,
Soc_EVENT_NOTICE = 11,
Soc_EVENT_FORUM_POST = 12,
/* Statistics tab */