Skip to content

Instantly share code, notes, and snippets.

class ArticlesController < ApplicationController
before_action :authenticate_enterprise!, except: [:index]
def index
@articles = Article.all
end
def show
@article = Article.find(params[:id])
@hernandezalek
hernandezalek / application.js
Last active August 21, 2016 04:12
Materialize Modal
$( document ).ready(function(){
$(document).ready(function(){
$('.modal-trigger').leanModal();
});
})
config.action_mailer.default_url_options = { host: 'www.mi-domnio.com' }
ActionMailer::Base.smtp_settings = {
:port => 587,
:address => 'smtp.mailgun.org',
:user_name => 'postmaster@your.mailgun.domain',
:password => 'mailgun-smtp-password',
:domain => 'your.mailgun.domain',
:authentication => :plain,
}