class OnboardingMailer < ApplicationMailer
  def onboarding_email
    @school_onboarding = params[:school_onboarding]
    make_bootstrap_mail(to: @school_onboarding.contact_email, subject: "Set up your school on Energy Sparks")
  end

  def completion_email
    @school_onboarding = params[:school_onboarding]
    if @school_onboarding.created_by
      make_bootstrap_mail(to: @school_onboarding.created_by.email, subject: "#{@school_onboarding.school_name} has completed the onboarding process")
    end
  end

  def reminder_email
    @school_onboarding = params[:school_onboarding]
    make_bootstrap_mail(to: @school_onboarding.contact_email, subject: "Don't forget to set up your school on Energy Sparks")
  end

  def activation_email
    @school_onboarding = params[:school_onboarding]
    @school = @school_onboarding.school
    make_bootstrap_mail(to: @school_onboarding.created_by.email, subject: "#{@school.name} is live on Energy Sparks")
  end
end

class OnboardingMailer < ApplicationMailer
  def onboarding_email
    @school_onboarding = params[:school_onboarding]
    make_bootstrap_mail(to: @school_onboarding.contact_email, subject: "Set up your school on Energy Sparks")
  end

  def completion_email
    @school_onboarding = params[:school_onboarding]
    if @school_onboarding.created_by
      make_bootstrap_mail(to: @school_onboarding.created_by.email, subject: "#{@school_onboarding.school_name} has completed the onboarding process")
    end
  end

  def reminder_email
    @school_onboarding = params[:school_onboarding]
    make_bootstrap_mail(to: @school_onboarding.contact_email, subject: "Don't forget to set up your school on Energy Sparks")
  end

  def activation_email
    @school_onboarding = params[:school_onboarding]
    @school = @school_onboarding.school
    make_bootstrap_mail(to: @school_onboarding.created_user.email, subject: "#{@school.name} is live on Energy Sparks")
  end
end

Send activation email to the right address
Send activation email to the right address
