/// <summary> /// Initializes a new instance of the <see cref="StaffDialogViewModel"/> class. /// </summary> /// <param name="unitOfWork">Unit of work.</param> /// <param name="messageBoxProvider">Message box provider.</param> /// <param name="genderCache">Gender cache.</param> /// <param name="positionCache">Position cache.</param> /// <param name="educationCache">Education cache.</param> /// <param name="mode">Mode (Add/Edit).</param> /// <param name="model">Staff model.</param> public StaffDialogViewModel( IUnitOfWork unitOfWork, IMessageBoxProvider messageBoxProvider, IGenderCache genderCache, IPositionCache positionCache, IEducationCache educationCache, WorkModeType mode, StaffModel model = null) : base(mode) { this.unitOfWork = unitOfWork; this.messageBoxProvider = messageBoxProvider; this.genderCache = genderCache; this.positionCache = positionCache; this.educationCache = educationCache; Task.Factory.StartNewWithDefaultCulture(() => this.Load(model)); }
/// <summary> /// Initializes a new instance of the <see cref="PatientDialogViewModel"/> class. /// </summary> /// <param name="unitOfWork">Unit of work.</param> /// <param name="viewModelBuilder">View model builder.</param> /// <param name="viewBuilder">View builder.</param> /// <param name="messageBoxProvider">Message box provider.</param> /// <param name="applicationSettings">Application settings.</param> /// <param name="genderCache">Gender cache.</param> /// <param name="mode">Mode (Add/Edit).</param> /// <param name="model">Patient model.</param> public PatientDialogViewModel( IUnitOfWork unitOfWork, IViewModelBuilder viewModelBuilder, IViewBuilder viewBuilder, IMessageBoxProvider messageBoxProvider, IApplicationSettings applicationSettings, IGenderCache genderCache, WorkModeType mode, PatientModel model = null) : base(mode) { this.unitOfWork = unitOfWork; this.viewModelBuilder = viewModelBuilder; this.viewBuilder = viewBuilder; this.messageBoxProvider = messageBoxProvider; this.applicationSettings = applicationSettings; this.genderCache = genderCache; Task.Factory.StartNewWithDefaultCulture(() => this.Load(model)); }