In SharePoint 2013, there are two task list templates and, consequently, two types of task lists:
SPListTemplateType.Task
(Id==107) – this one is from SharePoint 2010
SPListTemplateType.TasksWithTimelineAndHierarchy
(Id== 175) – this one is introduced in SharePoint 2013.
The second list is quite different, both visually and internally, for example it has the ParentID column which allows creating a task hierarchy.
In SharePoint 2013, when adding a task list, you add a list with the TasksWithTimelineAndHierarchy
template.
I haven’t seen it documented anywhere but the User Tasks web part retrieves tasks only from the first list type. More technically, it seems to use SPSiteDataQuery
with
<Lists ServerTemplate="107" />
Therefore, it will never show a task from a task list added in SP 2013 using a browser.
If you have to use this web part, you can add a task list with the old template programmatically, e.g. with PowerShell:
$web = Get-SPWeb -Identity http://localhost/yourWebUrl
$web.Lists.Add("Tasks2010","Task list with SharePoint 2010 template",[Microsoft.SharePoint.SPListTemplateType]::Tasks)
Tasks added to this list (assigned to the current user and incomplete) will be visible in a User Tasks web part.
To sum up: The web part was fully functional in SP2010 where SPListTemplateType.Task
was used for task lists. In SharePoint 2013 it is available for compatibility reasons, for webs upgraded from SP2010.
Shame it isn’t stated clearly anywhere, people keep wasting time.