about summary refs log tree commit diff
path: root/app/views/admin
diff options
context:
space:
mode:
Diffstat (limited to 'app/views/admin')
-rw-r--r--app/views/admin/email_domain_blocks/_email_domain_block.html.haml5
-rw-r--r--app/views/admin/email_domain_blocks/index.html.haml13
-rw-r--r--app/views/admin/email_domain_blocks/new.html.haml10
3 files changed, 28 insertions, 0 deletions
diff --git a/app/views/admin/email_domain_blocks/_email_domain_block.html.haml b/app/views/admin/email_domain_blocks/_email_domain_block.html.haml
new file mode 100644
index 000000000..61cff9395
--- /dev/null
+++ b/app/views/admin/email_domain_blocks/_email_domain_block.html.haml
@@ -0,0 +1,5 @@
+%tr
+  %td.domain
+    %samp= email_domain_block.domain
+  %td
+    = table_link_to 'trash', t('admin.email_domain_blocks.delete'), admin_email_domain_block_path(email_domain_block), method: :delete
diff --git a/app/views/admin/email_domain_blocks/index.html.haml b/app/views/admin/email_domain_blocks/index.html.haml
new file mode 100644
index 000000000..fbdb3b80b
--- /dev/null
+++ b/app/views/admin/email_domain_blocks/index.html.haml
@@ -0,0 +1,13 @@
+- content_for :page_title do
+  = t('admin.email_domain_blocks.title')
+
+%table.table
+  %thead
+    %tr
+      %th= t('admin.email_domain_blocks.domain')
+      %th
+  %tbody
+    = render @email_domain_blocks
+
+= paginate @email_domain_blocks
+= link_to t('admin.email_domain_blocks.add_new'), new_admin_email_domain_block_path, class: 'button'
diff --git a/app/views/admin/email_domain_blocks/new.html.haml b/app/views/admin/email_domain_blocks/new.html.haml
new file mode 100644
index 000000000..bcae867d9
--- /dev/null
+++ b/app/views/admin/email_domain_blocks/new.html.haml
@@ -0,0 +1,10 @@
+- content_for :page_title do
+  = t('.title')
+
+= simple_form_for @email_domain_block, url: admin_email_domain_blocks_path do |f|
+  = render 'shared/error_messages', object: @email_domain_block
+
+  = f.input :domain, placeholder: t('admin.email_domain_blocks.domain')
+
+  .actions
+    = f.button :button, t('.create'), type: :submit