public MainVM() { this._exceptionDlg = new View.ExceptionDlg(); this._exceptionVM = new ViewModel.ExceptionDlgVM(); this._exceptionDlg.DataContext = this._exceptionVM; this.Model = new Model.PartnerAllianceResubmit(); //this.Model.Reset(); BrowseForPS14FileCommand = new RelayCommand(e => browseForPS14File()); BrowseForPS15FileCommand = new RelayCommand(e => browseForPS15File()); CheckForErrorsCommand = new RelayCommand(e => checkForErrors(), e => canCheckForErrors()); PrepareForResubmitCommand = new RelayCommand(e => prepareForResubmit(), e => canPrepareForResubmit()); this.CheckForErrorsVisibility = Visibility.Hidden; this.PrepareForResubitVisibility = Visibility.Hidden; }
public MainVM() { this._exceptionDlg = new View.ExceptionDlg(); this._exceptionVM = new ViewModel.ExceptionDlgVM(); this._exceptionDlg.DataContext = this._exceptionVM; this._log = new TextLogger(Properties.Settings.Default.LogPath , Properties.Settings.Default.LoggingThreshold); this.Model = new Model.PpolTestFileGenerator(_log); this.Model.TestFileDestinationBeforeOvernightCutOff = Properties.Settings.Default.TesFileDestinationBeforeOvernightCutOff; this.Model.TestFileDestinationAfterOvernightCutOff = Properties.Settings.Default.TesFileDestinationAfterOvernightCutOff; this.Model.OvernightCutOffHHMM = Properties.Settings.Default.OvernightCutOffHHMM; this.Model.TestFileCopyDestination = Properties.Settings.Default.TesFileCopyDestination; this.Model.SendScript = Properties.Settings.Default.SendScript; this.Model.Reset(); this.AddCmd = new RelayCommand(e => this.addCard(), e => this.canAddCard()); this.CancelCmd = new RelayCommand(e => this.resetForm(), e => this.canResetForm()); this.CreateCmd = new RelayCommand(e => this.createTestFile(), e => this.canCreateTestFile()); this.AddCmd.CanExecuteChanged += AddCmd_CanExecuteChanged; }