Merge pull request #185 from ONLYOFFICE/feature/new-comments

New comments
This commit is contained in:
Sergey Linnik
2021-08-29 15:39:13 +03:00
committed by GitHub
25 changed files with 170 additions and 88 deletions

View File

@ -191,6 +191,7 @@
. "&userAddress=" . getClientIp();
}
// get url to the created file
function getCreateUrl($fileName, $uid, $type) {
$ext = trim(getInternalExtension($fileName),'.');
return serverPath(false) . '/'
@ -200,6 +201,7 @@
. "&type=" . $type;
}
// get url to download a file
function getDownloadUrl($fileName) {
return serverPath(TRUE) . '/'
. "webeditor-ajax.php"
@ -464,10 +466,11 @@
<?php if ($usersForMentions != null): ?>
// add mentions for not anonymous users
config.events['onRequestUsers'] = function () {
docEditor.setUsers({
docEditor.setUsers({ // set a list of users to mention in the comments
"users": <?php echo json_encode($usersForMentions) ?>
});
};
// the user is mentioned in a comment
config.events['onRequestSendNotify'] = function (event) {
var actionLink = JSON.stringify(event.data.actionLink);
console.log("onRequestSendNotify:");