From ebede9d016868c661cbe7beb96938fc951cf2324 Mon Sep 17 00:00:00 2001 From: Victor Costa Date: Wed, 13 Aug 2014 19:39:43 -0300 Subject: [PATCH] Use xmpp_chat to render new chat layout --- app/views/chat/index.html.erb | 82 ---------------------------------------------------------------------------------- app/views/layouts/application-ng.html.erb | 3 +-- app/views/shared/logged_in/xmpp_chat.html.erb | 89 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++--------- 3 files changed, 81 insertions(+), 93 deletions(-) delete mode 100644 app/views/chat/index.html.erb diff --git a/app/views/chat/index.html.erb b/app/views/chat/index.html.erb deleted file mode 100644 index aa70b00..0000000 --- a/app/views/chat/index.html.erb +++ /dev/null @@ -1,82 +0,0 @@ - <%= javascript_include_tag 'strophejs-1.0.1/strophe', 'jquery.emoticon', '../designs/icons/pidgin/emoticons.js', 'ba-linkify', 'jquery.ba-hashchange', 'jquery.sound', 'chat', 'perfect-scrollbar.min.js', 'perfect-scrollbar.with-mousewheel.min.js', :cache => 'cache/chat' %> - <%= stylesheet_link_tag 'perfect-scrollbar.min.css' %> - - <% extend ChatHelper %> - - - - - <% presence = current_user.last_chat_status %> - - -
-
-

<%= _("Online") % h(page_title) %> (0)

-
-
-
-
<%= user_status_menu('icon-menu-offline', _('Offline')) %>
- -
-
    -
-
-
-
-
    -
-
-
- -
-
- <%= _('Back') %> -
-
-
- -
-
- - - -
-
-
- -
%{name}
-
-
- %{time} -

%{message}

-
-
-
-
-
diff --git a/app/views/layouts/application-ng.html.erb b/app/views/layouts/application-ng.html.erb index b1f7d89..f8e4408 100644 --- a/app/views/layouts/application-ng.html.erb +++ b/app/views/layouts/application-ng.html.erb @@ -76,7 +76,7 @@ - <%= render_environment_features(:logged_in) %> + <%= render_environment_features(:logged_in) if logged_in? %> @@ -88,6 +88,5 @@ if content.respond_to?(:call) then instance_exec(&content).html_safe else content.html_safe end end.join("\n") %> - <%= render :file => 'chat/index' if logged_in? %> diff --git a/app/views/shared/logged_in/xmpp_chat.html.erb b/app/views/shared/logged_in/xmpp_chat.html.erb index a380e97..aa70b00 100644 --- a/app/views/shared/logged_in/xmpp_chat.html.erb +++ b/app/views/shared/logged_in/xmpp_chat.html.erb @@ -1,11 +1,82 @@ -