| Requires any of the roles: | Agent, Administrator |
| PUT,OPTIONS | /v1/project/job/{JobID}/schedule |
|---|
"use strict";
export class TimelineCrew {
/** @param {{ProjectJobCrewMemberID?:number,ContactID?:number,ContactName?:string,BudgetedHours?:number}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {number} */
ProjectJobCrewMemberID;
/** @type {number} */
ContactID;
/** @type {string} */
ContactName;
/** @type {?number} */
BudgetedHours;
}
export class TimelineEquipment {
/** @param {{ProjectJobEquipmentID?:number,EquipmentID?:number,EquipmentName?:string}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {number} */
ProjectJobEquipmentID;
/** @type {number} */
EquipmentID;
/** @type {string} */
EquipmentName;
}
export class TimelineJob {
/** @param {{JobID?:number,JobName?:string,ExpectedStartDate?:string,ExpectedCompletionDate?:string,ActualStartDate?:string,ActualEndDate?:string,PercentComplete?:number,StatusID?:number,JobCategory?:string,IsAgreementVisit?:boolean,OccurrenceDate?:string,Crew?:TimelineCrew[],Equipment?:TimelineEquipment[]}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {number} */
JobID;
/** @type {string} */
JobName;
/** @type {?string} */
ExpectedStartDate;
/** @type {?string} */
ExpectedCompletionDate;
/** @type {?string} */
ActualStartDate;
/** @type {?string} */
ActualEndDate;
/** @type {number} */
PercentComplete;
/** @type {?number} */
StatusID;
/** @type {string} */
JobCategory;
/** @type {boolean} */
IsAgreementVisit;
/** @type {?string} */
OccurrenceDate;
/** @type {TimelineCrew[]} */
Crew = [];
/** @type {TimelineEquipment[]} */
Equipment = [];
}
export class JobScheduleUpdateResponse {
/** @param {{ResponseStatus?:ResponseStatus,Job?:TimelineJob}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {ResponseStatus} */
ResponseStatus;
/** @type {TimelineJob} */
Job;
}
export class JobScheduleUpdateRequest {
/** @param {{JobID?:number,ExpectedStartDate?:string,ExpectedCompletionDate?:string,PercentComplete?:number}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {number} */
JobID;
/** @type {?string} */
ExpectedStartDate;
/** @type {?string} */
ExpectedCompletionDate;
/** @type {?number} */
PercentComplete;
}
JavaScript JobScheduleUpdateRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
PUT /v1/project/job/{JobID}/schedule HTTP/1.1
Host: api.dev.dynamics.trendsic.com
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length
{
JobID: 0,
ExpectedStartDate: 0001-01-01,
ExpectedCompletionDate: 0001-01-01,
PercentComplete: 0
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length
{
ResponseStatus:
{
ErrorCode: String,
Message: String,
StackTrace: String,
Errors:
[
{
ErrorCode: String,
FieldName: String,
Message: String,
Meta:
{
String: String
}
}
],
Meta:
{
String: String
}
},
Job:
{
JobID: 0,
JobName: String,
ExpectedStartDate: 0001-01-01,
ExpectedCompletionDate: 0001-01-01,
ActualStartDate: 0001-01-01,
ActualEndDate: 0001-01-01,
PercentComplete: 0,
StatusID: 0,
JobCategory: String,
IsAgreementVisit: False,
OccurrenceDate: 0001-01-01,
Crew:
[
{
ProjectJobCrewMemberID: 0,
ContactID: 0,
ContactName: String,
BudgetedHours: 0
}
],
Equipment:
[
{
ProjectJobEquipmentID: 0,
EquipmentID: 0,
EquipmentName: String
}
]
}
}