mirror of
https://github.com/renbaoshuo/S2OJ.git
synced 2024-12-25 12:31:53 +00:00
fix(user_msg): cannot open new chat
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
da273d1df9
commit
bfa0cf8d3d
@ -205,9 +205,11 @@ if (isset($_POST['user_msg'])) {
|
||||
</script>
|
||||
|
||||
<script type="text/javascript">
|
||||
<?php $enter_user = UOJRequest::user(UOJRequest::GET, 'enter'); ?>
|
||||
var conversations = {};
|
||||
var intervalId = 0;
|
||||
var user_avatar = '<?= HTML::avatar_addr(Auth::user(), 80) ?>';
|
||||
var enter_user = ['<?= $enter_user['username'] ?>', '<?= UOJUser::getRealname($enter_user) ?>', '<?= UOJUser::getUserColor($enter_user) ?>'];
|
||||
|
||||
function formatDate(date) {
|
||||
var d = new Date(date),
|
||||
@ -309,7 +311,7 @@ if (isset($_POST['user_msg'])) {
|
||||
function refreshHistory(conversation, page) {
|
||||
$("#history-list").empty();
|
||||
var ret = false;
|
||||
$('#conversation-name').html(getUserLink(conversation, conversations[conversation][2], conversations[conversation][3]));
|
||||
$('#conversation-name').html(getUserLink(conversation, conversation == enter_user[0] ? enter_user[1] : conversations[conversation][2], conversation == enter_user[0] ? enter_user[2] : conversations[conversation][3]));
|
||||
$('#pageShow').text("第" + page.toString() + "页");
|
||||
$.get('/user_msg', {
|
||||
getHistory: '',
|
||||
|
Loading…
Reference in New Issue
Block a user