canvasboard icon indicating copy to clipboard operation
canvasboard copied to clipboard

File versions

Open goliakshay357 opened this issue 4 years ago • 1 comments

Is your feature request related to a problem? Please describe. It would be great if there are version history for every file save like google docs provide. It would help users to retrieve the old version back again quickly.

image Source: Google Docs

goliakshay357 avatar Dec 23 '20 02:12 goliakshay357

@goliakshay357 I can think of a simple method of making a file version-controlled. Consider the first 'save' of a file as the main record. Then, every time a user makes a 'save' action for this file, create a new entry in the database. This new entry should have a foreign key which would store the ID of 'main' record. Now, when fetching the file for rendering on front-end, make sure that the latest version is served. To check if a file is the latest version or not can be done based on the timestamp of the record (which could be set automatically). Of course, this method will eat a tremendous amount of disk space, as the system will be saving the same content again and again.

abdus avatar Jan 05 '21 11:01 abdus