Convert erb files brought from spree_auth_devise to haml

This commit is contained in:
luisramos0
2019-07-08 17:36:54 +01:00
parent 1681e8a572
commit 86accc227e
8 changed files with 46 additions and 60 deletions

View File

@@ -1,3 +0,0 @@
<% if can? :admin, Spree::User %>
<%= tab(:users, :url => spree.admin_users_path, :icon => 'icon-user') %>
<% end %>

View File

@@ -0,0 +1,2 @@
- if can? :admin, Spree::User
= tab(:users, url: spree.admin_users_path, icon: 'icon-user')

View File

@@ -1,23 +0,0 @@
<% content_for :page_title do %>
<%= Spree.t(:new_user) %>
<% end %>
<% content_for :page_actions do %>
<li>
<%= button_link_to Spree.t(:back_to_users_list), spree.admin_users_path, :icon => 'icon-arrow-left' %>
</li>
<% end %>
<div data-hook="admin_user_new_form_header">
<%= render :partial => 'spree/shared/error_messages', :locals => { :target => @user } %>
</div>
<div data-hook="admin_user_new_form">
<%= form_for [:admin, @user] do |f| %>
<%= render :partial => 'form', :locals => { :f => f } %>
<div data-hook="admin_user_new_form_buttons">
<%= render :partial => 'spree/admin/shared/new_resource_links' %>
</div>
<% end %>
</div>

View File

@@ -0,0 +1,15 @@
= content_for :page_title do
= Spree.t(:new_user)
= content_for :page_actions do
%li
= button_link_to Spree.t(:back_to_users_list), spree.admin_users_path, icon: 'icon-arrow-left'
%div
= render partial: 'spree/shared/error_messages', locals: { target: @user }
%div
= form_for [:admin, @user] do |f|
= render partial: 'form', locals: { f: f }
%div
= render partial: 'spree/admin/shared/new_resource_links'

View File

@@ -1,17 +0,0 @@
<p>
<%= f.label :email, Spree.t(:email) %><br />
<%= f.email_field :email, :class => 'title' %>
</p>
<div id="password-credentials">
<p>
<%= f.label :password, Spree.t(:password) %><br />
<%= f.password_field :password, :class => 'title' %>
</p>
<p>
<%= f.label :password_confirmation, Spree.t(:confirm_password) %><br />
<%= f.password_field :password_confirmation, :class => 'title' %>
</p>
</div>
<div data-hook="signup_below_password_fields"></div>

View File

@@ -0,0 +1,15 @@
%p
= f.label :email, Spree.t(:email)
%br
= f.email_field :email, class: 'title'
%div{"id" => "password-credentials"}
%p
= f.label :password, Spree.t(:password)
%br
= f.password_field :password, class: 'title'
%p
= f.label :password_confirmation, Spree.t(:confirm_password)
%br
= f.password_field :password_confirmation, class: 'title'

View File

@@ -1,17 +0,0 @@
<%= render :partial => 'spree/shared/error_messages', :locals => { :target => @spree_user } %>
<div id="forgot-password">
<h6><%= Spree.t(:forgot_password) %></h6>
<p><%= Spree.t(:instructions_to_reset_password) %></p>
<%= form_for Spree::User.new, :as => :spree_user, :url => spree.reset_password_path do |f| %>
<p>
<%= f.label :email, Spree.t(:email) %><br />
<%= f.email_field :email %>
</p>
<p>
<%= f.submit Spree.t(:reset_password), :class => 'button primary' %>
</p>
<% end %>
</div>

View File

@@ -0,0 +1,14 @@
= render partial: 'spree/shared/error_messages', locals: { target: @spree_user }
%div{"id" => "forgot-password"}
%h6= Spree.t(:forgot_password)
%p= Spree.t(:instructions_to_reset_password)
= form_for Spree::User.new, as: :spree_user, url: spree.reset_password_path do |f|
%p
= f.label :email, Spree.t(:email)
%br
= f.email_field :email
%p
= f.submit Spree.t(:reset_password), class: 'button primary'