diff --git a/src/core/js/webcaosdb.js b/src/core/js/webcaosdb.js index 03cc7bfbb399e898a88cb99dc0a05cc90289f96a..108c09b16e637db198337d745f9fd83b4d2589e0 100644 --- a/src/core/js/webcaosdb.js +++ b/src/core/js/webcaosdb.js @@ -990,6 +990,11 @@ var version_history = new function () { const logger = log.getLogger("version_history"); this.logger = logger; + this._has_version_fragment = function () { + const fragment = window.location.hash.substr(1); + return fragment === 'version_history'; + } + this._get = connection.get; /** * Retrieve the version history of an entity and return a table with the @@ -1161,6 +1166,11 @@ var version_history = new function () { this.init_load_history_buttons(); this.init_export_history_buttons(); this.init_restore_version_buttons(); + + // check for the version_history fragment and open the modal if present. + if (this._has_version_fragment()) { + logger.debug("Showing full version modal for first entity"); + } } } @@ -2000,4 +2010,4 @@ class _CaosDBModules { var caosdb_modules = new _CaosDBModules() -$(document).ready(initOnDocumentReady); \ No newline at end of file +$(document).ready(initOnDocumentReady);