Closed Bug 1162444 Opened 9 years ago Closed 9 years ago

Update conversation window context view data after editing context

Categories

(Hello (Loop) :: Client, defect, P2)

defect
Points:
2

Tracking

(firefox40 verified, firefox41 verified)

VERIFIED FIXED
mozilla41
Iteration:
41.1 - May 25
Tracking Status
firefox40 --- verified
firefox41 --- verified

People

(Reporter: mikedeboer, Assigned: standard8)

References

Details

(Whiteboard: [context])

Attachments

(1 file, 1 obsolete file)

In bug 1142515 we added the ability to edit the context information that is attached to a room.
After editing the context information, the view inside the conversation window is updated accordingly, but not the rooms list inside the Loop panel.
We should fix this by emitting an 'update' event from LoopRooms once the context data has been updated.
Flags: qe-verify+
Flags: firefox-backlog+
Blocks: 1115340
Rank: 21
Whiteboard: [context]
(In reply to Mike de Boer [:mikedeboer] from comment #0)
> After editing the context information, the view inside the conversation
> window is updated accordingly, but not the rooms list inside the Loop panel.
> We should fix this by emitting an 'update' event from LoopRooms once the
> context data has been updated.

Mike, I don't see any issues with the panel here - I've just been testing with latest fx-team and that gets updated automatically.

However, from what I see, the conversation window doesn't get updated - if you add context, the "add context" remains there, if you edit it, then the view remains with the old information.
Flags: needinfo?(mdeboer)
As I still can't see an issue in the panel, I'm assuming its definitely the conversation window that has the issue.

Here's a simple patch that fixes the update in the conversation window - basically activeRoomStore needs to listen to updates from LoopRooms and update itself appropraitely.
Attachment #8609282 - Flags: review?(mdeboer)
Assignee: nobody → standard8
Iteration: --- → 41.1 - May 25
Flags: needinfo?(mdeboer)
Summary: Update rooms list context data after editing context → Update conversation window context view data after editing context
Comment on attachment 8609282 [details] [diff] [review]
Update context views when the context changes in Loop rooms.

Review of attachment 8609282 [details] [diff] [review]:
-----------------------------------------------------------------

One simple question below...

::: browser/components/loop/content/shared/js/activeRoomStore.js
@@ +201,5 @@
>              socialShareButtonAvailable: this._mozLoop.isSocialShareButtonAvailable(),
>              socialShareProviders: this._mozLoop.getSocialShareProviders()
>            }));
>  
> +          this._mozLoop.rooms.on("update:" + actionData.roomToken, this._onRoomUpated.bind(this));

no `off` ?
Attachment #8609282 - Flags: review?(mdeboer)
Its a good job you asked about off, as it turns out, we already have an update listening mechanism - we just weren't supplying all the required attributes for it.
Attachment #8609282 - Attachment is obsolete: true
Attachment #8609344 - Flags: review?(mdeboer)
Comment on attachment 8609344 [details] [diff] [review]
Simpler patch - update via existing mechanism

Review of attachment 8609344 [details] [diff] [review]:
-----------------------------------------------------------------

Ah, indeed! Well done :)
Attachment #8609344 - Flags: review?(mdeboer) → review+
https://hg.mozilla.org/mozilla-central/rev/30f9247cf363
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla41
Comment on attachment 8609344 [details] [diff] [review]
Simpler patch - update via existing mechanism

Approval Request Comment
[Feature/regressing bug #]: Context in conversations for Hello
[User impact if declined]: User may be confused - after having edited context the in-room display will remain as it was before the edit with no visible evidence of the edit having been completed.
[Describe test coverage new/current, TreeHerder]: Landed in m-c, has unit tests
[Risks and why]: Simple update to take existing data and ensure it gets displayed.
[String/UUID change made/needed]: None
Attachment #8609344 - Flags: approval-mozilla-aurora?
Attachment #8609344 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
QA Contact: bogdan.maris
Reproduced the initial issue using old Nightly build from 2015-05-22, verified across platforms (Windows 7 64-bit, Mac OS X 10.9.5 and Ubuntu 14.04 32-bit) that the issue is fixed using Nightly build from 2015-05-28 and latest Aurora and Nightly builds (even though the layout was a bit changed in latest builds).
Status: RESOLVED → VERIFIED
Flags: qe-verify+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: