From 74fff52e512e4342d6f7529927ae66eddb520792 Mon Sep 17 00:00:00 2001 From: Steffen van Bergerem Date: Mon, 3 Oct 2016 00:54:34 +0200 Subject: [PATCH] Fix message modal on profile page closes #7137 fixes #7136 --- Changelog.md | 1 + app/views/conversations/new.html.haml | 1 + features/desktop/conversations.feature | 12 ++++++++++++ 3 files changed, 14 insertions(+) diff --git a/Changelog.md b/Changelog.md index 5de9675d0..1dcc5b9bc 100644 --- a/Changelog.md +++ b/Changelog.md @@ -34,6 +34,7 @@ Note: Although this is a minor release, the configuration file changed because t * Clicking photos on mobile should no longer cause 404s [#7071](https://github.com/diaspora/diaspora/pull/7071) * Fix avatar size on mobile privacy page for ignored people [#7148](https://github.com/diaspora/diaspora/pull/7148) * Don't display tag following button when logged out [#7155](https://github.com/diaspora/diaspora/pull/7155) +* Fix message modal on profile page[#7137](https://github.com/diaspora/diaspora/pull/7137) ## Features * Deleted comments will be removed when loading more comments [#7045](https://github.com/diaspora/diaspora/pull/7045) diff --git a/app/views/conversations/new.html.haml b/app/views/conversations/new.html.haml index 8462a3990..1acbba809 100644 --- a/app/views/conversations/new.html.haml +++ b/app/views/conversations/new.html.haml @@ -2,6 +2,7 @@ $(document).ready(function () { var data = $.parseJSON( "#{escape_javascript(@contacts_json)}" ); new app.views.ConversationsForm({ + el: $("form#new-conversation").parent(), contacts: data, prefillName: "#{h params[:name]}", prefillValue: "#{@contact_ids}" diff --git a/features/desktop/conversations.feature b/features/desktop/conversations.feature index 2fcc54c2f..a9408fb69 100644 --- a/features/desktop/conversations.feature +++ b/features/desktop/conversations.feature @@ -44,6 +44,18 @@ Feature: private conversations Then I should have 2 unread private messages And I should have 2 email delivery + Scenario: send a message from the profile page + When I sign in as "bob@bob.bob" + And I am on "alice@alice.alice"'s page + And I click on selector "#message_button" + And I fill in "conversation-subject" with "Greetings" + And I fill in "new-message-text" with "hello, alice!" + And I press "Send" within "#conversationModal" + Then I should see "Greetings" within "#conversation-inbox" + And I should see "Greetings" within "#conversation-show" + And "Alice Awesome" should be part of active conversation + And I should see "hello, alice!" within ".stream_container" + Scenario: delete a conversation When I sign in as "bob@bob.bob" And I send a message with subject "Greetings" and text "hello, alice!" to "Alice Awesome"