| Requires any of the roles: | Agent, Administrator |
| GET,OPTIONS | /v1/Rfp/{RfpDocumentUID}/Estimate/Revisions/{RevisionA}/Compare/{RevisionB} |
|---|
"use strict";
export class RevisionLineDelta {
/** @param {{ItemNo?:string,Description?:string,Unit?:string,Change?:string,QuantityA?:number,QuantityB?:number,UnitPriceA?:number,UnitPriceB?:number,ExtensionA?:number,ExtensionB?:number,QuantityDelta?:number,UnitPriceDelta?:number,ExtensionDelta?:number}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
ItemNo;
/** @type {string} */
Description;
/** @type {string} */
Unit;
/** @type {string} */
Change;
/** @type {?number} */
QuantityA;
/** @type {?number} */
QuantityB;
/** @type {?number} */
UnitPriceA;
/** @type {?number} */
UnitPriceB;
/** @type {number} */
ExtensionA;
/** @type {number} */
ExtensionB;
/** @type {number} */
QuantityDelta;
/** @type {number} */
UnitPriceDelta;
/** @type {number} */
ExtensionDelta;
}
export class TaskDiff {
/** @param {{TaskName?:string,PositionsAdded?:string[],PositionsRemoved?:string[],PositionsStaffed?:string[],EquipmentAdded?:number[],EquipmentRemoved?:number[],MaterialsAdded?:number[],MaterialsRemoved?:number[],HasChanges?:boolean}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
TaskName;
/** @type {string[]} */
PositionsAdded = [];
/** @type {string[]} */
PositionsRemoved = [];
/** @type {string[]} */
PositionsStaffed = [];
/** @type {number[]} */
EquipmentAdded = [];
/** @type {number[]} */
EquipmentRemoved = [];
/** @type {number[]} */
MaterialsAdded = [];
/** @type {number[]} */
MaterialsRemoved = [];
/** @type {boolean} */
HasChanges;
}
export class ProposalDiff {
/** @param {{TasksAdded?:string[],TasksRemoved?:string[],Tasks?:TaskDiff[],HasChanges?:boolean}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string[]} */
TasksAdded = [];
/** @type {string[]} */
TasksRemoved = [];
/** @type {TaskDiff[]} */
Tasks = [];
/** @type {boolean} */
HasChanges;
}
export class EstimateRevisionCompareResult {
/** @param {{RevisionA?:number,RevisionB?:number,LabelA?:string,LabelB?:string,TotalA?:number,TotalB?:number,TotalDelta?:number,BidTotalA?:number,BidTotalB?:number,Added?:number,Removed?:number,Changed?:number,Unchanged?:number,Lines?:RevisionLineDelta[],Scope?:ProposalDiff,Summary?:string}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {number} */
RevisionA;
/** @type {number} */
RevisionB;
/** @type {string} */
LabelA;
/** @type {string} */
LabelB;
/** @type {number} */
TotalA;
/** @type {number} */
TotalB;
/** @type {number} */
TotalDelta;
/** @type {number} */
BidTotalA;
/** @type {number} */
BidTotalB;
/** @type {number} */
Added;
/** @type {number} */
Removed;
/** @type {number} */
Changed;
/** @type {number} */
Unchanged;
/** @type {RevisionLineDelta[]} */
Lines = [];
/** @type {ProposalDiff} */
Scope;
/** @type {string} */
Summary;
}
export class EstimateRevisionCompareResponse {
/** @param {{ResponseStatus?:ResponseStatus,Compare?:EstimateRevisionCompareResult}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {ResponseStatus} */
ResponseStatus;
/** @type {EstimateRevisionCompareResult} */
Compare;
}
export class EstimateRevisionCompareRequest {
/** @param {{RfpDocumentUID?:string,RevisionA?:number,RevisionB?:number}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
RfpDocumentUID;
/** @type {number} */
RevisionA;
/** @type {number} */
RevisionB;
}
JavaScript EstimateRevisionCompareRequest 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.
GET /v1/Rfp/{RfpDocumentUID}/Estimate/Revisions/{RevisionA}/Compare/{RevisionB} HTTP/1.1
Host: api.dev.dynamics.trendsic.com
Accept: text/jsv
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
}
},
Compare:
{
RevisionA: 0,
RevisionB: 0,
LabelA: String,
LabelB: String,
TotalA: 0,
TotalB: 0,
TotalDelta: 0,
BidTotalA: 0,
BidTotalB: 0,
Added: 0,
Removed: 0,
Changed: 0,
Unchanged: 0,
Lines:
[
{
ItemNo: String,
Description: String,
Unit: String,
Change: String,
QuantityA: 0,
QuantityB: 0,
UnitPriceA: 0,
UnitPriceB: 0,
ExtensionA: 0,
ExtensionB: 0,
QuantityDelta: 0,
UnitPriceDelta: 0,
ExtensionDelta: 0
}
],
Scope:
{
TasksAdded:
[
String
],
TasksRemoved:
[
String
],
Tasks:
[
{
TaskName: String,
PositionsAdded:
[
String
],
PositionsRemoved:
[
String
],
PositionsStaffed:
[
String
],
EquipmentAdded:
[
0
],
EquipmentRemoved:
[
0
],
MaterialsAdded:
[
0
],
MaterialsRemoved:
[
0
],
HasChanges: True
}
],
HasChanges: True
},
Summary: String
}
}