123456789101112131415161718192021222324252627282930313233 |
- <% provide(:title, @conversation.name) %>
- <div class="row">
- <div class="col-md-6 message-feed">
- <%= render @conversation.messages %>
- <%= bootstrap_form_for(current_user.messages.build) do |f| %>
- <%= render 'shared/error_messages', object: f.object %>
- <%= hidden_field_tag :conversation_id, @conversation.id %>
- <%= f.text_area :content, label: "New message" %>
- <%= f.submit "Send message", class: "btn btn-primary" %>
- <% end %>
- </div>
- <div class="col-md-6">
- <h1><%= @conversation.name %></h1>
- <h3>Users</h3>
- <ul>
- <% for user in @conversation.users %>
- <li>
- <%= render user %>
- </li>
- <% end %>
- </ul>
- <h3>Add user to conversation</h3>
- <%= render 'conversation_participations/form' %>
- </div>
- </div>
- <script>
- $(document).ready(function() {
- $('#conversation_participation_user_id').select2();
- });
- </script>
|