diff --git a/src/app/components/resources/detail/resource-detail.component.html b/src/app/components/resources/detail/resource-detail.component.html index ef28fb56a7711bb21f218d2385816738255c32df..60a5b0114ad29ff66798be9b4543a00585edf42a 100644 --- a/src/app/components/resources/detail/resource-detail.component.html +++ b/src/app/components/resources/detail/resource-detail.component.html @@ -40,7 +40,6 @@ <span class="empty-property">Non renseigné</span> </ng-template> </div> - <br> <p> <span class="has-text-weight-bold">Requêtable: </span> @@ -76,7 +75,6 @@ <span class="empty-property">Non renseigné</span> </ng-template> </div> - <br> <div *ngIf="resource.messageWarning"> <span class="has-text-weight-bold">Message d'alerte: </span> diff --git a/src/app/components/resources/edit/resource-form.component.ts b/src/app/components/resources/edit/resource-form.component.ts index e4756d8f7e5aa3cf6eea82fce3203cf6d037f8c9..b40283eb2dbed3b4d2148c60ebd4bb3e6e048052 100644 --- a/src/app/components/resources/edit/resource-form.component.ts +++ b/src/app/components/resources/edit/resource-form.component.ts @@ -42,9 +42,7 @@ export class ResourceFormComponent implements OnInit { switchMap((paramMap: ParamMap) => this._resourceService.findById(paramMap.get('id')))) .subscribe((resource: Resource) => { this.resource = resource; - this.initForm(); - }); } diff --git a/src/app/models/resource.model.ts b/src/app/models/resource.model.ts index fe8df0a3601619cca902abe6bc1a3a2f3f975eb9..2d28cdda3fc135178cc0515efd361079a1f286ed 100644 --- a/src/app/models/resource.model.ts +++ b/src/app/models/resource.model.ts @@ -28,7 +28,7 @@ export class Resource { this.isStandard = resource.isStandard; this.parametersUrl = resource.parametersUrl; this.messageWarning = resource.messageWarning; - this.resourceFormats = resource.resourceFormats; + this.resourceFormats = resource.resourceFormats ? resource.resourceFormats : []; } else { this.name = ''; this.acronym = '';