Skip to content

Commit

Permalink
NAS-133748: Datasets show in VM edit (#11381)
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexKarpov98 authored Jan 24, 2025
1 parent 781527b commit f3b22ed
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
root="/"
[label]="'Source' | translate"
[required]="true"
[nodeProvider]="directoryNodeProvider"
[nodeProvider]="directoryNodeProvider()"
[canCreateDataset]="isNew()"
></ix-explorer>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,14 @@ export class InstanceDiskFormComponent implements OnInit {
private existingDisk = signal<VirtualizationDisk | null>(null);

protected readonly isLoading = signal(false);
protected readonly directoryNodeProvider = this.filesystem.getFilesystemNodeProvider({ datasetsAndZvols: true });

readonly directoryNodeProvider = computed(() => {
if (this.instance.type === VirtualizationType.Vm) {
return this.filesystem.getFilesystemNodeProvider({ zvolsOnly: true });
}

return this.filesystem.getFilesystemNodeProvider({ datasetsAndZvols: true });
});

protected form = this.formBuilder.nonNullable.group({
source: ['', Validators.required],
Expand Down

0 comments on commit f3b22ed

Please sign in to comment.