new.html.haml 1.4 KB

1234567891011121314151617181920212223242526272829303132333435
  1. - content_for :page_title do
  2. = t('.title')
  3. = simple_form_for @email_domain_block, url: admin_email_domain_blocks_path do |f|
  4. = render 'shared/error_messages', object: @email_domain_block
  5. .fields-group
  6. = f.input :domain, wrapper: :with_block_label, label: t('admin.email_domain_blocks.domain'), input_html: { readonly: defined?(@resolved_records) }
  7. - if defined?(@resolved_records)
  8. %p.hint= t('admin.email_domain_blocks.resolved_dns_records_hint_html')
  9. .batch-table
  10. .batch-table__toolbar
  11. %label.batch-table__toolbar__select.batch-checkbox-all
  12. = check_box_tag :batch_checkbox_all, nil, false
  13. .batch-table__toolbar__actions
  14. .batch-table__body
  15. - @resolved_records.each do |record|
  16. .batch-table__row
  17. %label.batch-table__row__select.batch-table__row__select--aligned.batch-checkbox
  18. = f.input_field :other_domains, as: :boolean, checked_value: record.exchange.to_s, include_hidden: false, multiple: true
  19. .batch-table__row__content.pending-account
  20. .pending-account__header
  21. %samp= record.exchange.to_s
  22. %br
  23. = t('admin.email_domain_blocks.dns.types.mx')
  24. %hr.spacer/
  25. .actions
  26. - if defined?(@resolved_records)
  27. = f.button :button, t('.create'), type: :submit, name: :save
  28. - else
  29. = f.button :button, t('.resolve'), type: :submit, name: :resolve