@extends('BaseSistemaWeb') @section('CSS') @stop @section('Contenido')

E-Mail Marketing

Crear nuevo perfíl de envío de correos

{{ Form::open(array('route' => 'SysWebEmailMarketingConfPerfilesAgregar', 'method' => 'post', 'class' => 'form-horizontal row-border', 'id' => 'frmAgregar', 'files' => true, 'target' => 'upload_iframe')) }} Datos de envío
{{ Form::text('remitente', '', array('class' => 'form-control', 'placeholder' => '')) }}
{{ Form::text('correo_electronico', '', array('class' => 'form-control', 'placeholder' => '')) }}
Información de contacto
{{ Form::text('pais', '', array('class' => 'form-control', 'placeholder' => '')) }}
{{ Form::text('estado', '', array('class' => 'form-control', 'placeholder' => '')) }}
{{ Form::text('direccion', '', array('class' => 'form-control', 'placeholder' => '')) }}
{{ Form::text('empresa', '', array('class' => 'form-control', 'placeholder' => '')) }}
{{ Form::text('sitio_web', '', array('class' => 'form-control', 'placeholder' => '')) }}
{{ Form::text('telefono', '', array('class' => 'form-control', 'placeholder' => '')) }}
{{--

--}}
{{ Form::button('Guardar', array('class' => 'btn btn-primary', 'id' => 'btnAgregar', 'type' => 'submit')) }} {{ HTML::linkRoute('SysWebEmailMarketingConfPerfiles', 'Cancelar', array(), array('class' => 'btn btn-default')) }}
{{ Form::close() }}
@stop @section('JS') {{-- HTML::script('WebPro/plugins/ckeditor-new/ckeditor.js') --}} {{ HTML::script('Alphanum/jquery.alphanum.min.js') }} @stop @section('JSOr') $('[name="confirmacion"]').click(function(){ if( $(this).val() == 0 ){ $("#dvConfirmacion").hide("slow"); } else{ $("#dvConfirmacion").show("slow"); } }); $('[name="remitente"]').alphanum({ allow: ".|", disallow: "", allowSpace: true, allowNewline: false, allowNumeric: true, allowLatin: true, allowOtherCharSets: true, maxLength: 35 }); $("#frmAgregar").submit(function(e){ $.isLoading({ text: "Cargando..." }); NProgress.start(); $("#btnAgregar").html(' Cargando').prop("disabled", true); e.preventDefault(); $(this).find("input").each(function(){ $(this).val($(this).val().trim()); }); var frmAgregar = new FormData(document.getElementById("frmAgregar")); $.ajax({ type: "POST", url: "{{ URL::route('SysWebEmailMarketingConfPerfilesAgregar', array()) }}", data: frmAgregar, cache: false, contentType: false, processData: false, dataType: "json", success: function(data){ $.isLoading("hide"); NProgress.done(); $("#btnAgregar").html("Guardar").prop("disabled", false); if(data.success){ new PNotify({ title: "Realizado", text: data.mensaje, type: "success" }); setTimeout( function(){ window.location.href = "{{ URL::route('SysWebEmailMarketingConfPerfiles') }}"; }, 3000 ); } else{ if(data.mensaje != ''){ new PNotify({ title: "Error", text: data.mensaje, type: "error" }); } $.each(data.errMensajes, function(key, value){ if(value != ''){ $("#err"+key).html(value); } else{ $("#err"+key).html(""); } }); } }, error: function(jqXHR, textStatus, errorThrown){ new PNotify({ title: "Error", text: textStatus + " " + errorThrown, type: "error" }); } }); }); @stop