From 514e0fd4b675cbb2ed36687095daa047730c60d8 Mon Sep 17 00:00:00 2001 From: Matthew Hodgson Date: Fri, 17 Oct 2014 23:11:55 +0100 Subject: fix webclient to know about right timestamps --- webclient/room/room-controller.js | 4 ++-- webclient/room/room.html | 3 +-- 2 files changed, 3 insertions(+), 4 deletions(-) (limited to 'webclient') diff --git a/webclient/room/room-controller.js b/webclient/room/room-controller.js index d8c62c231e..a1d2e87039 100644 --- a/webclient/room/room-controller.js +++ b/webclient/room/room-controller.js @@ -603,9 +603,9 @@ angular.module('RoomController', ['ngSanitize', 'matrixFilter', 'mFileInput']) var echoMessage = { content: { body: (cmd === "/me" ? args : input), - hsob_ts: new Date().getTime(), // fake a timestamp msgtype: (cmd === "/me" ? "m.emote" : "m.text"), }, + origin_server_ts: new Date().getTime(), // fake a timestamp room_id: $scope.room_id, type: "m.room.message", user_id: $scope.state.user_id, @@ -640,7 +640,7 @@ angular.module('RoomController', ['ngSanitize', 'matrixFilter', 'mFileInput']) if (echoMessage) { // Mark the message as unsent for the rest of the page life - echoMessage.content.hsob_ts = "Unsent"; + echoMessage.origin_server_ts = "Unsent"; echoMessage.echo_msg_state = "messageUnSent"; } }); diff --git a/webclient/room/room.html b/webclient/room/room.html index 79a60585a5..a3f8aee7ab 100644 --- a/webclient/room/room.html +++ b/webclient/room/room.html @@ -68,7 +68,6 @@ ng-hide="state.permission_denied" ng-style="{ 'visibility': state.messages_visibility }" keep-scroll> - @@ -76,7 +75,7 @@
{{ msg.user_id | mUserDisplayName: room_id }}
- {{ (msg.content.hsob_ts || msg.ts) | date:'MMM d HH:mm' }} + {{ (msg.origin_server_ts) | date:'MMM d HH:mm' }}
-- cgit 1.4.1