CADViewer Technical Documentation, Installation Guide and Reference Samples Library

Modal Setup

Redlines Modal Setup

The initialization method cvjs_setRedlinesAbsolutePath() controls the path to the file location, that links with the Redline File Loader and Save Modal.

/** 
 * @param {string} path - abslute URL to the redlines location
 * @param {string} serverPath - absolute path to the redlines location, "/home/cadviewerjs/redlines/"
 * @param {boolean} dynamicPathFlag - dynamic location for each input file, input file name and path concatenated to path. 
*/

cadviewer.cvjs_setRedlinesAbsolutePath(ServerBackEndUrl+'/content/redlines/v7/', ServerLocation+'/content/redlines/v7/',false);  // 

The /content/redlines/ path is already set up with all the back-end CADViewer Servers on our GitHub Repositories.

If user is controlling save/load through API controls for Load/Save , then the third parameter dynamicPathFlag can be useful, in that it set to true it will make a unique redline folder based on the filepath for each drawing, thereby making collaboration around a drawing by multiple users easy to manage. Default is true where all redlines are managed from the same default serverPath folder.

NOTE: If general initialization path ServerLocation is set to “”, the back-end converter will concatenate the redline serverPath to the back-end installation path.

Click on the method to open the API documentation.

Last updated on 5 Feb 2023
Published on 9 Apr 2020