protected void createTabModel() {
   if (tabModel == null) {
     AMViewConfig amconfig = AMViewConfig.getInstance();
     tabModel =
         amconfig.getTabsModel(
             ServerEditViewBeanBase.TAB_NAME, "/", getRequestContext().getRequest());
     registerChild(TAB_COMMON, CCTabs.class);
   }
 }
 protected void createTabModel(String serverName) {
   AMViewConfig amconfig = AMViewConfig.getInstance();
   tabModel =
       amconfig.getTabsModel(
           ServerEditViewBeanBase.TAB_NAME, "/", getRequestContext().getRequest());
   if (serverName.equals(ServerConfiguration.DEFAULT_SERVER_CONFIG)) {
     CCNavNode node = (CCNavNode) tabModel.getNodeById(425);
     tabModel.removeNode(node);
   }
   registerChild(TAB_COMMON, CCTabs.class);
 }
예제 #3
0
 /** Creates a mapping of the service name to the display name for the service. */
 private Map mapNameToDisplayName(Set names) {
   Map map = new HashMap(names.size() * 2);
   AMViewConfig vConfig = AMViewConfig.getInstance();
   for (Iterator iter = names.iterator(); iter.hasNext(); ) {
     String name = (String) iter.next();
     /*
      * Have a way to hide policies in console by adding some entries
      * to amConsoleConfig.xml
      */
     if (vConfig.isServiceVisible(name)) {
       String displayName = getLocalizedServiceName(name);
       if (!name.equals(displayName)) {
         map.put(name, displayName);
       }
     }
   }
   return map;
 }
  /**
   * Handles tab selected event.
   *
   * @param event Request Invocation Event.
   * @param nodeID Selected Node ID.
   */
  public void nodeClicked(RequestInvocationEvent event, int nodeID) {
    AMViewConfig amconfig = AMViewConfig.getInstance();

    try {
      AMViewBeanBase vb = getTabNodeAssociatedViewBean("cscGeneral", nodeID);
      unlockPageTrailForSwapping();
      passPgSessionMap(vb);
      vb.forwardTo(getRequestContext());
    } catch (AMConsoleException e) {
      debug.error("ServerEditGeneralViewBean.nodeClicked", e);
      forwardTo();
    }
  }