@aurigma/ng-design-atoms-api-client 2.46.1 → 2.48.1
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/aurigma-ng-design-atoms-api-client.metadata.json +1 -1
- package/bundles/aurigma-ng-design-atoms-api-client.umd.js +232 -122
- package/bundles/aurigma-ng-design-atoms-api-client.umd.js.map +1 -1
- package/bundles/aurigma-ng-design-atoms-api-client.umd.min.js +1 -1
- package/bundles/aurigma-ng-design-atoms-api-client.umd.min.js.map +1 -1
- package/esm2015/lib/design-atoms-api-client.js +102 -3
- package/fesm2015/aurigma-ng-design-atoms-api-client.js +102 -3
- package/fesm2015/aurigma-ng-design-atoms-api-client.js.map +1 -1
- package/lib/design-atoms-api-client.d.ts +58 -9
- package/package.json +1 -1
|
@@ -53,7 +53,7 @@ class BuildInfoApiClient extends ApiClientBase {
|
|
|
53
53
|
this.baseUrl = baseUrl !== undefined && baseUrl !== null ? baseUrl : this.getBaseUrl("");
|
|
54
54
|
}
|
|
55
55
|
/**
|
|
56
|
-
*
|
|
56
|
+
* Get assembly build info.
|
|
57
57
|
* @return Success
|
|
58
58
|
*/
|
|
59
59
|
headInfo() {
|
|
@@ -111,7 +111,7 @@ class BuildInfoApiClient extends ApiClientBase {
|
|
|
111
111
|
return of(null);
|
|
112
112
|
}
|
|
113
113
|
/**
|
|
114
|
-
*
|
|
114
|
+
* Get assembly build info.
|
|
115
115
|
* @return Success
|
|
116
116
|
*/
|
|
117
117
|
getInfo() {
|
|
@@ -3118,6 +3118,97 @@ class DesignAtomsServiceApiClient extends ApiClientBase {
|
|
|
3118
3118
|
}
|
|
3119
3119
|
return of(null);
|
|
3120
3120
|
}
|
|
3121
|
+
/**
|
|
3122
|
+
* Returns design parameters stored in product model.
|
|
3123
|
+
* @param id Design identifier.
|
|
3124
|
+
* @param privateStorageOwner (optional) Private storage owner identifier.
|
|
3125
|
+
* @param tenantId (optional) Tenant identifier
|
|
3126
|
+
* @return Success
|
|
3127
|
+
*/
|
|
3128
|
+
getDesignParameters(id, privateStorageOwner, tenantId) {
|
|
3129
|
+
let url_ = this.baseUrl + "/api/atoms/v1/designs/{id}/parameters?";
|
|
3130
|
+
if (id === undefined || id === null)
|
|
3131
|
+
throw new Error("The parameter 'id' must be defined.");
|
|
3132
|
+
url_ = url_.replace("{id}", encodeURIComponent("" + id));
|
|
3133
|
+
if (privateStorageOwner !== undefined && privateStorageOwner !== null)
|
|
3134
|
+
url_ += "privateStorageOwner=" + encodeURIComponent("" + privateStorageOwner) + "&";
|
|
3135
|
+
if (tenantId === null)
|
|
3136
|
+
throw new Error("The parameter 'tenantId' cannot be null.");
|
|
3137
|
+
else if (tenantId !== undefined)
|
|
3138
|
+
url_ += "tenantId=" + encodeURIComponent("" + tenantId) + "&";
|
|
3139
|
+
url_ = url_.replace(/[?&]$/, "");
|
|
3140
|
+
let options_ = {
|
|
3141
|
+
observe: "response",
|
|
3142
|
+
responseType: "blob",
|
|
3143
|
+
headers: new HttpHeaders({
|
|
3144
|
+
"Accept": "application/json"
|
|
3145
|
+
})
|
|
3146
|
+
};
|
|
3147
|
+
return from(this.transformOptions(options_)).pipe(mergeMap(transformedOptions_ => {
|
|
3148
|
+
return this.http.request("get", url_, transformedOptions_);
|
|
3149
|
+
})).pipe(mergeMap((response_) => {
|
|
3150
|
+
return this.transformResult(url_, response_, (r) => this.processGetDesignParameters(r));
|
|
3151
|
+
})).pipe(catchError((response_) => {
|
|
3152
|
+
if (response_ instanceof HttpResponseBase) {
|
|
3153
|
+
try {
|
|
3154
|
+
return this.transformResult(url_, response_, (r) => this.processGetDesignParameters(r));
|
|
3155
|
+
}
|
|
3156
|
+
catch (e) {
|
|
3157
|
+
return throwError(e);
|
|
3158
|
+
}
|
|
3159
|
+
}
|
|
3160
|
+
else
|
|
3161
|
+
return throwError(response_);
|
|
3162
|
+
}));
|
|
3163
|
+
}
|
|
3164
|
+
processGetDesignParameters(response) {
|
|
3165
|
+
const status = response.status;
|
|
3166
|
+
const responseBlob = response instanceof HttpResponse ? response.body :
|
|
3167
|
+
response.error instanceof Blob ? response.error : undefined;
|
|
3168
|
+
let _headers = {};
|
|
3169
|
+
if (response.headers) {
|
|
3170
|
+
for (let key of response.headers.keys()) {
|
|
3171
|
+
_headers[key] = response.headers.get(key);
|
|
3172
|
+
}
|
|
3173
|
+
}
|
|
3174
|
+
if (status === 200) {
|
|
3175
|
+
return blobToText(responseBlob).pipe(mergeMap(_responseText => {
|
|
3176
|
+
let result200 = null;
|
|
3177
|
+
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
|
|
3178
|
+
return of(result200);
|
|
3179
|
+
}));
|
|
3180
|
+
}
|
|
3181
|
+
else if (status === 404) {
|
|
3182
|
+
return blobToText(responseBlob).pipe(mergeMap(_responseText => {
|
|
3183
|
+
let result404 = null;
|
|
3184
|
+
result404 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
|
|
3185
|
+
return throwException("Not Found", status, _responseText, _headers, result404);
|
|
3186
|
+
}));
|
|
3187
|
+
}
|
|
3188
|
+
else if (status === 401) {
|
|
3189
|
+
return blobToText(responseBlob).pipe(mergeMap(_responseText => {
|
|
3190
|
+
return throwException("Unauthorized", status, _responseText, _headers);
|
|
3191
|
+
}));
|
|
3192
|
+
}
|
|
3193
|
+
else if (status === 403) {
|
|
3194
|
+
return blobToText(responseBlob).pipe(mergeMap(_responseText => {
|
|
3195
|
+
return throwException("Forbidden", status, _responseText, _headers);
|
|
3196
|
+
}));
|
|
3197
|
+
}
|
|
3198
|
+
else if (status === 500) {
|
|
3199
|
+
return blobToText(responseBlob).pipe(mergeMap(_responseText => {
|
|
3200
|
+
let result500 = null;
|
|
3201
|
+
result500 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
|
|
3202
|
+
return throwException("Internal server error", status, _responseText, _headers, result500);
|
|
3203
|
+
}));
|
|
3204
|
+
}
|
|
3205
|
+
else if (status !== 200 && status !== 204) {
|
|
3206
|
+
return blobToText(responseBlob).pipe(mergeMap(_responseText => {
|
|
3207
|
+
return throwException("An unexpected server error occurred.", status, _responseText, _headers);
|
|
3208
|
+
}));
|
|
3209
|
+
}
|
|
3210
|
+
return of(null);
|
|
3211
|
+
}
|
|
3121
3212
|
/**
|
|
3122
3213
|
* Loads data schema from design file taken from storage
|
|
3123
3214
|
* @param id Design identifier
|
|
@@ -6411,6 +6502,14 @@ var ImagePreviewFormat;
|
|
|
6411
6502
|
ImagePreviewFormat["Jpeg"] = "Jpeg";
|
|
6412
6503
|
ImagePreviewFormat["Png"] = "Png";
|
|
6413
6504
|
})(ImagePreviewFormat || (ImagePreviewFormat = {}));
|
|
6505
|
+
/** Image preview fit mode. */
|
|
6506
|
+
var ImagePreviewFitMode;
|
|
6507
|
+
(function (ImagePreviewFitMode) {
|
|
6508
|
+
ImagePreviewFitMode["Fit"] = "Fit";
|
|
6509
|
+
ImagePreviewFitMode["Shrink"] = "Shrink";
|
|
6510
|
+
ImagePreviewFitMode["Resize"] = "Resize";
|
|
6511
|
+
ImagePreviewFitMode["Fill"] = "Fill";
|
|
6512
|
+
})(ImagePreviewFitMode || (ImagePreviewFitMode = {}));
|
|
6414
6513
|
var DesignElementType;
|
|
6415
6514
|
(function (DesignElementType) {
|
|
6416
6515
|
DesignElementType["Product"] = "Product";
|
|
@@ -6551,5 +6650,5 @@ DesignAtomsApiModule.decorators = [
|
|
|
6551
6650
|
* Generated bundle index. Do not edit.
|
|
6552
6651
|
*/
|
|
6553
6652
|
|
|
6554
|
-
export { API_BASE_URL, ApiClientBase, ApiClientConfiguration, ApiException, BuildInfoApiClient, ColorSpace, CreateApiClientConfiguration, DesignAtomsApiModule, DesignAtomsCompatibilityApiClient, DesignAtomsImagesApiClient, DesignAtomsMockups3dApiClient, DesignAtomsServiceApiClient, DesignAtomsViewerApiClient, DesignElementType, ImagePreviewFormat, ItemSourceType, ItemType, PlaceholderItemContentType, ProductPatchType, ProductPreviewFormat, ProductProofFormat, ProductProofInterpolationMode };
|
|
6653
|
+
export { API_BASE_URL, ApiClientBase, ApiClientConfiguration, ApiException, BuildInfoApiClient, ColorSpace, CreateApiClientConfiguration, DesignAtomsApiModule, DesignAtomsCompatibilityApiClient, DesignAtomsImagesApiClient, DesignAtomsMockups3dApiClient, DesignAtomsServiceApiClient, DesignAtomsViewerApiClient, DesignElementType, ImagePreviewFitMode, ImagePreviewFormat, ItemSourceType, ItemType, PlaceholderItemContentType, ProductPatchType, ProductPreviewFormat, ProductProofFormat, ProductProofInterpolationMode };
|
|
6555
6654
|
//# sourceMappingURL=aurigma-ng-design-atoms-api-client.js.map
|