Skip to content

Instantly share code, notes, and snippets.

@bseddon
Last active October 21, 2022 09:07
Show Gist options
  • Save bseddon/8c79b0cec790948b0d362c404e4874ad to your computer and use it in GitHub Desktop.
Save bseddon/8c79b0cec790948b0d362c404e4874ad to your computer and use it in GitHub Desktop.
Dundas BI pages structure

The listing below provides a canonical view of a page generated by Dundas BI. The structure of the page is the same whether it's for a frontend view or an administrator. The difference is the latter has extra files for JavaScript, CSS and localization.

The listing uses comments to describe the various sections that will appear and example tags where relevant.

There is nothing unusual about the structure used which is similar to that found in any web-based application.

From a the point of view of understanding how backend features translate into web page content, the interesting things are how items from the settings uun Setup -> app styling -> CssStyleOverride (and others like HTML Override) appear in the page content.

Note that the amount of code in the global overrides is not going to haveany material impact on the speed of page rendering for two reasons. The first is that they are static. That is, once they are read, the browser will cache the content until either the cache is removed (eg ctrl-f5) or the global script urls change. The other is that Dundas BI downloads A LOT of data dynamically. This is the live data that is to be rendered and there's not much to be done about it, it far exceeds the size of the global scripts and because its dynamic is downloaded every time a page is rendered.

<html>

	<!-- The head is the normal place scripts and styles are loaded as head creates no objects in the window -->
	<head>

		<!-- Bunch of meta tags like this... -->
		<meta name="application-name" content="Dundas BI">

		<!-- A title... -->
		<title>Admin - Application Styling</title>

		<!-- Bunch of link tags to pre-load images like this... -->
		<link rel="shortcut icon" href="https://<server>/<instance>/Content/Images/favicon/favicon.png">


		<!-- Bunch of link tags to load built-in style sheets like this... -->
		<link rel="stylesheet" href="./Admin - Application Styling_files/reset.cssbunch.min.css">

		<!-- Bunch of script tags to load built-in JavaScript files like this... -->
		<script src="./Admin - Application Styling_files/extrasstrict.min.js.download"></script>
		
		<!-- Make sure the browser is supported or redirect -->
		<script type="text/javascript">
			var isIE10 = BrowserDetect.browser == 'Explorer' && BrowserDetect.version <= 10;
			if (!(!!document.createElement('canvas').getContext)
				|| isIE10) {

				if (window.location.pathname.indexOf("Error/UnsupportedBrowser") == -1) {
					window.location = "/<instance>/" + "Error/UnsupportedBrowser/";
				}
			}
		</script>

		<!-- Bunch of script tags to load JSON conguration files like this... -->
		<script type="text/javascript" src="./Admin - Application Styling_files/GetUILocalizationJavaScript"></script>

		<!-- This script tag downloads a set of JS function that CAN BE replaced wioth global overrides (eg the PDF and Excel exports) ) -->
		<script type="text/javascript" src="./Admin - Application Styling_files/GetAllAdapterInfoResources"></script>

		<!-- Download style information.  At the moment for trumbowyg which is the content editor used by Dundas -->
		<link rel="stylesheet" type="text/css" href="./Admin - Application Styling_files/GetAllAdapterInfoResources(1)">

		<script type="text/javascript">
			dundas.constants.CONTEXT_URL_PATH = "/dInstance/";
			window._currentRequestUrl = "https\u003a\u002f\u002ffws\u002ddev\u002denv\u002d\u0031\u0033\u002ecom\u002fAdmin\u002fApplicationStyling";
			window._currentSessionId = "33d2ba08-108b-47b7-a5f8-9664631b342f";

			window._logonNotificationMessage = "This software is for internal development and testing purposes only. Any other use of the software is strictly prohibited.";

		</script>

		<!-- Bunch of link and script tags to admin specific CSS and JS files like this... -->    
		<script src="./Admin - Application Styling_files/admin.min.js.download"></script>

		<!-- The script from the pane when Dundas BI admin and selecting Setup -> app styling -> JS override -->
		<script type="text/javascript" src="./Admin - Application Styling_files/GetBuiltInResource"></script>

		<!-- The script from the pane when Dundas BI admin and selecting Setup -> app styling -> CssStyleOverride -->
		<link rel="stylesheet" type="text/css" href="./Admin - Application Styling_files/GetBuiltInResource(1)">

		<!-- Load of admin specific data grid styling -->
		<style></style>

	</head>

	<!-- in the body is where visual elements are created either by the application or by its scripts -->
    <body>
    
	<!--  This is where the visual html elements like <div> go -->

	<!-- The script from the pane when Dundas BI admin and selecting Setup -> app styling -> HTMLOverride -->
	<script src="./Admin - Application Styling_files/FWSGlobal_ParameterMatchup.js.download"></script>

	<!-- tooltip and close button stuff here -->

	</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment