@eo-sdk/client 8.16.10 → 8.16.11
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/bundles/eo-sdk-client-projects-eo-sdk-core.umd.js +19 -16
- package/bundles/eo-sdk-client-projects-eo-sdk-core.umd.js.map +1 -1
- package/bundles/eo-sdk-client-projects-eo-sdk-core.umd.min.js +2 -2
- package/bundles/eo-sdk-client-projects-eo-sdk-core.umd.min.js.map +1 -1
- package/bundles/eo-sdk-client.umd.js +5 -5
- package/bundles/eo-sdk-client.umd.js.map +1 -1
- package/bundles/eo-sdk-client.umd.min.js +1 -1
- package/bundles/eo-sdk-client.umd.min.js.map +1 -1
- package/esm2015/app/eo-client/about-state/about-state.component.js +3 -3
- package/esm2015/app/eo-framework/object-details/object-links/object-links.component.js +2 -2
- package/esm2015/app/eo-framework-core/api/grid.service.js +3 -3
- package/esm2015/projects/eo-sdk/core/lib/service/backend/backend.service.js +4 -3
- package/esm2015/projects/eo-sdk/core/lib/service/dms/dms.service.js +4 -4
- package/esm2015/projects/eo-sdk/core/lib/service/prepare/prepare.service.js +7 -7
- package/esm2015/projects/eo-sdk/core/lib/service/upload/upload.service.js +7 -4
- package/esm2015/projects/eo-sdk/core/lib/service/user/user.service.js +3 -3
- package/fesm2015/eo-sdk-client-projects-eo-sdk-core.js +19 -16
- package/fesm2015/eo-sdk-client-projects-eo-sdk-core.js.map +1 -1
- package/fesm2015/eo-sdk-client.js +5 -5
- package/fesm2015/eo-sdk-client.js.map +1 -1
- package/package.json +2 -2
- package/projects/eo-sdk/core/eo-sdk-client-projects-eo-sdk-core.metadata.json +1 -1
- package/projects/eo-sdk/core/lib/service/backend/backend.service.d.ts +2 -1
- package/projects/eo-sdk/core/lib/service/upload/upload.service.d.ts +3 -1
- package/projects/eo-sdk/core/package.json +1 -1
|
@@ -1702,10 +1702,11 @@
|
|
|
1702
1702
|
};
|
|
1703
1703
|
/**
|
|
1704
1704
|
* @ignore
|
|
1705
|
+
* This get base function includes the contextPath, but the others dont
|
|
1705
1706
|
*/
|
|
1706
1707
|
BackendService.prototype.getIconBase = function (id) {
|
|
1707
1708
|
if (id === void 0) { id = ''; }
|
|
1708
|
-
return this.
|
|
1709
|
+
return this.getContextPath() + '/ui/icon/' + id;
|
|
1709
1710
|
};
|
|
1710
1711
|
/**
|
|
1711
1712
|
* @ignore
|
|
@@ -1854,7 +1855,7 @@
|
|
|
1854
1855
|
var _this = this;
|
|
1855
1856
|
dmsObjects.forEach(function (dmsObject) {
|
|
1856
1857
|
if (dmsObject.content) {
|
|
1857
|
-
var uri = _this.
|
|
1858
|
+
var uri = _this.getContextPath() + "/dms/" + dmsObject.content.id + "/content?type=" + dmsObject.content.type + "&asdownload=true";
|
|
1858
1859
|
if (rendition) {
|
|
1859
1860
|
uri += "&rendition=" + rendition + "&_intent=DOWNLOAD_" + rendition;
|
|
1860
1861
|
}
|
|
@@ -2424,7 +2425,7 @@
|
|
|
2424
2425
|
UserService.prototype.setCurrentUser = function (res) {
|
|
2425
2426
|
this.user = new EoUser(res);
|
|
2426
2427
|
this.passwordValidationSettings = res.passwortvalidation;
|
|
2427
|
-
this.user.setImageBase(this.backend.
|
|
2428
|
+
this.user.setImageBase(this.backend.getContextPath());
|
|
2428
2429
|
this.backend.setHeader('Accept-Language', this.user.getSchemaLocale());
|
|
2429
2430
|
var languages = this.config.getClientLocales().map(function (lang) { return lang.iso; });
|
|
2430
2431
|
var userLang = this.user.getClientLocale();
|
|
@@ -2537,7 +2538,7 @@
|
|
|
2537
2538
|
* @returns URI to the user image
|
|
2538
2539
|
*/
|
|
2539
2540
|
UserService.prototype.getUserImageUri = function (userId) {
|
|
2540
|
-
return this.backend.
|
|
2541
|
+
return this.backend.getContextPath() + "/organization/image/" + userId;
|
|
2541
2542
|
};
|
|
2542
2543
|
/**
|
|
2543
2544
|
* Removes a favorite item
|
|
@@ -2670,10 +2671,11 @@
|
|
|
2670
2671
|
/**
|
|
2671
2672
|
* @ignore
|
|
2672
2673
|
*/
|
|
2673
|
-
function UploadService(coreConfig, http, userService) {
|
|
2674
|
+
function UploadService(coreConfig, http, userService, backend) {
|
|
2674
2675
|
this.coreConfig = coreConfig;
|
|
2675
2676
|
this.http = http;
|
|
2676
2677
|
this.userService = userService;
|
|
2678
|
+
this.backend = backend;
|
|
2677
2679
|
}
|
|
2678
2680
|
/**
|
|
2679
2681
|
* Uploads files.
|
|
@@ -2686,7 +2688,7 @@
|
|
|
2686
2688
|
var formData = new FormData();
|
|
2687
2689
|
var headers = new http.HttpHeaders({ 'Accept-Language': this.userService.getCurrentUser().getClientLocale() });
|
|
2688
2690
|
files.forEach(function (file) { return formData.append('files[]', file, Utils.encodeFileName(file.name)); });
|
|
2689
|
-
return this.http.post(uri, formData, { headers: headers, withCredentials: this.coreConfig.withCredentials });
|
|
2691
|
+
return this.http.post("" + this.backend.getContextPath() + uri, formData, { headers: headers, withCredentials: this.coreConfig.withCredentials });
|
|
2690
2692
|
};
|
|
2691
2693
|
return UploadService;
|
|
2692
2694
|
}());
|
|
@@ -2696,7 +2698,8 @@
|
|
|
2696
2698
|
UploadService.ctorParameters = function () { return [
|
|
2697
2699
|
{ type: CoreConfig, decorators: [{ type: i0.Inject, args: [CORE_CONFIG,] }] },
|
|
2698
2700
|
{ type: http.HttpClient },
|
|
2699
|
-
{ type: UserService }
|
|
2701
|
+
{ type: UserService },
|
|
2702
|
+
{ type: BackendService }
|
|
2700
2703
|
]; };
|
|
2701
2704
|
|
|
2702
2705
|
var UploadTarget = /** @class */ (function () {
|
|
@@ -2890,7 +2893,7 @@
|
|
|
2890
2893
|
* @returns string Preview uri
|
|
2891
2894
|
*/
|
|
2892
2895
|
PrepareService.prototype.getPreviewUri = function (id, index, rendition) {
|
|
2893
|
-
return Utils.buildUri(this.backend.
|
|
2896
|
+
return Utils.buildUri(this.backend.getContextPath() + "/prepare/" + id + "/content", { rendition: rendition, index: index });
|
|
2894
2897
|
};
|
|
2895
2898
|
/**
|
|
2896
2899
|
* Updates the prepared items target object type.
|
|
@@ -2934,7 +2937,7 @@
|
|
|
2934
2937
|
* @returns string The template preview url.
|
|
2935
2938
|
*/
|
|
2936
2939
|
PrepareService.prototype.getTemplatePreviewUri = function (id, rendition) {
|
|
2937
|
-
return Utils.buildUri(this.backend.
|
|
2940
|
+
return Utils.buildUri(this.backend.getContextPath() + "/template/" + id + "/content", { rendition: rendition });
|
|
2938
2941
|
};
|
|
2939
2942
|
/**
|
|
2940
2943
|
* Commit a prepared item. This will create an actual dms object.
|
|
@@ -2959,7 +2962,7 @@
|
|
|
2959
2962
|
* @returns Observable<any>
|
|
2960
2963
|
*/
|
|
2961
2964
|
PrepareService.prototype.uploadContent = function (preparedItemId, file) {
|
|
2962
|
-
var uri =
|
|
2965
|
+
var uri = "/prepare/" + preparedItemId + "/content.json?form=true&contentmeta=true";
|
|
2963
2966
|
return this.uploadService
|
|
2964
2967
|
.upload(uri, [file])
|
|
2965
2968
|
.pipe(
|
|
@@ -2996,7 +2999,7 @@
|
|
|
2996
2999
|
*
|
|
2997
3000
|
* @type string
|
|
2998
3001
|
*/
|
|
2999
|
-
uri = this.
|
|
3002
|
+
uri = this.createPreparedItemPostUrl({
|
|
3000
3003
|
parentId: null,
|
|
3001
3004
|
createMany: !useBatchUpload
|
|
3002
3005
|
});
|
|
@@ -3006,7 +3009,7 @@
|
|
|
3006
3009
|
* upload to dms object, means adding or replacing content file
|
|
3007
3010
|
*/
|
|
3008
3011
|
var referenceObject = uploadTarget.referenceObject;
|
|
3009
|
-
uri =
|
|
3012
|
+
uri = "/dms/" + referenceObject.id + "/contents?type=" + referenceObject.type.name;
|
|
3010
3013
|
}
|
|
3011
3014
|
else if (uploadTarget.type === UploadTarget.CONTEXT || uploadTarget.type === UploadTarget.CONTEXT_TREE) {
|
|
3012
3015
|
/**
|
|
@@ -3016,7 +3019,7 @@
|
|
|
3016
3019
|
*
|
|
3017
3020
|
* @type string
|
|
3018
3021
|
*/
|
|
3019
|
-
uri = this.
|
|
3022
|
+
uri = this.createPreparedItemPostUrl({
|
|
3020
3023
|
parentId: uploadTarget.referenceObject.id,
|
|
3021
3024
|
createMany: !useBatchUpload,
|
|
3022
3025
|
childType: uploadTarget.subFolder && uploadTarget.subFolder.data.type ? uploadTarget.subFolder.data.type : null
|
|
@@ -4965,7 +4968,7 @@
|
|
|
4965
4968
|
*/
|
|
4966
4969
|
DmsService.prototype.getAttachmentByIndex = function (id, index, type, version) {
|
|
4967
4970
|
var uri = Utils.buildUri("/dms/" + id + "/attachments/" + index, { type: type, version: version });
|
|
4968
|
-
return this.backend.
|
|
4971
|
+
return this.backend.getContextPath() + uri;
|
|
4969
4972
|
};
|
|
4970
4973
|
/**
|
|
4971
4974
|
* Generates the URI for getting a DmsObjects slide (Preview image).
|
|
@@ -4977,7 +4980,7 @@
|
|
|
4977
4980
|
* @returns string
|
|
4978
4981
|
*/
|
|
4979
4982
|
DmsService.prototype.getSlide = function (id, type, version, size) {
|
|
4980
|
-
return Utils.buildUri(this.backend.
|
|
4983
|
+
return Utils.buildUri(this.backend.getContextPath() + '/dms/' + id + '/slide', {
|
|
4981
4984
|
type: type,
|
|
4982
4985
|
version: version,
|
|
4983
4986
|
height: size
|
|
@@ -4993,7 +4996,7 @@
|
|
|
4993
4996
|
* @returns string
|
|
4994
4997
|
*/
|
|
4995
4998
|
DmsService.prototype.getPreview = function (id, type, version, rendition) {
|
|
4996
|
-
return Utils.buildUri(this.backend.
|
|
4999
|
+
return Utils.buildUri(this.backend.getContextPath() + '/dms/' + id + '/content', {
|
|
4997
5000
|
rendition: rendition,
|
|
4998
5001
|
type: type,
|
|
4999
5002
|
version: version
|