Examples of KPIEditor


Examples of org.jboss.dashboard.ui.components.KPIEditor

        // Ensure that the UI editor & viewer see the KPI
        passKPItoUI(kpi);
    }

    protected void passKPItoUI(KPI kpi) {
        KPIEditor kpiEditor = KPIEditor.lookup();
        KPIViewer kpiViewer = KPIViewer.lookup();
        if (kpiEditor.getKpi() == null) kpiEditor.setKpi(kpi);
        if (kpiViewer.getKpi() == null) kpiViewer.setKpi(kpi);
    }
View Full Code Here

Examples of org.jboss.dashboard.ui.components.KPIEditor

    /**
     * Save changes on the KPI being edited.
     */
    public void actionSubmit(Panel panel, CommandRequest request) throws Exception {
        KPIEditor kpiEditor = KPIEditor.lookup();
        kpiEditor.actionSubmit(request);

        // Make the panel instance's description match the KPI description.
        String lang = LocaleManager.currentLang();
        String kpiDescr = request.getRequestObject().getParameter(KPIEditor.PARAM_KPI_DESCRIPTION);
        if (!StringUtils.isBlank(kpiDescr)) panel.getInstance().setTitle(kpiDescr, lang);

        // Make changes persistent.
        KPI kpi = kpiEditor.getKpi();
        kpi.save();

        // Ensure that the UI editor & viewer see the KPI changes
        passKPItoUI(kpi);
    }
View Full Code Here

Examples of org.jboss.dashboard.ui.components.KPIEditor

        // Ensure that the UI editor & viewer see the KPI
        passKPItoUI(kpi);
    }

    protected void passKPItoUI(KPI kpi) {
        KPIEditor kpiEditor = UIBeanLocator.lookup().getEditor();
        KPIViewer kpiViewer = UIBeanLocator.lookup().getViewer();
        if (kpiEditor.getKpi() == null) kpiEditor.setKpi(kpi);
        if (kpiViewer.getKpi() == null) kpiViewer.setKpi(kpi);
    }
View Full Code Here

Examples of org.jboss.dashboard.ui.components.KPIEditor

    /**
     * Save changes on the KPI being edited.
     */
    public void actionSubmit(Panel panel, CommandRequest request) throws Exception {
        KPIEditor kpiEditor = UIBeanLocator.lookup().getEditor();
        kpiEditor.actionSubmit(request);

        // Make the panel instance's description match the KPI description.
        String lang = LocaleManager.currentLang();
        String kpiDescr = request.getRequestObject().getParameter(KPIEditor.PARAM_KPI_DESCRIPTION);
        if (!StringUtils.isBlank(kpiDescr)) panel.getInstance().setTitle(kpiDescr, lang);

        // Make changes persistent.
        KPI kpi = kpiEditor.getKpi();
        kpi.save();

        // Ensure that the UI editor & viewer see the KPI changes
        passKPItoUI(kpi);
    }
View Full Code Here

Examples of org.jboss.dashboard.ui.components.KPIEditor

        // Save the relationship between the panel and the KPI.
        panel.getInstance().setParameterValue(Dashboard.KPI_CODE, kpi.getCode());

        // Go to edit mode.
        KPIEditor kpiEditor = UIBeanLocator.lookup().getEditor(kpi);
        kpiEditor.setKpi(kpi);
        return panelActionEditMode(panel, request);
    }
View Full Code Here

Examples of org.jboss.dashboard.ui.components.KPIEditor

    /**
     * Save changes on the KPI being edited.
     */
    public void actionSubmit(Panel panel, CommandRequest request) throws Exception {
        KPI kpi = getKPI(panel);
        KPIEditor kpiEditor = UIBeanLocator.lookup().getEditor(kpi);
        kpiEditor.actionSubmit(request);

        // Make the panel instance's description match the KPI description.
        String lang = LocaleManager.currentLang();
        String kpiDescr = request.getRequestObject().getParameter(KPIEditor.PARAM_KPI_DESCRIPTION);
        if (kpiDescr != null) panel.getInstance().setTitle(kpiDescr, lang);
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.