This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @model HangfireAndPostal.Models.RegisterUserEmail | |
| To: @Model.Email | |
| Subject: New Account | |
| <h1>Hi @Model.FirstName!</h1> | |
| <p>Thank you for creating an account.</p> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public class FilterConfig | |
| { | |
| public static void RegisterGlobalFilters(GlobalFilterCollection filters) | |
| { | |
| filters.Add(new HandleErrorAttribute()); | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public bool HasAccess(ApplicationUser user, Invoice entity) | |
| { | |
| if(user == null) | |
| { | |
| throw new ArgumentNullException("user"); | |
| } | |
| if(entity == null) | |
| { | |
| throw new ArgumentNullException("entity"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Activating: System.Lazy`1[DependencyInjectionWithLazy.Logics.IUserLogic] | |
| Activating: DependencyInjectionWithLazy.Controllers.UsersController | |
| Before call controller: Users.create (GET) | |
| After call controller: Users.create (GET) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public class AutofacConfig | |
| { | |
| public static IContainer Configure() | |
| { | |
| var builder = new ContainerBuilder(); | |
| builder.RegisterAssemblyModules(typeof(AutofacConfig).Assembly); | |
| var container = builder.Build(); | |
| DependencyResolver.SetResolver(new AutofacDependencyResolver(container)); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public virtual ActionResult Action(int id) | |
| { | |
| return Content(id.ToString()); | |
| } | |
| public virtual ActionResult RedirectToActionUsingString() | |
| { | |
| return RedirectToAction("Action", "Home", new { id = 10 }); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public class User | |
| { | |
| public string FirstName { get; set; } | |
| public string LastName { get; set; } | |
| public string Email { get; set; } | |
| public Gender Gender { get; set; } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public class BaseMailer | |
| { | |
| protected void Send(Email email) | |
| { | |
| var mailerName = GetType().Name.Replace("Mailer", string.Empty); | |
| var viewsPath = Path.GetFullPath(string.Format(HostingEnvironment.MapPath(@"~/Views/Emails/{0}"), mailerName)); | |
| var engines = new ViewEngineCollection(); | |
| engines.Add(new FileSystemRazorViewEngine(viewsPath)); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <TextBox | |
| Text="{Binding Email, | |
| UpdateSourceTrigger=PropertyChanged, | |
| Mode=TwoWay, | |
| ValidatesOnNotifyDataErrors=True}" | |
| Name="Email"/> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <Window x:Class="FluentValidationWithWPF.MainWindow" | |
| xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | |
| xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | |
| xmlns:d="http://schemas.microsoft.com/expression/blend/2008" | |
| xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" | |
| xmlns:local="clr-namespace:FluentValidationWithWPF" | |
| mc:Ignorable="d" | |
| Title="MainWindow" Height="450" Width="800"> | |
| <StackPanel> | |
| <TextBox Text="{Binding Email, UpdateSourceTrigger=PropertyChanged, Mode=TwoWay, ValidatesOnDataErrors=True}" |
OlderNewer