spitfirepm 23.9600.15 → 23.9600.17

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -25,6 +25,7 @@ apiResult.then( (a) => {
25
25
  ### Change Log
26
26
 
27
27
  ```
28
+ 23.9600.17 - Improves Analytics opt out
28
29
  23.9600.15 - Improves ConfigController
29
30
  23.9600.13 - ARR cleanup
30
31
  23.9600.12 - ARR endpoints
@@ -8,6 +8,10 @@ export declare class APIClientBase {
8
8
  /** Spitfire Assigned Site ID */
9
9
  private static GAClientID;
10
10
  private static GAIgnoreActions;
11
+ /** Set true when the current user has opted out of Analytics data collection (WCCData.GAFMOptOut) */
12
+ private static _GAOptOut;
13
+ /** Synchronizes the client's Analytics opt-out preference. Call whenever WCCData.GAFMOptOut becomes known/changes. */
14
+ static setGAOptOut(optOut: boolean): void;
11
15
  private readonly _dateFormat;
12
16
  protected jsonParseReviver: {
13
17
  (key: string, value: any): any;
@@ -9,6 +9,12 @@ class APIClientBase {
9
9
  /** Spitfire Assigned Site ID */
10
10
  static GAClientID = undefined;
11
11
  static GAIgnoreActions = { account: true, session: true, suggestions: true, uicfg: true, viewable: true };
12
+ /** Set true when the current user has opted out of Analytics data collection (WCCData.GAFMOptOut) */
13
+ static _GAOptOut = false;
14
+ /** Synchronizes the client's Analytics opt-out preference. Call whenever WCCData.GAFMOptOut becomes known/changes. */
15
+ static setGAOptOut(optOut) {
16
+ APIClientBase._GAOptOut = !!optOut;
17
+ }
12
18
  // public static setBaseUrl(usingURL: string) {
13
19
  // APIClientBase._SiteURL = usingURL;
14
20
  // console.log('APIClientBase.setBaseUrl()....${APIClientBase._SiteURL}');
@@ -30,7 +36,7 @@ class APIClientBase {
30
36
  this.jsonParseReviver = this.jsonParseReviverLogic;
31
37
  if (APIClientBase._SiteURL === null) {
32
38
  if (window.location.origin === "http://localhost" && window.location.pathname === "/powerux/") {
33
- console.log('APIClientBase.getBaseUrl(${baseURL})....detected DEV path');
39
+ console.log(`APIClientBase.getBaseUrl(${baseURL})....detected DEV path`);
34
40
  APIClientBase._SiteURL = `http://localhost/sfpms`;
35
41
  }
36
42
  else {
@@ -38,7 +44,7 @@ class APIClientBase {
38
44
  ApplicationPath = ApplicationPath.substring(1, ApplicationPath.length === 1 && ApplicationPath === "/" ? 1 : ApplicationPath.substring(1).indexOf("/") + 1);
39
45
  APIClientBase._SiteURL = `${window.location.origin}/${ApplicationPath || 'sfPMS'}`;
40
46
  }
41
- console.log('APIClientBase.getBaseUrl(${baseURL})....${APIClientBase._SiteURL}');
47
+ console.log(`APIClientBase.getBaseUrl(${baseURL})....${APIClientBase._SiteURL}`);
42
48
  }
43
49
  return APIClientBase._SiteURL;
44
50
  }
@@ -46,7 +52,7 @@ class APIClientBase {
46
52
  const rxAPIURL = /\/\/.+\/api\/(?<controler>\w+)\/(?<endpoint>.*?)(\?|$|\s)/gm;
47
53
  const match = rxAPIURL.exec(url); // vpgName, args, width, height
48
54
  if (match && match.groups && match.groups.controler && match.groups.endpoint) {
49
- if (!(match.groups.controller in APIClientBase.GAIgnoreActions)) {
55
+ if (!(match.groups.controler in APIClientBase.GAIgnoreActions)) {
50
56
  const ep = match.groups.endpoint || '?';
51
57
  const ec = match.groups.controler || '';
52
58
  if (((Date.now() - APIClientBase._LastAt) > 1357) ||
@@ -64,6 +70,8 @@ class APIClientBase {
64
70
  return processor(response);
65
71
  }
66
72
  GAAPIEvent(controllerAction, endpointLabel) {
73
+ if (APIClientBase._GAOptOut)
74
+ return undefined;
67
75
  if (!APIClientBase.GAClientID)
68
76
  return undefined;
69
77
  if (controllerAction == "session" && endpointLabel == "who")
@@ -79,6 +87,8 @@ class APIClientBase {
79
87
  return APIClientBase.GA4MonitorSend(G4Payload);
80
88
  }
81
89
  static GAMonitorEvent(clientID, category, action, label, value) {
90
+ if (APIClientBase._GAOptOut)
91
+ return undefined;
82
92
  if (!clientID && !APIClientBase.GAClientID)
83
93
  return undefined;
84
94
  if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
  private processPostDownloadSessionWithCallbacks;
36
36
  protected processPostDownloadSession(xhr: any): string | null;
37
+ /**
38
+ * Sets the per-account anonymous feature-tracking preference
39
+ * @param enabled True to allow anonymous feature tracking, False to opt out
40
+ */
41
+ setFeatureTracking(enabled: boolean): Promise<boolean>;
42
+ private setFeatureTrackingWithCallbacks;
43
+ private processSetFeatureTrackingWithCallbacks;
44
+ protected processSetFeatureTracking(xhr: any): boolean | null;
37
45
  /**
38
46
  * Digest an identity from an Google token
39
47
  * @param subId google nonvolatile id
@@ -1502,6 +1510,14 @@ export declare class DocumentToolsClient extends APIClientBase {
1502
1510
  beforeSend: any;
1503
1511
  protected jsonParseReviver: ((key: string, value: any) => any) | undefined;
1504
1512
  constructor(baseUrl?: string);
1513
+ /**
1514
+ * Returns the header Of the specified document, including a Document Session Key
1515
+ * @param id Document Key
1516
+ */
1517
+ getDocHeader(id: string): Promise<DocMasterDetail | null>;
1518
+ private getDocHeaderWithCallbacks;
1519
+ private processGetDocHeaderWithCallbacks;
1520
+ protected processGetDocHeader(xhr: any): DocMasterDetail | null | null;
1505
1521
  /**
1506
1522
  * Deletes the specified document
1507
1523
  * @param id Document Key
@@ -1519,14 +1535,6 @@ export declare class DocumentToolsClient extends APIClientBase {
1519
1535
  private updateDocHeaderWithCallbacks;
1520
1536
  private processUpdateDocHeaderWithCallbacks;
1521
1537
  protected processUpdateDocHeader(xhr: any): any | null;
1522
- /**
1523
- * Returns the header Of the specified document, including a Document Session Key
1524
- * @param id Document Key
1525
- */
1526
- getDocHeader(id: string): Promise<DocMasterDetail | null>;
1527
- private getDocHeaderWithCallbacks;
1528
- private processGetDocHeaderWithCallbacks;
1529
- protected processGetDocHeader(xhr: any): DocMasterDetail | null | null;
1530
1538
  /**
1531
1539
  * Updates a Single field On the header Of the specified document
1532
1540
  * @param id Document Key
@@ -1854,14 +1862,6 @@ export declare class DocumentToolsClient extends APIClientBase {
1854
1862
  private addDocCommentsWithCallbacks;
1855
1863
  private processAddDocCommentsWithCallbacks;
1856
1864
  protected processAddDocComments(xhr: any): Comment | null | null;
1857
- /**
1858
- * Returns the compliance for the specified document
1859
- * @param id Document Key
1860
- */
1861
- getDocCompliance(id: string): Promise<DocCompliance[] | null>;
1862
- private getDocComplianceWithCallbacks;
1863
- private processGetDocComplianceWithCallbacks;
1864
- protected processGetDocCompliance(xhr: any): DocCompliance[] | null | null;
1865
1865
  /**
1866
1866
  * Deletes the compliance on the specified document
1867
1867
  * @param id Document Key
@@ -1891,6 +1891,14 @@ export declare class DocumentToolsClient extends APIClientBase {
1891
1891
  private addDocComplianceWithCallbacks;
1892
1892
  private processAddDocComplianceWithCallbacks;
1893
1893
  protected processAddDocCompliance(xhr: any): DocCompliance | null | null;
1894
+ /**
1895
+ * Returns the compliance for the specified document
1896
+ * @param id Document Key
1897
+ */
1898
+ getDocCompliance(id: string): Promise<DocCompliance[] | null>;
1899
+ private getDocComplianceWithCallbacks;
1900
+ private processGetDocComplianceWithCallbacks;
1901
+ protected processGetDocCompliance(xhr: any): DocCompliance[] | null | null;
1894
1902
  /**
1895
1903
  * Returns the Project Details based on the specified document. Update using PatchDocData
1896
1904
  * @param id Document Key
@@ -290,6 +290,73 @@ class AccountClient extends APIClientBase_1.APIClientBase {
290
290
  }
291
291
  return null;
292
292
  }
293
+ /**
294
+ * Sets the per-account anonymous feature-tracking preference
295
+ * @param enabled True to allow anonymous feature tracking, False to opt out
296
+ */
297
+ setFeatureTracking(enabled) {
298
+ return new Promise((resolve, reject) => {
299
+ this.setFeatureTrackingWithCallbacks(enabled, (result) => resolve(result), (exception, _reason) => reject(exception));
300
+ });
301
+ }
302
+ setFeatureTrackingWithCallbacks(enabled, onSuccess, onFail) {
303
+ let url_ = this.baseUrl + "/api/account/featuretracking/{enabled}";
304
+ if (enabled === undefined || enabled === null)
305
+ throw new globalThis.Error("The parameter 'enabled' must be defined.");
306
+ url_ = url_.replace("{enabled}", encodeURIComponent("" + enabled));
307
+ url_ = url_.replace(/[?&]$/, "");
308
+ jQuery.ajax({
309
+ url: url_,
310
+ beforeSend: this.beforeSend,
311
+ type: "post",
312
+ dataType: "text",
313
+ headers: {
314
+ "Accept": "application/json"
315
+ }
316
+ }).done((_data, _textStatus, xhr) => {
317
+ this.processSetFeatureTrackingWithCallbacks(url_, xhr, onSuccess, onFail);
318
+ }).fail((xhr) => {
319
+ this.processSetFeatureTrackingWithCallbacks(url_, xhr, onSuccess, onFail);
320
+ });
321
+ }
322
+ processSetFeatureTrackingWithCallbacks(_url, xhr, onSuccess, onFail) {
323
+ try {
324
+ let result = this.transformResult(_url, xhr, (xhr) => this.processSetFeatureTracking(xhr));
325
+ if (onSuccess !== undefined)
326
+ onSuccess(result);
327
+ }
328
+ catch (e) {
329
+ if (onFail !== undefined)
330
+ onFail(e, "http_service_exception");
331
+ }
332
+ }
333
+ processSetFeatureTracking(xhr) {
334
+ const status = xhr.status;
335
+ let _headers = {};
336
+ if (status === 200) {
337
+ const _responseText = xhr.responseText;
338
+ let result200 = null;
339
+ result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
340
+ return result200;
341
+ }
342
+ else if (status === 401) {
343
+ const _responseText = xhr.responseText;
344
+ let result401 = null;
345
+ result401 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
346
+ return throwException("Not currently authenticated", status, _responseText, _headers, result401);
347
+ }
348
+ else if (status === 500) {
349
+ const _responseText = xhr.responseText;
350
+ let result500 = null;
351
+ result500 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
352
+ return throwException("Internal Error", status, _responseText, _headers, result500);
353
+ }
354
+ else if (status !== 200 && status !== 204) {
355
+ const _responseText = xhr.responseText;
356
+ return throwException("An unexpected server error occurred.", status, _responseText, _headers);
357
+ }
358
+ return null;
359
+ }
293
360
  /**
294
361
  * Digest an identity from an Google token
295
362
  * @param subId google nonvolatile id
@@ -13777,15 +13844,15 @@ class DocumentToolsClient extends APIClientBase_1.APIClientBase {
13777
13844
  this.baseUrl = baseUrl ?? this.getBaseUrl("https://dev.spitfirepm.com:8443/SFPMS");
13778
13845
  }
13779
13846
  /**
13780
- * Deletes the specified document
13847
+ * Returns the header Of the specified document, including a Document Session Key
13781
13848
  * @param id Document Key
13782
13849
  */
13783
- deleteDocHeader(id) {
13850
+ getDocHeader(id) {
13784
13851
  return new Promise((resolve, reject) => {
13785
- this.deleteDocHeaderWithCallbacks(id, (result) => resolve(result), (exception, _reason) => reject(exception));
13852
+ this.getDocHeaderWithCallbacks(id, (result) => resolve(result), (exception, _reason) => reject(exception));
13786
13853
  });
13787
13854
  }
13788
- deleteDocHeaderWithCallbacks(id, onSuccess, onFail) {
13855
+ getDocHeaderWithCallbacks(id, onSuccess, onFail) {
13789
13856
  let url_ = this.baseUrl + "/api/document/{id}";
13790
13857
  if (id === undefined || id === null)
13791
13858
  throw new globalThis.Error("The parameter 'id' must be defined.");
@@ -13794,20 +13861,20 @@ class DocumentToolsClient extends APIClientBase_1.APIClientBase {
13794
13861
  jQuery.ajax({
13795
13862
  url: url_,
13796
13863
  beforeSend: this.beforeSend,
13797
- type: "delete",
13864
+ type: "get",
13798
13865
  dataType: "text",
13799
13866
  headers: {
13800
- "Accept": "application/octet-stream"
13867
+ "Accept": "application/json"
13801
13868
  }
13802
13869
  }).done((_data, _textStatus, xhr) => {
13803
- this.processDeleteDocHeaderWithCallbacks(url_, xhr, onSuccess, onFail);
13870
+ this.processGetDocHeaderWithCallbacks(url_, xhr, onSuccess, onFail);
13804
13871
  }).fail((xhr) => {
13805
- this.processDeleteDocHeaderWithCallbacks(url_, xhr, onSuccess, onFail);
13872
+ this.processGetDocHeaderWithCallbacks(url_, xhr, onSuccess, onFail);
13806
13873
  });
13807
13874
  }
13808
- processDeleteDocHeaderWithCallbacks(_url, xhr, onSuccess, onFail) {
13875
+ processGetDocHeaderWithCallbacks(_url, xhr, onSuccess, onFail) {
13809
13876
  try {
13810
- let result = this.transformResult(_url, xhr, (xhr) => this.processDeleteDocHeader(xhr));
13877
+ let result = this.transformResult(_url, xhr, (xhr) => this.processGetDocHeader(xhr));
13811
13878
  if (onSuccess !== undefined)
13812
13879
  onSuccess(result);
13813
13880
  }
@@ -13816,10 +13883,10 @@ class DocumentToolsClient extends APIClientBase_1.APIClientBase {
13816
13883
  onFail(e, "http_service_exception");
13817
13884
  }
13818
13885
  }
13819
- processDeleteDocHeader(xhr) {
13886
+ processGetDocHeader(xhr) {
13820
13887
  const status = xhr.status;
13821
13888
  let _headers = {};
13822
- if (status === 200 || status === 206) {
13889
+ if (status === 200) {
13823
13890
  const _responseText = xhr.responseText;
13824
13891
  let result200 = null;
13825
13892
  result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
@@ -13835,19 +13902,7 @@ class DocumentToolsClient extends APIClientBase_1.APIClientBase {
13835
13902
  const _responseText = xhr.responseText;
13836
13903
  let result404 = null;
13837
13904
  result404 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
13838
- return throwException("Document not found, or not accessible", status, _responseText, _headers, result404);
13839
- }
13840
- else if (status === 406) {
13841
- const _responseText = xhr.responseText;
13842
- let result406 = null;
13843
- result406 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
13844
- return throwException("Not acceptable", status, _responseText, _headers, result406);
13845
- }
13846
- else if (status === 409) {
13847
- const _responseText = xhr.responseText;
13848
- let result409 = null;
13849
- result409 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
13850
- return throwException("Could Not persist the delete", status, _responseText, _headers, result409);
13905
+ return throwException("Document Not found, Or Not accessible", status, _responseText, _headers, result404);
13851
13906
  }
13852
13907
  else if (status === 500) {
13853
13908
  const _responseText = xhr.responseText;
@@ -13862,41 +13917,37 @@ class DocumentToolsClient extends APIClientBase_1.APIClientBase {
13862
13917
  return null;
13863
13918
  }
13864
13919
  /**
13865
- * Updates the header On the specified document
13920
+ * Deletes the specified document
13866
13921
  * @param id Document Key
13867
- * @param updatedData Replacement data
13868
13922
  */
13869
- updateDocHeader(id, updatedData) {
13923
+ deleteDocHeader(id) {
13870
13924
  return new Promise((resolve, reject) => {
13871
- this.updateDocHeaderWithCallbacks(id, updatedData, (result) => resolve(result), (exception, _reason) => reject(exception));
13925
+ this.deleteDocHeaderWithCallbacks(id, (result) => resolve(result), (exception, _reason) => reject(exception));
13872
13926
  });
13873
13927
  }
13874
- updateDocHeaderWithCallbacks(id, updatedData, onSuccess, onFail) {
13928
+ deleteDocHeaderWithCallbacks(id, onSuccess, onFail) {
13875
13929
  let url_ = this.baseUrl + "/api/document/{id}";
13876
13930
  if (id === undefined || id === null)
13877
13931
  throw new globalThis.Error("The parameter 'id' must be defined.");
13878
13932
  url_ = url_.replace("{id}", encodeURIComponent("" + id));
13879
13933
  url_ = url_.replace(/[?&]$/, "");
13880
- const content_ = JSON.stringify(updatedData);
13881
13934
  jQuery.ajax({
13882
13935
  url: url_,
13883
13936
  beforeSend: this.beforeSend,
13884
- type: "put",
13885
- data: content_,
13937
+ type: "delete",
13886
13938
  dataType: "text",
13887
13939
  headers: {
13888
- "Content-Type": "application/json",
13889
13940
  "Accept": "application/octet-stream"
13890
13941
  }
13891
13942
  }).done((_data, _textStatus, xhr) => {
13892
- this.processUpdateDocHeaderWithCallbacks(url_, xhr, onSuccess, onFail);
13943
+ this.processDeleteDocHeaderWithCallbacks(url_, xhr, onSuccess, onFail);
13893
13944
  }).fail((xhr) => {
13894
- this.processUpdateDocHeaderWithCallbacks(url_, xhr, onSuccess, onFail);
13945
+ this.processDeleteDocHeaderWithCallbacks(url_, xhr, onSuccess, onFail);
13895
13946
  });
13896
13947
  }
13897
- processUpdateDocHeaderWithCallbacks(_url, xhr, onSuccess, onFail) {
13948
+ processDeleteDocHeaderWithCallbacks(_url, xhr, onSuccess, onFail) {
13898
13949
  try {
13899
- let result = this.transformResult(_url, xhr, (xhr) => this.processUpdateDocHeader(xhr));
13950
+ let result = this.transformResult(_url, xhr, (xhr) => this.processDeleteDocHeader(xhr));
13900
13951
  if (onSuccess !== undefined)
13901
13952
  onSuccess(result);
13902
13953
  }
@@ -13905,7 +13956,7 @@ class DocumentToolsClient extends APIClientBase_1.APIClientBase {
13905
13956
  onFail(e, "http_service_exception");
13906
13957
  }
13907
13958
  }
13908
- processUpdateDocHeader(xhr) {
13959
+ processDeleteDocHeader(xhr) {
13909
13960
  const status = xhr.status;
13910
13961
  let _headers = {};
13911
13962
  if (status === 200 || status === 206) {
@@ -13924,19 +13975,19 @@ class DocumentToolsClient extends APIClientBase_1.APIClientBase {
13924
13975
  const _responseText = xhr.responseText;
13925
13976
  let result404 = null;
13926
13977
  result404 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
13927
- return throwException("Document Not found, Or Not accessible", status, _responseText, _headers, result404);
13978
+ return throwException("Document not found, or not accessible", status, _responseText, _headers, result404);
13928
13979
  }
13929
13980
  else if (status === 406) {
13930
13981
  const _responseText = xhr.responseText;
13931
13982
  let result406 = null;
13932
13983
  result406 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
13933
- return throwException("Document number cannot be changed by this method", status, _responseText, _headers, result406);
13984
+ return throwException("Not acceptable", status, _responseText, _headers, result406);
13934
13985
  }
13935
13986
  else if (status === 409) {
13936
13987
  const _responseText = xhr.responseText;
13937
13988
  let result409 = null;
13938
13989
  result409 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
13939
- return throwException("Could Not persist the update", status, _responseText, _headers, result409);
13990
+ return throwException("Could Not persist the delete", status, _responseText, _headers, result409);
13940
13991
  }
13941
13992
  else if (status === 500) {
13942
13993
  const _responseText = xhr.responseText;
@@ -13951,37 +14002,41 @@ class DocumentToolsClient extends APIClientBase_1.APIClientBase {
13951
14002
  return null;
13952
14003
  }
13953
14004
  /**
13954
- * Returns the header Of the specified document, including a Document Session Key
14005
+ * Updates the header On the specified document
13955
14006
  * @param id Document Key
14007
+ * @param updatedData Replacement data
13956
14008
  */
13957
- getDocHeader(id) {
14009
+ updateDocHeader(id, updatedData) {
13958
14010
  return new Promise((resolve, reject) => {
13959
- this.getDocHeaderWithCallbacks(id, (result) => resolve(result), (exception, _reason) => reject(exception));
14011
+ this.updateDocHeaderWithCallbacks(id, updatedData, (result) => resolve(result), (exception, _reason) => reject(exception));
13960
14012
  });
13961
14013
  }
13962
- getDocHeaderWithCallbacks(id, onSuccess, onFail) {
14014
+ updateDocHeaderWithCallbacks(id, updatedData, onSuccess, onFail) {
13963
14015
  let url_ = this.baseUrl + "/api/document/{id}";
13964
14016
  if (id === undefined || id === null)
13965
14017
  throw new globalThis.Error("The parameter 'id' must be defined.");
13966
14018
  url_ = url_.replace("{id}", encodeURIComponent("" + id));
13967
14019
  url_ = url_.replace(/[?&]$/, "");
14020
+ const content_ = JSON.stringify(updatedData);
13968
14021
  jQuery.ajax({
13969
14022
  url: url_,
13970
14023
  beforeSend: this.beforeSend,
13971
- type: "get",
14024
+ type: "put",
14025
+ data: content_,
13972
14026
  dataType: "text",
13973
14027
  headers: {
13974
- "Accept": "application/json"
14028
+ "Content-Type": "application/json",
14029
+ "Accept": "application/octet-stream"
13975
14030
  }
13976
14031
  }).done((_data, _textStatus, xhr) => {
13977
- this.processGetDocHeaderWithCallbacks(url_, xhr, onSuccess, onFail);
14032
+ this.processUpdateDocHeaderWithCallbacks(url_, xhr, onSuccess, onFail);
13978
14033
  }).fail((xhr) => {
13979
- this.processGetDocHeaderWithCallbacks(url_, xhr, onSuccess, onFail);
14034
+ this.processUpdateDocHeaderWithCallbacks(url_, xhr, onSuccess, onFail);
13980
14035
  });
13981
14036
  }
13982
- processGetDocHeaderWithCallbacks(_url, xhr, onSuccess, onFail) {
14037
+ processUpdateDocHeaderWithCallbacks(_url, xhr, onSuccess, onFail) {
13983
14038
  try {
13984
- let result = this.transformResult(_url, xhr, (xhr) => this.processGetDocHeader(xhr));
14039
+ let result = this.transformResult(_url, xhr, (xhr) => this.processUpdateDocHeader(xhr));
13985
14040
  if (onSuccess !== undefined)
13986
14041
  onSuccess(result);
13987
14042
  }
@@ -13990,10 +14045,10 @@ class DocumentToolsClient extends APIClientBase_1.APIClientBase {
13990
14045
  onFail(e, "http_service_exception");
13991
14046
  }
13992
14047
  }
13993
- processGetDocHeader(xhr) {
14048
+ processUpdateDocHeader(xhr) {
13994
14049
  const status = xhr.status;
13995
14050
  let _headers = {};
13996
- if (status === 200) {
14051
+ if (status === 200 || status === 206) {
13997
14052
  const _responseText = xhr.responseText;
13998
14053
  let result200 = null;
13999
14054
  result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
@@ -14011,6 +14066,18 @@ class DocumentToolsClient extends APIClientBase_1.APIClientBase {
14011
14066
  result404 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
14012
14067
  return throwException("Document Not found, Or Not accessible", status, _responseText, _headers, result404);
14013
14068
  }
14069
+ else if (status === 406) {
14070
+ const _responseText = xhr.responseText;
14071
+ let result406 = null;
14072
+ result406 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
14073
+ return throwException("Document number cannot be changed by this method", status, _responseText, _headers, result406);
14074
+ }
14075
+ else if (status === 409) {
14076
+ const _responseText = xhr.responseText;
14077
+ let result409 = null;
14078
+ result409 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
14079
+ return throwException("Could Not persist the update", status, _responseText, _headers, result409);
14080
+ }
14014
14081
  else if (status === 500) {
14015
14082
  const _responseText = xhr.responseText;
14016
14083
  let result500 = null;
@@ -16900,61 +16967,6 @@ class DocumentToolsClient extends APIClientBase_1.APIClientBase {
16900
16967
  }
16901
16968
  return null;
16902
16969
  }
16903
- /**
16904
- * Returns the compliance for the specified document
16905
- * @param id Document Key
16906
- */
16907
- getDocCompliance(id) {
16908
- return new Promise((resolve, reject) => {
16909
- this.getDocComplianceWithCallbacks(id, (result) => resolve(result), (exception, _reason) => reject(exception));
16910
- });
16911
- }
16912
- getDocComplianceWithCallbacks(id, onSuccess, onFail) {
16913
- let url_ = this.baseUrl + "/api/document/{id}/compliance";
16914
- if (id === undefined || id === null)
16915
- throw new globalThis.Error("The parameter 'id' must be defined.");
16916
- url_ = url_.replace("{id}", encodeURIComponent("" + id));
16917
- url_ = url_.replace(/[?&]$/, "");
16918
- jQuery.ajax({
16919
- url: url_,
16920
- beforeSend: this.beforeSend,
16921
- type: "get",
16922
- dataType: "text",
16923
- headers: {
16924
- "Accept": "application/json"
16925
- }
16926
- }).done((_data, _textStatus, xhr) => {
16927
- this.processGetDocComplianceWithCallbacks(url_, xhr, onSuccess, onFail);
16928
- }).fail((xhr) => {
16929
- this.processGetDocComplianceWithCallbacks(url_, xhr, onSuccess, onFail);
16930
- });
16931
- }
16932
- processGetDocComplianceWithCallbacks(_url, xhr, onSuccess, onFail) {
16933
- try {
16934
- let result = this.transformResult(_url, xhr, (xhr) => this.processGetDocCompliance(xhr));
16935
- if (onSuccess !== undefined)
16936
- onSuccess(result);
16937
- }
16938
- catch (e) {
16939
- if (onFail !== undefined)
16940
- onFail(e, "http_service_exception");
16941
- }
16942
- }
16943
- processGetDocCompliance(xhr) {
16944
- const status = xhr.status;
16945
- let _headers = {};
16946
- if (status === 200) {
16947
- const _responseText = xhr.responseText;
16948
- let result200 = null;
16949
- result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
16950
- return result200;
16951
- }
16952
- else if (status !== 200 && status !== 204) {
16953
- const _responseText = xhr.responseText;
16954
- return throwException("An unexpected server error occurred.", status, _responseText, _headers);
16955
- }
16956
- return null;
16957
- }
16958
16970
  /**
16959
16971
  * Deletes the compliance on the specified document
16960
16972
  * @param id Document Key
@@ -17218,6 +17230,61 @@ class DocumentToolsClient extends APIClientBase_1.APIClientBase {
17218
17230
  }
17219
17231
  return null;
17220
17232
  }
17233
+ /**
17234
+ * Returns the compliance for the specified document
17235
+ * @param id Document Key
17236
+ */
17237
+ getDocCompliance(id) {
17238
+ return new Promise((resolve, reject) => {
17239
+ this.getDocComplianceWithCallbacks(id, (result) => resolve(result), (exception, _reason) => reject(exception));
17240
+ });
17241
+ }
17242
+ getDocComplianceWithCallbacks(id, onSuccess, onFail) {
17243
+ let url_ = this.baseUrl + "/api/document/{id}/compliance";
17244
+ if (id === undefined || id === null)
17245
+ throw new globalThis.Error("The parameter 'id' must be defined.");
17246
+ url_ = url_.replace("{id}", encodeURIComponent("" + id));
17247
+ url_ = url_.replace(/[?&]$/, "");
17248
+ jQuery.ajax({
17249
+ url: url_,
17250
+ beforeSend: this.beforeSend,
17251
+ type: "get",
17252
+ dataType: "text",
17253
+ headers: {
17254
+ "Accept": "application/json"
17255
+ }
17256
+ }).done((_data, _textStatus, xhr) => {
17257
+ this.processGetDocComplianceWithCallbacks(url_, xhr, onSuccess, onFail);
17258
+ }).fail((xhr) => {
17259
+ this.processGetDocComplianceWithCallbacks(url_, xhr, onSuccess, onFail);
17260
+ });
17261
+ }
17262
+ processGetDocComplianceWithCallbacks(_url, xhr, onSuccess, onFail) {
17263
+ try {
17264
+ let result = this.transformResult(_url, xhr, (xhr) => this.processGetDocCompliance(xhr));
17265
+ if (onSuccess !== undefined)
17266
+ onSuccess(result);
17267
+ }
17268
+ catch (e) {
17269
+ if (onFail !== undefined)
17270
+ onFail(e, "http_service_exception");
17271
+ }
17272
+ }
17273
+ processGetDocCompliance(xhr) {
17274
+ const status = xhr.status;
17275
+ let _headers = {};
17276
+ if (status === 200) {
17277
+ const _responseText = xhr.responseText;
17278
+ let result200 = null;
17279
+ result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
17280
+ return result200;
17281
+ }
17282
+ else if (status !== 200 && status !== 204) {
17283
+ const _responseText = xhr.responseText;
17284
+ return throwException("An unexpected server error occurred.", status, _responseText, _headers);
17285
+ }
17286
+ return null;
17287
+ }
17221
17288
  /**
17222
17289
  * Returns the Project Details based on the specified document. Update using PatchDocData
17223
17290
  * @param id Document Key