Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Overview


This web service deletes a specified project role task (PwsProjectTaskRef) and returns the identity of the deleted project role.task (PwsProjectTaskRef)

Request Format


Panel
titlePwsDeleteProjectTask Request

Request Elements


a Base64 encoded timestamp utilized for engagement locking. To protect against overwriting other changes, you may optionally echo back the timestamp returned in a prior response. This if any change has been made between the two invocations

Element

Data Type

Required?

Default

Description

Sample Data

RequestId

Int32



Click here for more information.


SessionTicket

String



Click here for more information.


CascadeDeleteFlag

Boolean

No

false

If set to 'true', deleting a parent task deletes all children tasks. If set to 'false' and there is child task, this request will fail.

true

CloseIfInuseFlag

Boolean

No

false

If set to 'true' and the task being deleted is in use (e.g. time has been reported against the task), the task will be closed for time entry instead of being deleted. If set to 'false' and there is reported time, this request will fail.

true

ProjectTaskIdentity

PwsProjectTaskRef

Yes


This is the identity of the project task to be deleted. Click here for more information.


StealLockFlag

Boolean

No

false

If set to 'true', any locks on the project will be stolen if it is currently locked, otherwise, if it is set to 'false' and a lock is in place the service will fail.

false

EngagementTimestamp**deprecated**




EngagementTimestamp

String

**deprecated**




LocksToStealPwsEntityLockSummaryNo
The detailed information of the locks that are to be stolen. If not specified, the request will fail if any requested locks are already held. If specified, the information supplied must exactly match the current state of existing locks or the attempt to steal the existing locks will fail. Typically, this service is invoked with LocksToSteal empty or null. If there are existing locks, they will be returned in the LockHolders member of PwsFault. This data can then be sent, as is, back to the server in a second invocation of this service, as LocksToSteal, if the caller desires to steal the locks.
ProjectorLockSetIdInt32No
A projector lock set id is an identifier for a group of one or more locks held as a unit.
RateTaskTimestampStringNo
This is an optimistic locking timestamp that, if provided on update request, will cause the request to fail when the timestamp stored in the database does not match the provided value.

Request Usage Example(s)


Code Block
languagexml
titleExample 01
collapsetrue
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:pws="http://projectorpsa.com/PwsProjectorServices/" xmlns:req="http://projectorpsa.com/DataContracts/Requests/" xmlns:sch="http://projectorpsa.com/DataContracts/Shared/Scheduling/" xmlns:com="http://projectorpsa.com/DataContracts/Shared/Common/">
   <soapenv:Header/>
   <soapenv:Body>
      <pws:PwsDeleteProjectTask>
         <pws:serviceRequest>
            <req:SessionTicket>AZ2QD+hg1Hm7vSa7Y3Lm3w==</req:SessionTicket>
            <sch:CascadeDeleteFlag>true</sch:CascadeDeleteFlag>
            <sch:CloseIfInuseFlag>true</sch:CloseIfInuseFlag>
            <sch:ProjectTaskIdentity>
               <com:ProjectTaskUid>1152921504608735070</com:ProjectTaskUid>
            </sch:ProjectTaskIdentity>
            <sch:StealLockFlag>true</sch:StealLockFlag>
         </pws:serviceRequest>
      </pws:PwsDeleteProjectTask>
   </soapenv:Body>
</soapenv:Envelope>


Response Format


Panel
titlePwsDeleteProjectTask Response


Response Elements


Element

Data Type

Description

Sample Data

Messages

PwsMessage[]

The web service response status and message. Click here for more information.


ResponseId

Int32

Click here for more information.

0

Status

RequestStatus

Click here for more information.

Ok

ServerTimestampUtc

DateTime

Click here for more information.


ProjectTaskIdentity

PwsProjectTaskRef

This is the identity of the project task that was deleted. Click here for more information.


EngagementTimestamp

StringSee EngagementTimestamp above in Request Elements table

**deprecated**


LockStolenFromUserIdentity

PwsUserRefIf a lock is stolen in the process of updating an engagement, this identifies the user from which the lock was stolen from. Click here for more information

**deprecated**


RateTaskTimestampStringThis is an optimistic locking timestamp that, if provided on update request, will cause the request to fail when the timestamp stored in the database does not match the provided value.
StolenLocksPwsEntityLockSummaryThis structure contains information about the locks that were stolen in order to complete this request, Will be included only when LocksToSteal is specified in the request.

Response Usage Example(s)

...

Code Block
languagexml
titleExample 01
collapsetrue
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
   <s:Body>
      <PwsDeleteProjectTaskResponse xmlns="http://projectorpsa.com/PwsProjectorServices/">
         <PwsDeleteProjectTaskResult xmlns:a="http://projectorpsa.com/DataContracts/Shared/Scheduling/" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
            <Messages xmlns="http://projectorpsa.com/CommonServices/" xmlns:b="http://projectorpsa.com/DataContracts/Shared/Common/"/>
            <ResponseId xmlns="http://projectorpsa.com/CommonServices/">0</ResponseId>
            <Status xmlns="http://projectorpsa.com/CommonServices/">Ok</Status>
            <ServerTimestampUtc xmlns="http://projectorpsa.com/CommonServices/">2018-02-28T19:52:42.4283848Z</ServerTimestampUtc>
            <a:ProjectTaskIdentity xmlns:b="http://projectorpsa.com/DataContracts/Shared/Common/">
               <b:ExternalSystemIdentifier i:nil="true"/>
               <b:ProjectTaskId i:nil="true"/>
               <b:ProjectTaskUid>1152921504608735070</b:ProjectTaskUid>
            </a:ProjectTaskIdentity>
            <a:EngagementTimestamp>AAAAAA+vif4=</a:EngagementTimestamp>
            <a:LockStolenFromUserIdentity i:nil="true" xmlns:b="http://projectorpsa.com/DataContracts/Shared/Common/"/>
         </PwsDeleteProjectTaskResult>
      </PwsDeleteProjectTaskResponse>
   </s:Body>
</s:Envelope>

PwsDeleteProjectTask - Common Errors and Warnings


ErrorNumberErrorCodeErrorText
54074RoleHasHoursBookedOrRequestedThis project role
103TaskClosedThe project task is in use and cannot be deleted. It was closed for time instead.
54201TaskHasTimeReportedThis project task cannot be deleted because time has been reported against it or there has been invoicing activity involving the project.
54202TaskHasChildTasksThis project task cannot be deleted because it has
hours booked or requested to it
child tasks. Specify CascadeDeleteFlag to recursively delete child tasks.