This commit is contained in:
Roman Kelesidis 2024-01-10 11:11:22 +07:00
parent 1eb2652963
commit c5e1dacc53
2 changed files with 4 additions and 4 deletions

View File

@ -86,7 +86,7 @@ switch ($mode)
$this->response['val']['tpl-last-edit-tst'] = $tpl_data['tpl_last_edit_tm']; $this->response['val']['tpl-last-edit-tst'] = $tpl_data['tpl_last_edit_tm'];
$this->response['html']['tpl-name-old-save'] = $tpl_data['tpl_name']; $this->response['html']['tpl-name-old-save'] = $tpl_data['tpl_name'];
$this->response['html']['tpl-last-edit-time'] = bb_date($tpl_data['tpl_last_edit_tm'], 'd-M-y H:i'); $this->response['html']['tpl-last-edit-time'] = bb_date($tpl_data['tpl_last_edit_tm'], 'd-M-y H:i');
$this->response['html']['tpl-last-edit-by'] = get_username(intval($tpl_data['tpl_last_edit_by'])); $this->response['html']['tpl-last-edit-by'] = profile_url(get_userdata(intval($tpl_data['tpl_last_edit_by'])));
$this->response['tpl_rules_href'] = POST_URL . $tpl_data['tpl_rules_post_id'] .'#'. $tpl_data['tpl_rules_post_id']; $this->response['tpl_rules_href'] = POST_URL . $tpl_data['tpl_rules_post_id'] .'#'. $tpl_data['tpl_rules_post_id'];
break; break;
@ -130,7 +130,7 @@ switch ($mode)
{ {
$last_edit_by_username = get_username(intval($tpl_data['tpl_last_edit_by'])); $last_edit_by_username = get_username(intval($tpl_data['tpl_last_edit_by']));
$msg = "Изменения не были сохранены!\n\n"; $msg = "Изменения не были сохранены!\n\n";
$msg .= 'Шаблон был отредактирован: '. html_entity_decode($last_edit_by_username) .', '. delta_time($tpl_data['tpl_last_edit_tm']) ." назад\n\n"; $msg .= 'Шаблон был отредактирован: '. html_entity_decode($last_edit_by_username) .', '. delta_time($tpl_data['tpl_last_edit_tm'], 'd-M-y H:i') ." назад\n\n";
$this->ajax_die($msg); $this->ajax_die($msg);
} }
$sql = "UPDATE ". BB_TOPIC_TPL ." SET ". DB()->build_array('UPDATE', $sql_args) ." WHERE tpl_id = $tpl_id LIMIT 1"; $sql = "UPDATE ". BB_TOPIC_TPL ." SET ". DB()->build_array('UPDATE', $sql_args) ." WHERE tpl_id = $tpl_id LIMIT 1";

View File

@ -73,7 +73,7 @@ if ($edit_tpl_mode)
'TPL_COMMENT' => $tpl_data['tpl_comment'], 'TPL_COMMENT' => $tpl_data['tpl_comment'],
'TPL_RULES_POST_ID' => $tpl_data['tpl_rules_post_id'], 'TPL_RULES_POST_ID' => $tpl_data['tpl_rules_post_id'],
'TPL_LAST_EDIT_TIME' => bb_date($tpl_data['tpl_last_edit_tm'], 'd-M-y H:i'), 'TPL_LAST_EDIT_TIME' => bb_date($tpl_data['tpl_last_edit_tm'], 'd-M-y H:i'),
'TPL_LAST_EDIT_USER' => get_username(intval($tpl_data['tpl_last_edit_by'])), 'TPL_LAST_EDIT_USER' => profile_url(get_userdata(intval($tpl_data['tpl_last_edit_by']))),
'TPL_LAST_EDIT_TIMESTAMP' => $tpl_data['tpl_last_edit_tm'], 'TPL_LAST_EDIT_TIMESTAMP' => $tpl_data['tpl_last_edit_tm'],
)); ));
} }