none
PSI: Updating actual work for an assignment RRS feed

  • Question

  • Sorry if this is long, but I'm trying to be thorough and provide as much info as possible:

    I'm attempting to update the actual work for a particular day for an assignment.

    I've constructed the relevant change XML. It looks like this:

    <Changes>
        <Proj ID="bea2e0b6-6c8a-e611-813c-02b303a7df7d">
            <Assn ID="9645c2ba-6c8a-e611-8139-02fd2309a0e3" ResID="d90b6c62-2c7c-e611-813c-02b303a7df7d">
                <PeriodChange PID="251658250" Start="2016-10-06T00:00:00-00:00" End="2016-10-06T00:00:00-00:00">60000</PeriodChange>
            </Assn>
        </Proj>
    </Changes>

    And I'm calling this to submit the update:

            public void UpdateStatus(Guid projUid, Guid assnUid, Guid resUid, TimeSpan hoursWorked, DateTime date)
            {
                var xml = CreateUpdateStatusXml(projUid, assnUid, resUid, hoursWorked, date);
                using (var client = _ClientFactory.GetStatusingClient())
                {
                    client.UpdateStatus(xml);
                    client.SubmitStatusForResource(resUid, new[] { assnUid }, "I did some stuff");
                }
            }

    So now I'll put on my project manager's hat and head over to the approvals bin in PWA. Right away I see something is wrong:

    Approval Bin

    Task 3 is a task that I updated through PWA. I added 1.1 hours of actual work on 10/6. Task 4 is the task that I updated via the API. But it doesn't show any work for 10/6. Curious.

    If I click on Task 3, it shows me this:

    That looks right. 

    If I click on Task 4:

    That looks correct too? So what is the difference between the two updates.

    I'm feeling bold, so I'll go ahead and accept both updates and publish them.

    If I return to the Tasks page, I see this:

    This is really weird. Both Task 3 and Task 4 started with 20h in the "Work" column.

    Now, Task 3 -- the one I updated with PWA -- properly shows "Actual" of 1.1h and "Remaining" of 18.9h.

    Task 4, by contrast, shows no actual work. But curiously, the "Work" column has been decremented by 1 hour.

    So, at long last, the question:

    What am I doing wrong/missing? What do I need to do to properly update the work for Task 4?


    Bryan Slatner

    Thursday, October 6, 2016 9:46 PM

All replies

  • I think I may have solved my own problem. The issue appears to be with the Start and End attributes in the XML.

    If I set start to "2016-10-06T00:00:00" and end to "2016-10-06T23:59:59" then it seems to work as expected.


    Bryan Slatner

    • Proposed as answer by Sunitha vv Friday, March 24, 2017 5:33 AM
    • Unproposed as answer by Sunitha vv Friday, March 24, 2017 5:33 AM
    Friday, October 7, 2016 10:20 PM