diff --git a/file/lib/data/chat/message/ChatMessage.class.php b/file/lib/data/chat/message/ChatMessage.class.php index 4731cac..3e8f2a1 100644 --- a/file/lib/data/chat/message/ChatMessage.class.php +++ b/file/lib/data/chat/message/ChatMessage.class.php @@ -94,9 +94,10 @@ public function jsonify() { return \wcf\util\JSON::encode(array( 'formattedUsername' => $this->getFormattedUsername(), 'formattedMessage' => $this->getFormattedMessage(), - 'time' => $this->time, + 'formattedTime' => \wcf\util\DateUtil::format(\wcf\util\DateUtil::getDateTimeByTimestamp($this->time), 'H:i:s'), 'sender' => $this->sender, 'username' => $this->getUsername(), + 'time' => $this->time, 'receiver' => $this->receiver, 'type' => $this->type )); diff --git a/template/chatMessage.tpl b/template/chatMessage.tpl index 18fa9af..8a8dcbb 100644 --- a/template/chatMessage.tpl +++ b/template/chatMessage.tpl @@ -1 +1 @@ -{literal}{@$time} {@$formattedUsername}{@$formattedMessage}{/literal} +{literal}{@$formattedTime} {@$formattedUsername}{@$formattedMessage}{/literal}