Version 15.123.7

This commit is contained in:
Antonio Cañas Vargas 2016-01-22 12:55:28 +01:00
parent b4c410deda
commit a3379035aa
4 changed files with 19 additions and 13 deletions

View File

@ -121,13 +121,14 @@
/****************************** Public constants *****************************/
/*****************************************************************************/
#define Log_PLATFORM_VERSION "SWAD 15.123.6 (2016-01-22)"
#define Log_PLATFORM_VERSION "SWAD 15.123.7 (2016-01-22)"
#define CSS_FILE "swad15.121.7.css"
#define JS_FILE "swad15.121.7.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 15.123.7: Jan 22, 2016 New social notifications. Not finished. (194347 lines)
Version 15.123.6: Jan 22, 2016 New social notifications. Not finished. (194342 lines)
Version 15.123.5: Jan 22, 2016 New social notifications. Not finished. (194328 lines)
Version 15.123.4: Jan 22, 2016 New social notifications. Not finished. (194281 lines)

View File

@ -844,6 +844,7 @@ void Ntf_GetNotifSummaryAndContent (char *SummaryStr,char **ContentStr,
Soc_GetNotifNewSocialPost (SummaryStr,ContentStr,Cod,MaxChars,GetContent);
break;
case Ntf_EVENT_SOCIAL_COMMENT:
Soc_GetNotifNewSocialComment (SummaryStr,ContentStr,Cod,MaxChars,GetContent);
break;
case Ntf_EVENT_SOCIAL_FAV:
break;
@ -1197,17 +1198,18 @@ unsigned Ntf_StoreNotifyEventsToAllUsrs (Ntf_NotifyEvent_t NotifyEvent,long Cod)
Gbl.CurrentDeg.Deg.DegCod,
Gbl.Usrs.Me.UsrDat.UsrCod);
break;
case Ntf_EVENT_SOCIAL_POST:
case Ntf_EVENT_SOCIAL_POST: // New social post from one of the users I follow
// Get all my followers
sprintf (Query,"SELECT FollowerCod FROM usr_follow"
" WHERE FollowedCod='%ld'",
Gbl.Usrs.Me.UsrDat.UsrCod);
break;
case Ntf_EVENT_SOCIAL_COMMENT:
case Ntf_EVENT_SOCIAL_COMMENT: // New comment to one of my social notes
!!!
break;
case Ntf_EVENT_SOCIAL_FAV:
case Ntf_EVENT_SOCIAL_FAV: // New favourite to one of my social notes or comments
break;
case Ntf_EVENT_SOCIAL_SHARE:
case Ntf_EVENT_SOCIAL_SHARE: // New sharing of one of my social notes
break;
case Ntf_EVENT_FOLLOWER: // This function should not be called in this case
return 0;

View File

@ -59,13 +59,13 @@ typedef enum
Ntf_EVENT_ENROLLMENT_REQUEST = 8,
/* Social tab */
Ntf_EVENT_SOCIAL_POST = 9,
Ntf_EVENT_SOCIAL_COMMENT = 10,
Ntf_EVENT_SOCIAL_FAV = 11,
Ntf_EVENT_SOCIAL_SHARE = 12,
Ntf_EVENT_FOLLOWER = 13, // Old 14
Ntf_EVENT_FORUM_POST_COURSE = 14, // Old 10
Ntf_EVENT_FORUM_REPLY = 15, // Old 11
Ntf_EVENT_SOCIAL_POST = 9, // New social post from one of the users I follow
Ntf_EVENT_SOCIAL_COMMENT = 10, // New comment to one of my social notes
Ntf_EVENT_SOCIAL_FAV = 11, // New favourite to one of my social notes or comments
Ntf_EVENT_SOCIAL_SHARE = 12, // New sharing of one of my social notes
Ntf_EVENT_FOLLOWER = 13, // Old 14
Ntf_EVENT_FORUM_POST_COURSE = 14, // Old 10 // New post in forums of my courses
Ntf_EVENT_FORUM_REPLY = 15, // Old 11 // New reply to one of my posts in any forum
/* Messages tab */
Ntf_EVENT_NOTICE = 16, // Old 9

View File

@ -1992,7 +1992,7 @@ static long Soc_ReceiveSocialPost (void)
/* Insert post in social notes */
NotCod = Soc_StoreAndPublishSocialNote (Soc_NOTE_SOCIAL_POST,PstCod);
/***** Notify by e-mail about the new notice *****/
/***** Store notification about the new post *****/
Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_SOCIAL_POST,NotCod);
}
else
@ -2706,6 +2706,9 @@ static long Soc_ReceiveComment (void)
Content);
DB_QueryINSERT (Query,"can not store comment content");
/***** Store notification about the new comment *****/
Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_SOCIAL_COMMENT,SocNot.NotCod);
/***** Show the social note just commented *****/
Soc_WriteSocialNote (&SocNot,
Soc_TOP_MESSAGE_COMMENTED,Gbl.Usrs.Me.UsrDat.UsrCod,