<%--
  @(#)TakeSnapshot.jsp	1.1 03/07/16
   Copyright (c) 2003 by Sun Microsystems, Inc. All rights reserved.
--%>
<%@ page language="java" %>
<%@taglib uri="/WEB-INF/tld/com_iplanet_jato/jato.tld" prefix="jato"%>
<%@taglib uri="/WEB-INF/tld/com_sun_web_ui/cc.tld" prefix="cc"%>
<%@taglib uri="/WEB-INF/lib/sa.tld" prefix="sa"%>
<%@taglib uri="/WEB-INF/lib/progress.tld" prefix="progress"%>

<jato:useViewBean
    className="com.sun.netstorage.mgmt.fm.storade.ui.viewbeans.reports.AnalyzeInventoryViewBean">

<!-- Masthead -->
<sa:secondarymasthead name="SecondaryMasthead" bodyExtraHtml="onload='init()'">

<jato:form name="form" method="post" defaultCommandChild="Submit">

<script type="text/javascript" src="/com_sun_web_ui/js/dynamic.js"></script>

<script language="javascript">
// initialize the display
function init() {
  var flag = ccGetElement("AnalyzeInventory.Refresh", "form");
  if (flag.value == "true") {
    setTimeout("refresh()", 10000);
  }
  if (flag.value != "true") {
    // refresh the parent's window. (in case alarms or inventory have been updated).
    // Make sure the name of the form match
    var pf = window.opener.document.rackForm;
    pf.action = pf.action + "?" + "Rack.ResetButton=";
    pf.submit();
  }
  var checkbox = ccGetElement("AnalyzeInventory.Checkbox", "form");
  if ((flag.value != "true") && (checkbox.checked)) {
    // check if we should close the window.
    window.close();
  }
}

// refresh the display
function refresh() {
  var f = ccGetForm("form");
  f.submit();
}
</script>

<!-- Page Title -->
<cc:pagetitle name="PageTitle" bundleID="appBundle"
    pageTitleText="page.title.analyzeInventory"
    showPageTitleSeparator="true"
    showPageButtonsTop="false"
    showPageButtonsBottom="true">

<!-- Search-for text input area -->
<table border=0 cellpadding=0 cellspacing=10>
<tr><td>

<cc:spacer name="Spacer" height="10" newline="true"/>

<cc:text name="StaticText" bundleID="appBundle" defaultValue="analyzeInventory.staticText"/>

<cc:spacer name="Spacer" height="10" newline="true"/>

<!-- Progress Bar -->
<progress:progressbar name="ProgressBar" bundleID="appBundle" type="basic" defaultValue="0"/>

<cc:spacer name="Spacer" height="10" newline="true"/>

<cc:text name="ProgressText" bundleID="appBundle" defaultValue="analyzeInventory.progressText"/>

<cc:spacer name="Spacer" height="10" newline="true"/>

<!-- Close checkbox -->
<cc:checkbox name="Checkbox" bundleID="appBundle" label="progressbar.basic.closeUponComplete"/>

</td></tr>
</table>

<cc:hidden name="Refresh" defaultValue="true"/>

</cc:pagetitle>

</jato:form>

</sa:secondarymasthead>

</jato:useViewBean>

