Пример #1
0
        public GestioneQuoteInvestitoriViewModel(IRegistryServices registryServices, IManagerLiquidAssetServices managerLiquidServices)
        {
            _registryServices      = registryServices ?? throw new ArgumentNullException("Services in Manager Portfolio Movement View Model");
            _managerLiquidServices = managerLiquidServices ?? throw new ArgumentNullException("Liquid Asset Services in Manager Portfolio Movement View Model");

            Init();
        }
        public MainWindowViewModel()
        {
            string versione = "";

            try
            {
                versione = ApplicationDeployment.CurrentDeployment.CurrentVersion.ToString();
                Assembly.GetExecutingAssembly().GetName().Version = ApplicationDeployment.CurrentDeployment.CurrentVersion;
            }
            catch
            {
                versione = Assembly.GetExecutingAssembly().GetName().Version.ToString();
            }
            Titolo                 = string.Format("DAF-C Gestione Finanza ({0})", versione);
            _DafConnection         = new DAFconnection();
            _registryServices      = new RegistryService(_DafConnection);
            _managerLiquidServices = new ManagerLiquidAssetServices(_DafConnection);
            _managerReportServices = new ManagerReportServices(_DafConnection);

            OnClickOpenGestioni         = new CommandHandler(OpenGestioni);
            OnClickOpenConti            = new CommandHandler(OpenConti);
            OnClickOpenAziende          = new CommandHandler(OpenAziende);
            OnClickOpenTipologiaTitoli  = new CommandHandler(OpenTipologiaTitoli);
            OnClickOpenValute           = new CommandHandler(OpenValute);
            OnClickOpenSchedaTitoli     = new CommandHandler(OpenSchedaTitoli);
            OnClickOpenMovimenti        = new CommandHandler(OpenMovimenti);
            OnClickOpenQuoteInvestitori = new CommandHandler(OpenQuoteInvestitori);
            OnClickPortafoglioTitoli    = new CommandHandler(PortafoglioTitoli);
            OnClickOpenContoCorrente    = new CommandHandler(OpenContoCorrente);
            OnClickManagerReports       = new CommandHandler(OpenReports);
        }
Пример #3
0
        public SccmRemoteAccessRegModify(ILoggerService logger, INetworkServices networkServices, IFileAndFolderServices fileAndFolderServices, IRegistryServices registryServices) : base(logger, networkServices, fileAndFolderServices)
        {
            _registry = registryServices;

            ActionName = "SCCM Remote Access Registry Modify";
            Description = "Changes the remote access options for SCCM remote control.";
            Category = "SCCM";
        }
Пример #4
0
 public ManagerReportsViewModel(IRegistryServices registryServices, IManagerReportServices managerReportServices, IManagerLiquidAssetServices managerLiquidAssetServices)
 {
     _services       = registryServices ?? throw new ArgumentNullException("ManagerReportsViewModel with no registry services");
     _reportServices = managerReportServices ?? throw new ArgumentNullException("ManagerReportsViewModel with no report services");
     _assetServices  = managerLiquidAssetServices ?? throw new ArgumentNullException("ManagerLiquidAssetServices");
     CloseMeCommand  = new CommandHandler(CloseMe);
     ViewCommand     = new CommandHandler(ViewReport, CanDoReport);
     ClearCommand    = new CommandHandler(ClearReport, CanClearReport);
     DownloadCommand = new CommandHandler(ExportReport, CanExportReport);
     SetUpViewModel();
 }
Пример #5
0
        public SchedeTitoliViewModel(IRegistryServices registryServices)
        {
            _registryServices = registryServices ?? throw new ArgumentNullException("SchedeTitoliViewModel senza registryServices");

            CloseMeCommand = new CommandHandler(CloseMe);
            InsertCommand  = new CommandHandler(InsertData, CanInsertData);
            ClearCommand   = new CommandHandler(ClearReport, CanClearForm);
            ModifyCommand  = new CommandHandler(ModifyData, CanModifyData);
            DeleteCommand  = new CommandHandler(DeleteData, CanModifyData);
            SetUpViewModel();
        }
 public RegistryMovementTypeViewModel(IRegistryServices services)
 {
     _services = services ?? throw new ArgumentNullException("RegistryMovementTypeViewModel With No Services");
     try
     {
         MovementTypeList = new ObservableCollection <RegistryMovementType>(services.GetRegistryMovementTypesList());
     }
     catch (Exception err)
     {
         MessageBox.Show("Errore nella richiesta dei dati." + Environment.NewLine + err.Message, "DAF-C Lista Tipologia Movimenti");
     }
     CloseMeCommand = new CommandHandler(CloseMe);
 }
Пример #7
0
 public RegistryCurrencyViewModel(IRegistryServices service)
 {
     _services = service ?? throw new ArgumentNullException("RegistryCurrencyModel With No Services");
     try
     {
         CurrencyList = new ObservableCollection <RegistryCurrency>(service.GetRegistryCurrencyList());
         CurrencyList.CollectionChanged += CollectionHasChanged;
     }
     catch (Exception err)
     {
         MessageBox.Show("Errore nella richiesta dei dati." + Environment.NewLine + err.Message, "DAF-C Lista Valute");
     }
     CloseMeCommand = new CommandHandler(CloseMe);
 }
 /// <summary>
 /// costruttore
 /// </summary>
 /// <param name="services">la gestione dei dati verso il database</param>
 public RegistryOwnerViewModel(IRegistryServices services)
 {
     _services = services ?? throw new ArgumentNullException("RegistryOwnerViewModel With No Services");
     try
     {
         OwnerList = new ObservableCollection <RegistryOwner>(services.GetGestioneList());
         OwnerList.CollectionChanged += CollectionHasChanged;
     }
     catch (Exception err)
     {
         MessageBox.Show("Errore nella richiesta dei dati." + Environment.NewLine + err.Message, "DAF-C Lista Gestioni");
     }
     CloseMeCommand = new CommandHandler(CloseMe);
 }
 public RegistryFirmViewModel(IRegistryServices services)
 {
     _services = services ?? throw new ArgumentNullException("RegistryFirmViewModel With No Services");
     try
     {
         FirmList = new ObservableCollection <RegistryFirm>(services.GetRegistryFirmList());
         _Filter  = new Predicate <object>(Filter);
     }
     catch (Exception err)
     {
         MessageBox.Show("Errore nella richiesta dei dati." + Environment.NewLine + err.Message, "DAF-C Lista Aziende");
     }
     CloseMeCommand = new CommandHandler(CloseMe);
 }
Пример #10
0
        public SccmRemoteAccessRegModify(
            ILoggerService logger,
            INetworkServices networkServices,
            IFileAndFolderServices fileAndFolderServices,
            IRegistryServices registryServices,
            IWindowService windowService) : base(logger, networkServices, fileAndFolderServices)
        {
            _windowService = windowService;
            _registry      = registryServices;

            ActionName  = "SCCM Remote Access Registry Modify";
            Description = "Changes the remote access options for SCCM remote control.";
            Category    = "SCCM";

            HasUserInterfaceElement = true;
            UiCallback = CallbackMethod;
        }
Пример #11
0
 public GestioneContoCorrenteViewModel(IRegistryServices registryServices, IManagerLiquidAssetServices managerLiquidServices)
 {
     _registryServices    = registryServices ?? throw new ArgumentNullException("Registry Services in Gestione Conto Corrente");
     _liquidAssetServices = managerLiquidServices ?? throw new ArgumentNullException("Registry Services in Gestione Conto Corrente");
     CloseMeCommand       = new CommandHandler(CloseMe);
     InsertCommand        = new CommandHandler(SaveCommand, CanSave);
     ModifyCommand        = new CommandHandler(UpdateCommand, CanModify);
     EraseCommand         = new CommandHandler(DeleteCommand, CanModify);
     ClearCommand         = new CommandHandler(CleanCommand);
     try
     {
         SetUpData();
         Init();
     }
     catch (Exception err)
     {
         MessageBox.Show("Errore nella richiesta dei dati." + Environment.NewLine + err.Message, "DAF-C Quote Investitori");
     }
 }