diff --git a/resources/celerity/map.php b/resources/celerity/map.php index dabb6f1d5b..f7a1f391d0 100644 --- a/resources/celerity/map.php +++ b/resources/celerity/map.php @@ -392,7 +392,7 @@ return array( 'rsrc/js/application/diffusion/behavior-pull-lastmodified.js' => 'f01586dc', 'rsrc/js/application/doorkeeper/behavior-doorkeeper-tag.js' => '1db13e70', 'rsrc/js/application/drydock/drydock-live-operation-status.js' => '901935ef', - 'rsrc/js/application/files/behavior-document-engine.js' => 'd3f8623c', + 'rsrc/js/application/files/behavior-document-engine.js' => '194cbe53', 'rsrc/js/application/files/behavior-icon-composer.js' => '8499b6ab', 'rsrc/js/application/files/behavior-launch-icon-composer.js' => '48086888', 'rsrc/js/application/harbormaster/behavior-harbormaster-log.js' => '191b4909', @@ -607,7 +607,7 @@ return array( 'javelin-behavior-diffusion-jump-to' => '73d09eef', 'javelin-behavior-diffusion-locate-file' => '6d3e1947', 'javelin-behavior-diffusion-pull-lastmodified' => 'f01586dc', - 'javelin-behavior-document-engine' => 'd3f8623c', + 'javelin-behavior-document-engine' => '194cbe53', 'javelin-behavior-doorkeeper-tag' => '1db13e70', 'javelin-behavior-drydock-live-operation-status' => '901935ef', 'javelin-behavior-durable-column' => '2ae077e1', @@ -983,6 +983,11 @@ return array( '191b4909' => array( 'javelin-behavior', ), + '194cbe53' => array( + 'javelin-behavior', + 'javelin-dom', + 'javelin-stratcom', + ), '1ad0a787' => array( 'javelin-install', 'javelin-reactor', @@ -2002,11 +2007,6 @@ return array( 'd254d646' => array( 'javelin-util', ), - 'd3f8623c' => array( - 'javelin-behavior', - 'javelin-dom', - 'javelin-stratcom', - ), 'd4505101' => array( 'javelin-stratcom', 'javelin-install', diff --git a/webroot/rsrc/js/application/files/behavior-document-engine.js b/webroot/rsrc/js/application/files/behavior-document-engine.js index 4cb7d17723..3e49f35410 100644 --- a/webroot/rsrc/js/application/files/behavior-document-engine.js +++ b/webroot/rsrc/js/application/files/behavior-document-engine.js @@ -73,7 +73,6 @@ JX.behavior('document-engine', function(config, statics) { var handler = JX.bind(null, onrender, data, data.sequence); data.viewKey = spec.viewKey; - JX.History.replace(spec.viewURI); new JX.Request(spec.engineURI, handler) .send(); @@ -91,6 +90,10 @@ JX.behavior('document-engine', function(config, statics) { var load = JX.bind(null, onloading, data, spec); data.loadTimer = setTimeout(load, 333); + + // Replace the URI with the URI for the specific rendering the user + // has selected. + JX.History.replace(spec.viewURI); } } @@ -128,7 +131,7 @@ JX.behavior('document-engine', function(config, statics) { statics.initialized = true; } - if (config.renderControlID) { + if (config && config.renderControlID) { var control = JX.$(config.renderControlID); var data = JX.Stratcom.getData(control);