public PrismTabbedPageViewModel(IPageDialogService pageDialogService) { _pageDialogService = pageDialogService; ValidationService = new ValidationService <PrismTabbedPageViewModel>(this, true); EntryNotEmptyRule = ValidationService.Add(e => new IsNotNullOrEmptyRule(nameof(e.UserName))); EntryPassRule = ValidationService.Add(e => new StrongPasswordRule(nameof(e.Password))); CustomRule = ValidationService.Add(e => new CustomRule(nameof(e.ForCustomValue))); EmailRule = ValidationService.Add(e => new EmailRule(nameof(e.Email))); }
// This method gets called by the runtime. Use this method to add services to the container. public void ConfigureServices(IServiceCollection services) { ServiceInjector.Add(services, Configuration); ValidationService.Add(services); services.AddSession(); services.AddHttpContextAccessor(); //sayfayi yenileyince yenilikleri algilamasi icin services.AddControllersWithViews() .AddRazorRuntimeCompilation(); services.AddControllersWithViews() .AddFluentValidation(); services.AddFormHelper(new FormHelperConfiguration { CheckTheFormFieldsMessage = "Check the form fields." //RedirectDelay->Yönlendirme iþlemlerinde beklenecek varsayýlan süre. //ToastrDefaultPosition->Bildirim / Uyarý mesajlarýnýn ekranda görüneceði pozisyon. }); }