Skip to content

Commit

Permalink
Computer resource without vendor or provider 177 (#179)
Browse files Browse the repository at this point in the history
* Update compute-resource-properties.component.html

* Update compute-resource-provenance.component.ts

Co-authored-by: salmma <marie.salm@iaas.uni-stuttgart.de>
  • Loading branch information
emymaria and salmma authored Dec 14, 2021
1 parent d61279d commit 9a0bfd1
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<mat-card class="m-2">
<app-text-input
name="Vendor"
[value]="computeResource.vendor"
[value]="computeResource.vendor ? computeResource.vendor : ''"
(onChange)="onPropertyChanged($event, 'vendor')"
(onSaveChanges)="onChangesSaved($event, 'vendor')">
</app-text-input>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -106,8 +106,10 @@ export class ComputeResourceProvenanceComponent implements OnInit {
// search for provider specified in computeResource
for (const providerDto of result._embedded.providerDtoes) {
if (
providerDto.name &&
this.computeResource.vendor &&
providerDto.name.toLowerCase() ===
this.computeResource.vendor.toLowerCase()
this.computeResource.vendor.toLowerCase()
) {
this.provider = providerDto;
return;
Expand Down Expand Up @@ -164,6 +166,7 @@ export class ComputeResourceProvenanceComponent implements OnInit {
})
.subscribe((qubitCharacteristicsResult) => {
if (
qubitCharacteristicsResult._embedded &&
qubitCharacteristicsResult._embedded.qubitCharacteristicsDtoes
.length > 0
) {
Expand Down

0 comments on commit 9a0bfd1

Please sign in to comment.