diff --git a/src/app/features/preprints/components/stepper/review-step/review-step.component.ts b/src/app/features/preprints/components/stepper/review-step/review-step.component.ts index 4c772e1d1..fd85917a8 100644 --- a/src/app/features/preprints/components/stepper/review-step/review-step.component.ts +++ b/src/app/features/preprints/components/stepper/review-step/review-step.component.ts @@ -98,7 +98,7 @@ export class ReviewStepComponent implements OnInit { const preprintFile = this.preprintFile()!; this.actions - .updatePrimaryFileRelationship(preprintFile.id) + .updatePrimaryFileRelationship(preprintFile.id ?? preprint.primaryFileId) .pipe( switchMap(() => { if (preprint.reviewsState !== ReviewsState.Accepted) { diff --git a/src/app/features/preprints/services/preprints-projects.service.ts b/src/app/features/preprints/services/preprints-projects.service.ts index f1855f187..da369b71e 100644 --- a/src/app/features/preprints/services/preprints-projects.service.ts +++ b/src/app/features/preprints/services/preprints-projects.service.ts @@ -100,6 +100,7 @@ export class PreprintsProjectsService { ...(description && { description }), category: 'project', ...(templateFrom && { template_from: templateFrom }), + public: true, }, relationships: { region: { diff --git a/src/app/shared/models/nodes/nodes-json-api.model.ts b/src/app/shared/models/nodes/nodes-json-api.model.ts index 8e75ce771..82b4ae0a6 100644 --- a/src/app/shared/models/nodes/nodes-json-api.model.ts +++ b/src/app/shared/models/nodes/nodes-json-api.model.ts @@ -17,6 +17,7 @@ export interface CreateProjectPayloadJsoApi { description?: string; category: 'project'; template_from?: string; + public: boolean; }; relationships: { region: { diff --git a/src/app/shared/services/my-resources.service.ts b/src/app/shared/services/my-resources.service.ts index aa654d9c5..d1d752d27 100644 --- a/src/app/shared/services/my-resources.service.ts +++ b/src/app/shared/services/my-resources.service.ts @@ -181,6 +181,7 @@ export class MyResourcesService { ...(description && { description }), category: 'project', ...(templateFrom && { template_from: templateFrom }), + public: false, }, relationships: { region: {