Esempio n. 1
0
        public Counts GetNewMessagesCount()
        {
            var user = (IUserAccount)Context.User.Identity;

            CoreContext.TenantManager.SetCurrentTenant(user.Tenant);
            var currentUser = CoreContext.UserManager.GetUsers(user.ID);
            var counts      = new Counts();

            counts.MessagesCount = GetMessagesCount(currentUser);
            counts.FeedsCount    = GetUserFeedsCount();
            counts.MailsCount    = GetMailsCount(currentUser);

            return(counts);
        }
Esempio n. 2
0
        public Counts GetNewMessagesCount()
        {
            var user = (IUserAccount)Context.User.Identity;
            CoreContext.TenantManager.SetCurrentTenant(user.Tenant);
            var currentUser = CoreContext.UserManager.GetUsers(user.ID);
            var counts = new Counts();
            counts.MessagesCount = GetMessagesCount(currentUser);
            counts.FeedsCount = GetUserFeedsCount();
            counts.MailsCount = GetMailsCount(currentUser);

            return counts;
        }