Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@marcfuentes
Created May 10, 2015 04:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save marcfuentes/1c9901d9916ca46c0a04 to your computer and use it in GitHub Desktop.
Save marcfuentes/1c9901d9916ca46c0a04 to your computer and use it in GitHub Desktop.
form
<div class="row-fluid">
<div class="services_pro col-md-6 col-md-offset-1 ">
<div class="well well large">
<p><h3>Envia un mensaje a <%= @lawyer.name %></h3></p>
<p><%= form_tag({controller: "messages", action: "create"}, method: :post) do %></p>
<%= label_tag :Asunto %>
<p><%= text_field_tag :subject %></p>
<%= label :body, "Mensaje" %>
<p><%= text_area_tag :body %></p>
<%= hidden_field_tag(:lawyer, "#{@lawyer.id}") %>
<%= submit_tag 'Enviar Mensaje', class: "btn btn-primary" %>
<% end %>
</div>
</div>
</div>
@jtansley
Copy link

Is this /app/views/messages/new.html.erb?

@marcfuentes
Copy link
Author

No, is not the same structure as your example, I put this code in /app/views/lawyers/message.html.erb
heres the full repo https://github.com/marcfuentes/abogado

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment