Question

I want to make a gadget that lists all the users with their current workitems shown.

How do I get the current work item which is shown in the page-tree in editor-mode. For example, when user 1 works with page 1 you can see that there is a little person-icon next to the name and if you hoover over it, it will say user 1.

Although it is possible to loop all pages in the page-tree and get latest changes, but that would be tough on the server.

Was it helpful?

Solution

There is an API for the notifications. Try this:

using EPiServer.Editor.Notification;

InUseNotificationRepository pagesInUseRepo = new InUseNotificationRepository();
var notifications = pagesInUseRepo.GetAllInUseNotifications();
foreach (var notification in notifications)
{
    // notification.PageGuid
}
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top