public OpenmediavaultAddFileSystemViewModel(IOmvService sshService,
                                             IOMVSshBackgroundService backgroundService)
 {
     _omvService        = sshService;
     _backgroundService = backgroundService;
     SaveCmd            = new Command(async() => await Save());
 }
Beispiel #2
0
 public OpenmediavaultSystemLogsViewModel(IOmvService sshService)
 {
     _sshService         = sshService;
     DeleteItemCommand   = new Command(DeleteItem);
     DownloadItemCommand = new Command(DownloadItem);
     SyncItemCommand     = new Command(SyncItem);
 }
Beispiel #3
0
        public OpenmediavaultFileSystemsViewModel(IOmvService sshService, IMessageBoxService messageBoxService)
        {
            _omvService        = sshService;
            _messageBoxService = messageBoxService;
            AddItemCommand     = new Command(AddItem);
            MountFileSystemCmd = new Command(MountFileSystem, o =>
            {
                if (o is OmvFilesystems filesystem)
                {
                    return(filesystem.CanMount);
                }

                return(false);
            });
            UmountFileSystemCmd = new Command(UmountFileSystem, o =>
            {
                if (o is OmvFilesystems filesystem)
                {
                    return(filesystem.CanUmount);
                }

                return(false);
            });
            DeleteFileSystemCmd = new Command(DeleteFileSystem, o =>
            {
                if (o is OmvFilesystems filesystem)
                {
                    return(filesystem.CanDelete);
                }

                return(false);
            });
        }
Beispiel #4
0
 public OpenmediavaultDashboardViewModel(IOmvService omvService, IConfiguration configuration, IMessagingCenter messagingCenter)
 {
     _OmvService      = omvService;
     UpdatesCmd       = new Command(async(obj) => await Updates(obj));
     CheckCmd         = new Command(async(obj) => await Check(obj));
     ManageHostsCmd   = new Command(ManageHosts);
     ChangeHostCmd    = new Command(async(obj) => await ChangeHost());
     ShowDetailsCmd   = new Command(ShowDetails);
     BannerId         = configuration.AdsKey;
     _messagingCenter = messagingCenter;
 }
 public OpenmediavaultUpdatesViewModel(IOmvService sshService, IMessageBoxService messageBoxService, IMessagingCenter messagingCenter)
 {
     _sshService        = sshService;
     _messageBoxService = messageBoxService;
     _messagingCenter   = messagingCenter;
 }
 public OpenmediavaultSettingsViewModel(IOmvService sshService)
 {
     _sshService = sshService;
 }
 public OpenmediavaultPluginsViewModel(IOmvService sshService)
 {
     _sshService          = sshService;
     OmvPluginsChangedCmd = new Command(OmvPluginsChanged);
     InstallRemoveCmd     = new Command(InstallRemove, CanExecute);
 }
Beispiel #8
0
 public OpenmediavaultStatisticsViewModel(IOmvService sshService)
 {
     _sshService = sshService;
 }