Task list hierarchies?

Mar 22, 2014 at 1:11 AM
Hi,

I'm trying to make a web page using JQuery and SPServices that walked through a Sharepoint 2013 Task List, and display it in a specialized HTML table. I can get to the task name, assignee, etc, without problem.

I can't seem figure out which field contains the "hierarchy" (i.e. summary tasks vs child tasks) information. I've tried:

$(this).attr("ows__Level");

and

$(this).attr("ows__FileDirRef");

Neither seem to contain what I want (Level is always "1"). Anybody know where the information is hidden?

Thanks,
John
Mar 28, 2014 at 11:49 PM
Any thoughts on this?

When I bring up tasks in a view in SP2013 I see a distinct hierarchical and physical ordering. But, when I query via SPServices, they come in completely scrambled.
Mar 29, 2014 at 2:52 AM
Your list view is probably sorted in its definition.

--
Paul T.

-- Sent from Mobile

Mar 31, 2014 at 4:25 PM
No, there is no sort order for the list view define.

There is some sort of "physical" order that's used by the task list, because in the keyboard shortcuts in the grid editing view, it provides a "Move Up" and "Move Down" capability, along with indent and outdent. It's that order that I'd like to duplicate via a spservices query. What attribute stores that information??
Coordinator
Mar 31, 2014 at 4:52 PM
Is it the Predecessor column which is driving it?

M.
Mar 31, 2014 at 6:12 PM
This is just a shot in the dark, but can you try this URL and see if it matches your results?

https://tenant.sharepoint.com/sites/bramer/_layouts/15/start.aspx#/_layouts/15/reorder.aspx?List={ListGUID}

If your results match the ordering shown here, your results are being sorted by an under the hood column called: Order
You could also opt to pass in the View GUID and SPServices will display the items according to that view, at least that's my understanding of how that works.

Cheers,
Matthew
Mar 31, 2014 at 7:27 PM
sympmarc -- no predecessors are difference. That's a dependency relationship.


iOnline247 -- I'm unclear on what you wanted me to do the URL you sent; it doesn't connect to anything.

I tried adding:

viewName: '5963C680-F40B-4962-92CA-F9F5EFBC65E0',

to my SPServices call, but it doesn't change anything. That was the default view for the list, anyway.

Order does seem to be helping, but it doesn't seem to store the hierarchical relationship, and thus still doesn't display the information correctly.
Coordinator
Mar 31, 2014 at 9:23 PM
Can you post a screenshot somewhere so we can see what you're seeing?

M.
Mar 31, 2014 at 9:26 PM
I suppose I should clarify the link I put above:

https://YOUR_TENANT.sharepoint.com/sites/YOUR_SITE_NAME/_layouts/15/start.aspx#/_layouts/15/reorder.aspx?List=YOUR_ENCODED_LIST_GUID

Some work will be needed on your end to make that link work.

Cheers,
Matthew