<%@  page pageEncoding="utf-8" contentType="text/html;charset=utf-8" import="com.novell.webaccess.common.JSPConduit, com.novell.emframe.dev.eMFrameUtils" %>
<%   JSPConduit c = JSPConduit.getJSPConduit(request);
   c.stringTable("DevResources");
   c.stringTable("BaseResources"); %>
   <%@ taglib uri="/WEB-INF/iman.tld" prefix="iman" %>
   <%@ taglib uri="/WEB-INF/c.tld" prefix="c" %>
   <%@ taglib uri="/WEB-INF/x.tld" prefix="x" %>
<HTML>
<HEAD>
   <TITLE><%= c.string("ProductName") %></TITLE>

   <jsp:include page='<%= c.getPath("dev/XmlScripts_inc.jsp") %>' flush="true" />
   <iman:uihandlerTools/>
   <iman:pageScripts/>
   <iman:eMFrameScripts/>
   <iman:validateNumberScripts/>

   <LINK rel='stylesheet' href='<%= c.getModulesUrl() + "/dev/css/hf_style.css" %>'>
   <jsp:include page='<%= c.getPath("dev/PageScripts_inc.jsp") %>' flush="true" />
   <x:parse xml="${edas}" var="edasXml"/>
   <iman:mvedScripts mode="mvsel"/><%-- Always include for the description field --%>
   <c:if test="${DeviceType=='browser'}">
      <iman:mvedScripts mode="mvie"/>
   </c:if>   
   <SCRIPT language="JavaScript">
      function onInit()
      {
         var form=document.forms[0];
         <% if (c.var("Task.moo").equals("false")) { %>
            mvLoadFromPack("_CN", "<%= c.toScript(c.var("otherName")) %>");
         <% } %>
      }

      function isPageValid()
      {
         var form=document.forms[0];

         <% if (c.var("Task.moo").equals("false")) { %>
            form.otherName.value = mvGetValuesAsPack("_CN" );
         <% } %>

         return notifyAllOfExit();
      }
   </SCRIPT>
</HEAD>

<BODY onLoad="onInit();">
<FORM name="form" method=post action="webacc">
   <jsp:include page='<%= c.getPath("dev/Messagebar_inc.jsp") %>' flush="true" />
	<jsp:include page='<%= c.getPath("dev/BookVars_inc.jsp") %>' flush="true" />

   <!---- UI Created by UiHandlers ---->

      <TABLE class="mediumtext" border='0' bgcolor='#FFFFFF' cellpadding='0' cellspacing='0'>
         <!-- CN -->
         <% if (c.var("Task.moo").equals("false")) { %>
         <TR>
            <TD align=left>
               <%= c.string("otherName") %>:&nbsp;
            </TD>
            <% if (session.getAttribute("DeviceType").equals("pocket")) { %></TR><TR><% } %>
            <TD>
               <INPUT name='otherName' type=hidden value="<%= c.formatMessage(c.var("toHtml"), new String[]{(c.var("otherName"))}) %>">
               <% c.set("MVStringEditor_name", "_CN");
                  c.set("MVStringEditor_minLength", "1");
                  c.set("MVStringEditor_maxLength", "64");
                  c.set("MVStringEditor_ignoreCase", "true");
                  c.set("MVStringEditor_enforceUnique", "true");
                  if (!c.var("otherNameRights").equals("RW")) {    c.set("MVStringEditor_readonly", "true");    } %>
               <jsp:include page='<%= c.getPath("dev/MVStringEditor_inc.jsp") %>' flush="true" />
            </TD>
            <TD valign=top>
               <% if (c.var("Task.moo").equals("true")) {    c.set("ModeSelectorMV.name", "_CN_mode"); %>&nbsp;&nbsp;<jsp:include page='<%= c.getPath("dev/ModeSelectorMV_inc.jsp") %>' flush="true" /><% } %>
            </TD>
         </TR>
         <TR><TD height=9></TD></TR>
         <% } %>
      <!-- L -->
      <TR>
         <TD align=left>
            <%= c.var("LDisplayName") %>:&nbsp;
         </TD>
         <% if (session.getAttribute("DeviceType").equals("pocket")) { %></TR><TR><% } %>
         <TD>
            <INPUT name='eDir$target$L' type=hidden value="<%= c.formatMessage(c.var("toHtml"), new String[]{(c.var("eDir$target$L"))}) %>">
            <% c.set("MVStringEditor_name", "_L");
               c.set("MVStringEditor_xml", c.var("eDir$target$L"));
               c.set("MVStringEditor_minLength", "1");
               c.set("MVStringEditor_maxLength", "128");
               c.set("MVStringEditor_ignoreCase", "true");
               c.set("MVStringEditor_enforceUnique", "true");
               if (c.var("eDirRights$target$L").equals("R") || c.var("eDirRights$target$L").equals("NONE")) {    c.set("MVStringEditor_readonly", "true");    } %>
            <jsp:include page='<%= c.getPath("dev/MVStringEditor_inc.jsp") %>' flush="true" />
         </TD>
         <TD valign=top>
            <% if (c.var("Task.moo").equals("true")) {    c.set("ModeSelectorMV.name", "_L_mode"); %>&nbsp;&nbsp;<jsp:include page='<%= c.getPath("dev/ModeSelectorMV_inc.jsp") %>' flush="true" /><% } %>
         </TD>
      </TR>

      <TR><TD height=9></TD></TR>
      <!-- Facsimile Telephone Number -->
      <TR>
         <TD align=left>
            <%= c.var("Facsimile_Telephone_NumberDisplayName") %>:&nbsp;
         </TD>
         <% if (session.getAttribute("DeviceType").equals("pocket")) { %></TR><TR><% } %>
         <TD>
            <INPUT name='eDir$target$Facsimile_Telephone_Number' type=hidden value="<%= c.formatMessage(c.var("toHtml"), new String[]{(c.var("eDir$target$Facsimile_Telephone_Number"))}) %>">
            <% c.set("MVStringEditor_name", "_Facsimile_Telephone_Number");
               c.set("MVStringEditor_xml", c.var("eDir$target$Facsimile_Telephone_Number"));
               c.set("MVStringEditor_maxLength", "32");
               c.set("MVStringEditor_enforceUnique", "true");
               if (c.var("eDirRights$target$Facsimile_Telephone_Number").equals("R") || c.var("eDirRights$target$Facsimile_Telephone_Number").equals("NONE")) {    c.set("MVStringEditor_readonly", "true");    } %>
            <jsp:include page='<%= c.getPath("dev/MVStringEditor_inc.jsp") %>' flush="true" />
         </TD>
         <TD valign=top>
            <% if (c.var("Task.moo").equals("true")) {    c.set("ModeSelectorMV.name", "_Facsimile_Telephone_Number_mode"); %>&nbsp;&nbsp;<jsp:include page='<%= c.getPath("dev/ModeSelectorMV_inc.jsp") %>' flush="true" /><% } %>
         </TD>
      </TR>

      <TR><TD height=9></TD></TR>
      <!-- Telephone Number -->
      <TR>
         <TD align=left>
            <%= c.var("Telephone_NumberDisplayName") %>:&nbsp;
         </TD>
         <% if (session.getAttribute("DeviceType").equals("pocket")) { %></TR><TR><% } %>
         <TD>
            <INPUT name='eDir$target$Telephone_Number' type=hidden value="<%= c.formatMessage(c.var("toHtml"), new String[]{(c.var("eDir$target$Telephone_Number"))}) %>">
            <% c.set("MVStringEditor_name", "_Telephone_Number");
               c.set("MVStringEditor_xml", c.var("eDir$target$Telephone_Number"));
               c.set("MVStringEditor_maxLength", "32");
               c.set("MVStringEditor_enforceUnique", "true");
               if (c.var("eDirRights$target$Telephone_Number").equals("R") || c.var("eDirRights$target$Telephone_Number").equals("NONE")) {    c.set("MVStringEditor_readonly", "true");    } %>
            <jsp:include page='<%= c.getPath("dev/MVStringEditor_inc.jsp") %>' flush="true" />
         </TD>
         <TD valign=top>
            <% if (c.var("Task.moo").equals("true")) {    c.set("ModeSelectorMV.name", "_Telephone_Number_mode"); %>&nbsp;&nbsp;<jsp:include page='<%= c.getPath("dev/ModeSelectorMV_inc.jsp") %>' flush="true" /><% } %>
         </TD>
      </TR>

      <TR><TD height=9></TD></TR>
  <!-- Description -->
   <TR>
      <TD align=left>
         <c:out value="${DescriptionDisplayName}"/>:&nbsp;&nbsp;
      </TD>
      <c:if test="${DEVICE_TYPE=='pocket'}"></TR><TR></c:if>

      <TD>
         <c:if test="${edasRights.target.Description.writeable}">
            <INPUT type="hidden" name="eDir$target$Description" value="<c:out value="${eDir$target$Description}" escapeXml="false"/>" >
            <SCRIPT>addToNotificationList('Description', 'uih_mvStringEditor');</SCRIPT>
         </c:if>

         <x:set var="MVStringEditor_xmlNodeSet" select="$edasXml/edas/Description" scope="request"/>
         <c:set var="MVStringEditor_bigEditBox" value="true" scope="request"/>
         <iman:mved mode="mvsel" maxLength="1024" readonly="${!edasRights.target.Description.writeable}" enforceUnique="true" ignoreCase="true" minLength="1" name="_Description"/>
      </TD>
      <TD valign=top>
         <c:set var="mode"><x:out select="$edasXml/edas/Description/@mode"/></c:set>
         <iman:mooMode name="_Description_mode" value="${mode}" multi="true"/>
      </TD>
   </TR>

      <TR><TD height=9></TD></TR>
      </TABLE>


</FORM>
</BODY>
</HTML>

