Setting up an iMIS 15 Home Page/Dashboard

Does anyone have a way to set up the home page/dashboard for iMIS 15?

I'm not sure how to get to it now that none of the Framework pages are available.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Here's how to do it

This is how to set up a custom home-page for iMIS 15.

By default the home page is the default.aspx file in

C:\Program Files\ASI\iMIS15\net\

If you have the Navigation Designer you can change this to another page, otherwise just edit this file directly. The page needs to have some minimal values - it must have a

<asp:Content ID="MainContent" ContentPlaceHolderID="TemplateBody" runat="server">

</asp:Content>

to know where to load the content, and some C# code to check if a user is logged in. The page below displays the contents of a second web site located on the same web server, with details of the currently logged on user being passed through to allow for personalisation.

Here is my new default.aspx page:

<%@ Page Language="C#" Inherits="Asi.Web.UI.DisplayPageBase" Title="iMIS - Welcome to the World of iMIS" %>

<script language="C#" runat="server">
    protected override void OnInit(EventArgs e)
    {
        base.OnInit(e);

        if (Request["hkey"] == null)
        {
            //Asi.Business.ContentManagement.Website website = Asi.Business.ContentManagement.WebsiteController.Website(new Guid("E28BB596-80D6-48CA-B241-09745C03FAC2"));
            string url = Asi.Web.Utilities.GetTildeExpansion() + "/Admin/imis15.web.Home/Default.aspx"; // +website.DefaultSectionURL + "Default.aspx";
            Response.Redirect(url, true);
        }
    }
    protected override void OnLoad(EventArgs e)
    {
        base.OnLoad(e);

        if (Asi.Security.AppPrincipal.CurrentPrincipal != null)
        {
            Asi.iBO.ContactManagement.CContact contact = new Asi.iBO.ContactManagement.CContact(Asi.ContentManagerNet.ContentManager.CMUser, ((Asi.Security.AppPrincipal)Asi.Security.AppPrincipal.CurrentPrincipal).AppIdentity.ContactMaster);
            // WelcomeMessage.Text = string.Format("Welcome to our Website, {0} {1} {2} !", contact.FirstName, contact.LastName, contact.ContactId.ToString());
            HomeFrame.Attributes["src"] = "http://localhost/HelloiMIS/NewHomePage.html?firstname=" + contact.FirstName + "&lastname=" + contact.LastName + "&ID=" + contact.ContactId;
            
        }
    }
</script>

<asp:Content ID="MainContent" ContentPlaceHolderID="TemplateBody" runat="server">

<!--     <asp:Label ID="WelcomeMessage" runat="Server">Welcome To Our Website!</asp:Label> -->
     <iframe frameborder="0" height="100%" id="HomeFrame" width="100%" runat="Server"></iframe> 

</asp:Content>

Here are the contents of the NewHomePage.html

<html>
<body>
<script language="JavaScript">
document.write("URL=" + location.href);
</script>
</body>
</html>

This is what is displayed for the user:
URL=http://localhost/HelloiMIS/NewHomePage.html?firstname=MANAGER&lastname=&ID=194

change homepage to be any web page

You can change your homepage (or any imis page for that matter) to be a webpage. Here is what we do to run iDashboards on the homepage - we simply change the src to be the new web page.

Change the line in the above comment:
HomeFrame.Attributes["src"] = "http://localhost/HelloiMIS/NewHomePage.html?firstname=" + contact.FirstName + "&lastname=" + contact.LastName + "&ID=" + contact.ContactId;

To

HomeFrame.Attributes["src"] = “http://localhost:6500/idashboards/”;

voila