Overview
This web service saves changes to time cards. This service should be used to save changes to existing time cards, to insert new time cards or to delete time cards. It is also capable of saving estimates (remaining minutes), saving task notes and performing a submit operation.
The service is written such that a failure to save or delete a time card or time off card, or to save an estimate or task note, will not prevent the saving of other changes, however any failure to save will prevent the submit from occurring, even if the service requests it. Individual errors processing time cards, time off cards, estimates and task notes are reported in the response.
...
Panel | ||
---|---|---|
| ||
|
...
Element | Data Type | Required? | Default | Description | Sample Data |
---|---|---|---|---|---|
RequestId | Int32 | No | Click here for more information | 1 | |
SessionTicket | String | Yes | Click here for more information | AUtZcJgtdfVGhgjNekiP9w== | |
AdministratorComments | String | No | Administrator comments for entering time on behalf of others | Web Service Testing | |
DeleteTimeCards | No | The identity of the time card(s) that will be deleted | |||
DeleteTimeOffCards | No | The identity of the time off time card(s) that will be deleted | |||
EndDate | DateTime | Yes | The EndDate defines the last work or time off date that affected time cards can be logged against. Only time cards with work or time off dates on or prior to this EndDate will be included when the web service is executed. | 2018-03-31T00:00:00.000Z | |
Estimates | No | The estimate to complete for a given task. This is only applicable for time cards logged against a project with detailed task management. | |||
InsertIfNotFoundOnUpdateFlag | Boolean | No | false | If set to 'true', the specified time card or time off time card details will be inserted as a new time card or time off time card if it does not currently exist | true |
ResourceIdentity | No - unless inserting a new time card | The identity of the resource associated with the time card or time off time card | |||
SaveTimeCards | No - unless inserting a new time card | The details of the time card to be saved / updated | |||
SaveTimeOffCards | No - unless inserting a new time off time card | The details of the time off time card to be saved / updated | |||
SendNotificationEmailFlag | Boolean | No | false | If set to 'true', a notification email will be sent to the resource associated with the time card. This is applicable only when entering time on behalf of others. | false |
StartDate | DateTime | Yes | The StartDate defines the first work or time off date that affected time cards can be logged against. Only time cards with work or time off dates on or after this StartDate will be included when the web service is executed. | 2018-03-09T00:00:00.000Z | |
SubmitFlag | Boolean | No | false | If set to 'true', a submit operation will be performed as part of this request. To submit a specific time card or time off card, use SubmitTimeCardIdentity. | true |
Tasks | No | Notes to be saved with the task associated with the time card | |||
SubmitSavedCardsOnlyFlag | Boolean | No | false | If set to 'true', draft time cards associated with the provided resource identity will be submitted | true |
SubmitTimeCardIdentity | No | The specific time card(s) to be submitted, see SubmitFlag | |||
PreserveTimeCardStatusFlag - deprecated | Boolean | *** deprecated *** | *** deprecated *** |
Request Usage Example(s)
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:pws="http://projectorpsa.com/PwsProjectorServices/" xmlns:req="http://projectorpsa.com/DataContracts/Requests/" xmlns:tim="http://projectorpsa.com/DataContracts/Shared/TimeAndCost/" xmlns:com="http://projectorpsa.com/DataContracts/Shared/Common/"> <soapenv:Header/> <soapenv:Body> <pws:PwsSaveTimeCards> <pws:serviceRequest> <req:RequestId>1</req:RequestId> <req:SessionTicket>AUtZcJgtdfVGhgjNekiP9w==</req:SessionTicket> <tim:AdministratorComments>Web Service Testing</tim:AdministratorComments> <tim:EndDate>2018-03-31T00:00:00.000Z</tim:EndDate> <tim:Estimates> <tim:PwsEstimate> <tim:AsOfDate>2018-03-09T00:00:00.000Z</tim:AsOfDate> <tim:CompletedFlag>false</tim:CompletedFlag> <tim:ProjectTaskRoleIdentity> <com:ProjectRoleIdentity> <com:ProjectRoleUid>1152921504609525049</com:ProjectRoleUid> </com:ProjectRoleIdentity> <com:ProjectTaskIdentity> <com:ProjectTaskUid>1152921504608637344</com:ProjectTaskUid> </com:ProjectTaskIdentity> <com:ProjectTaskRoleUid>1152921504608549426</com:ProjectTaskRoleUid> </tim:ProjectTaskRoleIdentity> <tim:RemainingMinutes>360</tim:RemainingMinutes> </tim:PwsEstimate> </tim:Estimates> <tim:InsertIfNotFoundOnUpdateFlag>true</tim:InsertIfNotFoundOnUpdateFlag> <tim:ResourceIdentity> <com:ResourceReferenceSystemId>E123</com:ResourceReferenceSystemId> </tim:ResourceIdentity> <tim:SaveTimeCards> <tim:PwsTimecardDetail> <com:TimecardType>T</com:TimecardType> <tim:DescriptionClearFlag>false</tim:DescriptionClearFlag> <tim:Status>Submitted</tim:Status> <tim:WorkDate>2018-03-09T00:00:00.000Z</tim:WorkDate> <tim:WorkMinutes>60</tim:WorkMinutes> <tim:CardStatus>Submitted</tim:CardStatus> <tim:LocationClearFlag>false</tim:LocationClearFlag> <tim:LocationIdentity> <com:LocationName>USA</com:LocationName> </tim:LocationIdentity> <tim:ProjectIdentity> <com:ProjectCode>P001396-001</com:ProjectCode> </tim:ProjectIdentity> <tim:ProjectRateTypeIdentity> <com:ProjectRateTypeUid>1152921504607370468</com:ProjectRateTypeUid> </tim:ProjectRateTypeIdentity> <tim:ProjectTaskIdentity> <com:ProjectTaskUid>1152921504608637344</com:ProjectTaskUid> </tim:ProjectTaskIdentity> <tim:RoleClearFlag>false</tim:RoleClearFlag> <tim:RoleIdentity> <com:ProjectRoleUid>1152921504609525049</com:ProjectRoleUid> </tim:RoleIdentity> <tim:Udf1ClearFlag>false</tim:Udf1ClearFlag> <tim:Udf2ClearFlag>false</tim:Udf2ClearFlag> <tim:ExternalGroupingIdentifierClearFlag>false</tim:ExternalGroupingIdentifierClearFlag> </tim:PwsTimecardDetail> </tim:SaveTimeCards> <tim:SendNotificationEmailFlag>false</tim:SendNotificationEmailFlag> <tim:StartDate>2018-03-09T00:00:00.000Z</tim:StartDate> <tim:SubmitFlag>true</tim:SubmitFlag> <tim:Tasks> <tim:PwsProjectTaskNote> <tim:Notes>Added via the web service</tim:Notes> <tim:ProjectTaskIdentity> <com:ProjectTaskUid>1152921504608637344</com:ProjectTaskUid> </tim:ProjectTaskIdentity> <tim:EmailPmTeamFlag>false</tim:EmailPmTeamFlag> </tim:PwsProjectTaskNote> </tim:Tasks> <tim:SubmitSavedCardsOnlyFlag>false</tim:SubmitSavedCardsOnlyFlag> <tim:PreserveTimeCardStatusFlag>true</tim:PreserveTimeCardStatusFlag> </pws:serviceRequest> </pws:PwsSaveTimeCards> </soapenv:Body> </soapenv:Envelope> |
...
Panel | ||
---|---|---|
| ||
|
Response Elements
Element | Data Type | Description | Sample Data |
---|---|---|---|
Messages | The web service response status and message. Click here for more information. | ||
ResponseId | Int32 | Click here for more information | 1 |
Status | Click here for more information | ||
ServerTimestampUtc | DateTime | Click here for more information | 2018-03-09T22:22:30.2317159Z |
EstimateResults | The results from saving time card estimates | ||
Locations | The results from saving locations | ||
SubmittedFlag | Boolean | If set to 'true', the time card has a status of submitted | true |
TaskNoteResults | The results from saving task notes | ||
TimeOffCardResults | The results from saving time off time cards | ||
TimecardResults | The results from saving time cards |
...