This file contains 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
using System.Linq; | |
using System.Web.Mvc; | |
using Microsoft.AspNet.Identity; | |
namespace AuditSample.Models | |
{ | |
public class AuditFilter:FilterAttribute, IActionFilter | |
{ | |
public void OnActionExecuting(ActionExecutingContext filterContext) | |
{ |
This file contains 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
using System.Linq; | |
using System.Web.Mvc; | |
using Microsoft.AspNet.Identity; | |
namespace AuditSample.Models | |
{ | |
public class AuditFilter:FilterAttribute, IActionFilter | |
{ | |
public void OnActionExecuting(ActionExecutingContext filterContext) | |
{ |
This file contains 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
<system.webServer> | |
<security> | |
<requestFiltering> | |
<hiddenSegments> | |
<add segment="templates" /> | |
</hiddenSegments> | |
</requestFiltering> | |
</security> | |
</system.webServer> |
This file contains 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
<system.net> | |
<mailSettings> | |
<smtp deliveryMethod="SpecifiedPickupDirectory"> | |
<specifiedPickupDirectory pickupDirectoryLocation="c:\Temp\mail\"/> | |
</smtp> | |
</mailSettings> | |
</system.net> |
This file contains 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
using System; | |
using System.Collections.Generic; | |
using System.IO; | |
using System.Linq; | |
using System.Web; | |
using HandlebarsDotNet; | |
namespace WcfDemoMail.Mail | |
{ | |
public static class MailGenerator |
This file contains 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
<!doctype html> | |
<html> | |
<head> | |
<meta name="viewport" content="width=device-width"> | |
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> | |
<title>Really Simple HTML Email Template</title> | |
<style> | |
/* ------------------------------------- | |
GLOBAL | |
------------------------------------- */ |
This file contains 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
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Net.Mail; | |
using System.Runtime.Serialization; | |
using System.ServiceModel; | |
using System.Text; | |
using WcfDemoMail.Mail; | |
namespace WcfDemoMail |
This file contains 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
//set the compiler options to use 3.5 version of assemblies | |
Dictionary<string,string> compilerOptions=new Dictionary<string, string>(); | |
compilerOptions.Add("CompilerVersion", "v3.5"); | |
// Select the code provider | |
CSharpCodeProvider codeProvider = new CSharpCodeProvider(compilerOptions); | |
CompilerParameters compilerparams = new CompilerParameters(); | |
// we dont want to generate an executable |
This file contains 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 RefactorView.Models.Product | |
@{ | |
ViewBag.Title = "Nuevo"; | |
} | |
<h2>Nuevo</h2> | |
@using (Html.BeginForm()) | |
{ |
This file contains 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
using System.Web.Mvc; | |
namespace RefactorView.Infraestructure.Html | |
{ | |
public class FormControl | |
{ | |
public MvcHtmlString Label { get; set; } | |
public MvcHtmlString Control { get; set; } | |
public MvcHtmlString Validation { get; set; } | |
public string ContainerSize { get; set; } |