Skip to content

Commit a6f1a6d

Browse files
authored
Merge pull request #584 from atmire/SubmissionUseFullProjection
Use full projection for submission REST requests
2 parents e60688b + 775dfb5 commit a6f1a6d

2 files changed

Lines changed: 3 additions & 2 deletions

File tree

src/app/core/submission/submission-rest.service.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ describe('SubmissionRestService test suite', () => {
2626
const resourceEndpoint = 'workspaceitems';
2727
const resourceScope = '260';
2828
const body = { test: new FormFieldMetadataValueObject('test')};
29-
const resourceHref = resourceEndpointURL + '/' + resourceEndpoint + '/' + resourceScope;
29+
const resourceHref = resourceEndpointURL + '/' + resourceEndpoint + '/' + resourceScope + '?projection=full';
3030
const timestampResponse = 1545994811992;
3131

3232
function initTestService() {

src/app/core/submission/submission-rest.service.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,8 +71,9 @@ export class SubmissionRestService {
7171
*/
7272
protected getEndpointByIDHref(endpoint, resourceID, collectionId?: string): string {
7373
let url = isNotEmpty(resourceID) ? `${endpoint}/${resourceID}` : `${endpoint}`;
74+
url = new URLCombiner(url, '?projection=full').toString();
7475
if (collectionId) {
75-
url = new URLCombiner(url, `?owningCollection=${collectionId}`).toString();
76+
url = new URLCombiner(url, `&owningCollection=${collectionId}`).toString();
7677
}
7778
return url;
7879
}

0 commit comments

Comments
 (0)