<%@ 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"%>

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

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

<%
  String close = request.getParameter("close");
%>

<script language="javascript">

function init() {
  var close = '<%=close%>';
  if (close == "true") {
    window.close();
  }
}

function submitValues() {
    // Form names.
    var tf = ccGetForm(setupForm);

    var isMonitor = tf.elements["DSPSetupInformation.MonitorValue"].value;
    var devName   = tf.elements["DSPSetupInformation.DeviceNameValue"].value;
    var devPasswd = tf.elements["DSPSetupInformation.PasswordValue"].value;

    tf.action = tf.action + "?" + "DSPSetupInformation.OKButton=&MonitorValue=" + isMonitor;
    tf.submit();

    // cannot close the window directly, this will be done in the init method
    // when the page is redisplayed.

}
</script>


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

<jato:form name="setupForm" method="post">

<cc:pagetitle 
  name="PageTitle" 
  bundleID="appBundle"
  pageTitleText="page.title.setupDevice" 
  showPageTitleSeparator="true"
  showPageButtonsTop="false"
  showPageButtonsBottom="true">

  <cc:propertysheet 
   name="SetupPropertySheet" 
   bundleID="appBundle" 
   showJumpLinks="false"
   addJavaScript="true" />

</cc:pagetitle>

</jato:form>
</sa:secondarymasthead>
</jato:useViewBean>

