aboutsummaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
Diffstat (limited to 'app')
-rw-r--r--app/helpers/agents_helper.rb7
-rw-r--r--app/views/application/_user_info.html.erb4
2 files changed, 0 insertions, 11 deletions
diff --git a/app/helpers/agents_helper.rb b/app/helpers/agents_helper.rb
index a02fb7a..7e54438 100644
--- a/app/helpers/agents_helper.rb
+++ b/app/helpers/agents_helper.rb
@@ -1,9 +1,2 @@
module AgentsHelper
- # Form to select an Agent
- def agent_selector_form
- form_for current_agent, url: '/my/current_agent', method: :patch do |f|
- f.submit('select')
- f.select(:id, options_for_select(current_user.agents.map { |a| [a.name, a.id] }), selected: current_agent.id)
- end
- end
end
diff --git a/app/views/application/_user_info.html.erb b/app/views/application/_user_info.html.erb
index be3b6c5..048e6fb 100644
--- a/app/views/application/_user_info.html.erb
+++ b/app/views/application/_user_info.html.erb
@@ -3,10 +3,6 @@
<% if current_user.present? %>
<a href="/my/dashboard"><%= image_tag current_user.avatar_url, alt: current_user.username %></a>
<ul>
- <%#= tag.li(link_to(new_agent_switch_url, method: :get, remote: true, title: "Changer d'Agent") do
- "Agent: %s" % current_agent
- end, id: 'current_agent_name') %>
- <%= tag.li agent_selector_form %>
<%= tag.li link_to("Ajouter un point", new_agent_resource_url(agent_id: current_agent)) %>
<%= tag.li link_to("Terminer la session", logout_url) %>
</ul>