summaryrefslogtreecommitdiff
path: root/users/app/views
diff options
context:
space:
mode:
authorAzul <azul@leap.se>2012-12-10 11:00:24 +0100
committerAzul <azul@leap.se>2012-12-10 11:00:24 +0100
commit28b21959f39b0e28c450bba54b8696632a0187fa (patch)
tree7f13cad03190324ca0d242d3aee74bfb4efb00fa /users/app/views
parente4c7f2fb8fa2833037508f1b88f802944855fd77 (diff)
created generic Email class and use it with EmailAliases
Diffstat (limited to 'users/app/views')
-rw-r--r--users/app/views/emails/_email.html.haml4
-rw-r--r--users/app/views/users/_email_aliases.html.haml8
2 files changed, 6 insertions, 6 deletions
diff --git a/users/app/views/emails/_email.html.haml b/users/app/views/emails/_email.html.haml
new file mode 100644
index 0000000..f182ed9
--- /dev/null
+++ b/users/app/views/emails/_email.html.haml
@@ -0,0 +1,4 @@
+%li.pull-right
+ %code= email
+ %i.icon-remove
+.clearfix
diff --git a/users/app/views/users/_email_aliases.html.haml b/users/app/views/users/_email_aliases.html.haml
index 41d4f9e..646480e 100644
--- a/users/app/views/users/_email_aliases.html.haml
+++ b/users/app/views/users/_email_aliases.html.haml
@@ -1,10 +1,6 @@
.span6
%ul.unstyled
- - @user.email_aliases.each do |email_alias|
- %li.pull-right
- %code= email_alias.email
- %i.icon-remove
- .clearfix
+ =render @user.email_aliases
.clearfix
-= f.simple_fields_for :email_aliases, EmailAlias.new do |e|
+= f.simple_fields_for :email_aliases, Email.new do |e|
= e.input :email, :placeholder => "alias@#{request.domain}"