Examples of PanelStack


Examples of org.opencustomer.framework.webapp.panel.PanelStack

            log.debug("delete list configuration (ID:" + listConfiguration.getId() + ")");

        try {
            new ListConfigurationDAO().delete(listConfiguration);
           
            PanelStack stack = Panel.getPanelStack(request);
            if(stack.getSize() > 2) {
                Panel lastPanel = stack.peek(3);
                lastPanel.removeAttribute("listConfigurations");
                lastPanel.removeAttribute("choosenList");
                lastPanel.removeAttribute(ListAction.TABLE_KEY);
            }
           
View Full Code Here

Examples of org.opencustomer.framework.webapp.panel.PanelStack

                dao.update(listConfiguration);
            }
           
            HibernateContext.commitTransaction();
           
            PanelStack stack = Panel.getPanelStack(request);
            if(stack.getSize() > 1) {
                Panel lastPanel = stack.peek(2);
                lastPanel.removeAttribute("listConfigurations");
                lastPanel.removeAttribute(ListAction.TABLE_KEY);
            }
        } catch (HibernateException e) {
            log.error("problems saving list configuration", e);
View Full Code Here

Examples of org.opencustomer.framework.webapp.panel.PanelStack

    protected ActionForward getActionForward(ActionMapping mapping, HttpServletRequest request, HttpServletResponse response)
    {
        if(request.getAttribute(Globals.JUMP_KEY) != null) {
            JumpBean jump = (JumpBean)request.getAttribute(Globals.JUMP_KEY);
           
            PanelStack panelStack = Panel.getPanelStack(request);
            if(panelStack.peek(2).getType().equals(Panel.Type.EDIT)) {
                EditPanel panel = (EditPanel)panelStack.peek(2);
               
                return Panel.getForward(panel.getAction(Action.Type.SAVE).getAction(), request);
            } else if(panelStack.peek(2).getType().equals(Panel.Type.LIST)) {
               
                return jump.getForward();
            }
           
        }

       
        if(request.getAttribute("external_person_id") != null
                || request.getAttribute("external_company_id") != null)
        {
            PanelStack panelStack = Panel.getPanelStack(request);
           
            EditPanel panel = (EditPanel)panelStack.peek(2);
           
            return Panel.getForward(panel.getAction(Action.Type.SAVE).getAction(), request);
        }
        else
            return null;
View Full Code Here

Examples of org.opencustomer.framework.webapp.panel.PanelStack

                || request.getAttribute("external_company_id") != null)
        {
            if(log.isDebugEnabled())
                log.debug("will jump ... got to save parent panel (person:"+request.getAttribute("external_person_id")+"/company:"+request.getAttribute("external_company_id")+")");
           
            PanelStack panelStack = Panel.getPanelStack(request);
           
            EditPanel panel = (EditPanel)panelStack.peek(2);
           
            return Panel.getForward(panel.getAction(Action.Type.SAVE).getAction(), request);
        }
        else
            return null;
View Full Code Here

Examples of org.opencustomer.framework.webapp.panel.PanelStack

            }
            else if(log.isDebugEnabled())
                log.debug("activate item: "+menuItem);
           
            // do always delete the stack when click the menu
            PanelStack panelStack = Panel.getPanelStack(request);
            panelStack.clear();
           
            return Panel.getForward(menuItem.getAction(), request);
        }
       
        return mapping.findForward("login");
View Full Code Here

Examples of org.opencustomer.framework.webapp.panel.PanelStack

        attributes.put("listConfiguration", listConfiguration);
    }
   
    @Override
    public void preOperation(ActionMessages errors, LoadForm form, Hashtable<String, Object> attributes, HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException {
        PanelStack stack = Panel.getPanelStack(request);
        if(!stack.isEmpty()) {
            Panel lastPanel = Panel.getPanelStack(request).peek();
            if(lastPanel.getAttribute(ListAction.TABLE_KEY) != null) {
                Table table = (Table)lastPanel.getAttribute(ListAction.TABLE_KEY);
                ListConfigurationVO.Type type = null;
                for(ListConfigurationVO.Type existingType : ListConfigurationVO.Type.values()) {
View Full Code Here

Examples of org.opencustomer.framework.webapp.panel.PanelStack

        panel.setEditable(isEditable(panel, request));
       
        if(!validateAccess(request, panel))
            errors.add(ActionMessages.GLOBAL_MESSAGE, new ActionMessage("default.error.invalidEntity", panel.getEntity().getId()));
       
        PanelStack panelStack = Panel.getPanelStack(request);
        panelStack.push(panel);
       
        if(!errors.isEmpty())
        {
            this.saveErrors(request, errors);
           
View Full Code Here

Examples of org.opencustomer.framework.webapp.panel.PanelStack

            if(removePanel)
            {
                if(log.isDebugEnabled())
                    log.debug("leave panel with action > pop stack");
                   
                PanelStack panelStack = Panel.getPanelStack(request);
                panelStack.pop();
            }
           
            // fix backbutton problem of browser
            ActionConfig actionConfig = mapping.getModuleConfig().findActionConfig(panel.getActivePage().getAction());
            if(!this.isTokenValid(request) && !actionConfig.getInput().equals(mapping.getInput())) {
View Full Code Here

Examples of org.opencustomer.framework.webapp.panel.PanelStack

   
    private final static SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HHmm");
   
    @Override
    protected StreamInfo getStreamInfo(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) throws Exception {
        PanelStack stack = Panel.getPanelStack(request);
       
        CvsStreamInfo streamInfo = new CvsStreamInfo();
       
        if(stack.isEmpty() || stack.peek().getAttribute(DynamicListAction.TABLE_KEY) == null) {
            throw new IllegalArgumentException("no panel or table found");
        } else {
            Table table = (Table)stack.peek().getAttribute(DynamicListAction.TABLE_KEY);
            table.query(true);
           
            ArrayList<String> header = new ArrayList<String>();
            for(Column column : table.getColumns()) {
                header.add(removeHTML(MessageUtil.message(request, column.getMessageKey())));
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.