Sha256: 259d2d947d58c3ab1e61543fff4391914ff264e3232de41156c179ac72a83872

Contents?: true

Size: 1.53 KB

Versions: 40

Compression:

Stored size: 1.53 KB

Contents

- url = email_template.new_record? ? email_templates_path : email_template_path(email_template.id)

.email-templates--form
  = form_for email_template, as: :template, url: url do |f|
    .field
      %label Slug
      = f.text_field :slug
    .flex-row
      %label Layout
      = f.select :layout, options_for_select(WcoEmail::EmailTemplate::LAYOUTS, selected: email_template.layout), {}, class: 'select2'
      %label From
      = f.select :from_email, options_for_select(WcoEmail::EmailTemplate.from_emails_list, selected: email_template.from_email), {}, class: 'select2'
    .field.field-subject
      = f.label :subject
      = f.text_field :subject
    .field
      = f.label :preview_str
      = f.text_field :preview_str
    -# .field
    -#   = f.label :can_unsubscribe
    -#   = f.check_box :can_unsubscribe


    .tab-labels.flex-row
      %a.label-raw{ href: "javascript: void(0)", data: { ref: '.tab-raw' } } Raw
      %a.label-preview.active{ href: "javascript: void(0)", data: { ref: '.tab-preview' } } Preview
      .label-save-preview= f.submit 'Save & Preview'
    .tabs
      .tab-raw
        = f.text_area :body # , class: 'tinymce'
      .tab-preview
        - if email_template.persisted?
          %iframe{ src: email_template_iframe_path(email_template), width: '100%', height: '100%' }

    .row
      .col-md-6
        .field
          = f.label :config_json
          = f.text_area :config_json
      .col-md-6
        .field
          = f.label :config_exe
          = f.text_area :config_exe

    .actions
      = f.submit 'Save'

Version data entries

40 entries across 40 versions & 1 rubygems

Version Path
wco_email-0.1.1.40 app/views/wco_email/email_templates/_form.haml
wco_email-0.1.1.39 app/views/wco_email/email_templates/_form.haml
wco_email-0.1.1.38 app/views/wco_email/email_templates/_form.haml
wco_email-0.1.1.37 app/views/wco_email/email_templates/_form.haml
wco_email-0.1.1.36 app/views/wco_email/email_templates/_form.haml
wco_email-0.1.1.35 app/views/wco_email/email_templates/_form.haml
wco_email-0.1.1.34 app/views/wco_email/email_templates/_form.haml
wco_email-0.1.1.33 app/views/wco_email/email_templates/_form.haml
wco_email-0.1.1.32 app/views/wco_email/email_templates/_form.haml
wco_email-0.1.1.31 app/views/wco_email/email_templates/_form.haml
wco_email-0.1.1.30 app/views/wco_email/email_templates/_form.haml
wco_email-0.1.1.29 app/views/wco_email/email_templates/_form.haml
wco_email-0.1.1.28 app/views/wco_email/email_templates/_form.haml
wco_email-0.1.1.27 app/views/wco_email/email_templates/_form.haml
wco_email-0.1.1.26 app/views/wco_email/email_templates/_form.haml
wco_email-0.1.1.25 app/views/wco_email/email_templates/_form.haml
wco_email-0.1.1.24 app/views/wco_email/email_templates/_form.haml
wco_email-0.1.1.23 app/views/wco_email/email_templates/_form.haml
wco_email-0.1.1.22 app/views/wco_email/email_templates/_form.haml
wco_email-0.1.1.21 app/views/wco_email/email_templates/_form.haml