Track File Download Action

Hello community,

 

Does Creatio offer a way to track the download of a document from the Attachment and Notes section.

i.e Every time the user clicks on the download attachment button the system saves an audit of this action eg the person who downloaded it, time etc.

 

Best regards

Like 0

Like

3 comments

It can be done with development. I'll outline the parts you'd need to create/change (but it's all untested so you'll need to fill in any gaps).

First, you'd need to create a custom configuration service, we'll say it is call UsrCustomFileService that has a function GetFile that takes two params string entitySchemaUId, string fileId. All the function needs to do is something like this: 

[OperationContract]
[WebGet(UriTemplate = "GetFile/{entitySchemaUId}/{fileId}")]
public Stream GetFile(string entitySchemaUId, string fileId) {
    // log the user and file for entitySchemaUId and fileId here
    // now return the file calling the out of the box file service, something like this: 
    var fileService = new FileService();
    return fileService.GetFile(entitySchemaUId, fileId);
}

Then, you'll need to replace the FileDetailV2 schema and override the getColumnLinkConfig function. You could copy the existing function. Basically, what you'd need to change is to take the result of Terrasoft.FileDownloader.getFileLink(this.entitySchema.uId, id) and replace in that string "FileService" with the name of your custom configuration service "UsrCustomFileService". 

Now, when a link is clicked, the link will call your custom configuration service, which can log the download, then return the file stream so the file downloads.

Ryan

Hello,



We have developed file download logging for Contact section. Single package ready for install, but not so ready as Marketplace solution yet. 



Send PM or email to vs@aviterra.lv if you are interested in



Kind regards,

Vladimir

Vladimir Sokolov,

 



Would love to see it as a marketplace solution - definitely has some useful application here :)

Show all comments