Search in sources :

Example 6 with Caption

use of org.zkoss.zul.Caption in project adempiere by adempiere.

the class WAccountDialog method init.

/**
	 *	Static component init.
	 *  <pre>
	 *  - north
	 *    - parameterPanel
	 *    - toolBar
	 *  - center
	 *    - adtabpanel
	 *  - south
	 *    - confirmPanel
	 *    - statusBar
	 *  </pre>
	 *  @throws Exception
	 */
void init() throws Exception {
    //
    Caption caption = new Caption(Msg.getMsg(Env.getCtx(), "Parameter"));
    parameterPanel.appendChild(caption);
    parameterPanel.setStyle("background-color: transparent;");
    toolBar.setOrient("vertical");
    toolBar.setStyle("border: none; margin: 5px");
    bSave.setImage(ServletFns.resolveThemeURL("~./images/Save24.png"));
    bSave.setTooltiptext(Msg.getMsg(Env.getCtx(), "AccountNewUpdate"));
    bSave.addEventListener(Events.ON_CLICK, this);
    bRefresh.setImage(ServletFns.resolveThemeURL("~./images/Refresh24.png"));
    bRefresh.setTooltiptext(Msg.getMsg(Env.getCtx(), "Refresh"));
    bRefresh.addEventListener(Events.ON_CLICK, this);
    bIgnore.setImage(ServletFns.resolveThemeURL("~./images/Ignore24.png"));
    bIgnore.setTooltiptext(Msg.getMsg(Env.getCtx(), "Ignore"));
    bIgnore.addEventListener(Events.ON_CLICK, this);
    //
    toolBar.appendChild(bRefresh);
    toolBar.appendChild(bIgnore);
    toolBar.appendChild(bSave);
    //
    northPanel.appendChild(parameterPanel);
    parameterPanel.setWidth("95%");
    northPanel.appendChild(toolBar);
    northPanel.setWidth("100%");
    m_adTabPanel = new ADTabPanel();
    Borderlayout layout = new Borderlayout();
    layout.setParent(this);
    if (AEnv.isFirefox2()) {
        layout.setHeight("93%");
        layout.setWidth("98%");
        layout.setStyle("background-color: transparent; position: absolute;");
        this.setStyle("position: relative;");
    } else {
        layout.setHeight("100%");
        layout.setWidth("100%");
        layout.setStyle("background-color: transparent;");
    }
    North nRegion = new North();
    nRegion.setParent(layout);
    nRegion.setHflex("false");
    nRegion.setVflex("false");
    nRegion.appendChild(northPanel);
    nRegion.setStyle("background-color: transparent; border: none");
    northPanel.setStyle("background-color: transparent;");
    Center cRegion = new Center();
    cRegion.setParent(layout);
    cRegion.appendChild(m_adTabPanel);
    cRegion.setHflex("true");
    cRegion.setVflex("true");
    South sRegion = new South();
    sRegion.setParent(layout);
    Div div = new Div();
    div.appendChild(confirmPanel);
    confirmPanel.setStyle("margin-top: 5px; margin-bottom: 5px");
    div.appendChild(statusBar);
    sRegion.appendChild(div);
    sRegion.setStyle("background-color: transparent; border: none");
    confirmPanel.addActionListener(Events.ON_CLICK, this);
    this.setBorder("normal");
    this.setClosable(false);
    this.setAttribute("modal", Boolean.TRUE);
    this.setSizable(true);
}
Also used : ADTabPanel(org.adempiere.webui.panel.ADTabPanel) Div(org.zkoss.zul.Div) Center(org.zkoss.zul.Center) South(org.zkoss.zul.South) North(org.zkoss.zul.North) Borderlayout(org.zkoss.zul.Borderlayout) Caption(org.zkoss.zul.Caption)

Example 7 with Caption

use of org.zkoss.zul.Caption in project adempiere by adempiere.

the class WBOMDrop method createSelectionPanel.

//	dispose
/**************************************************************************
	 * 	Create Selection Panel
	 *	@param order
	 *	@param invoice
	 *	@param project
	 */
private void createSelectionPanel(boolean order, boolean invoice, boolean project) {
    Caption caption = new Caption(Msg.translate(Env.getCtx(), "Selection"));
    //		grpSelectionPanel.setWidth("100%");
    grpSelectionPanel.appendChild(caption);
    grpSelectionPanel.appendChild(selectionPanel);
    productField.setRows(1);
    productField.setMold("select");
    KeyNamePair[] keyNamePair = getProducts();
    for (int i = 0; i < keyNamePair.length; i++) {
        productField.addItem(keyNamePair[i]);
    }
    Rows rows = selectionPanel.newRows();
    Row boxProductQty = rows.newRow();
    Label lblProduct = new Label(Msg.translate(Env.getCtx(), "M_Product_ID"));
    Label lblQty = new Label(Msg.translate(Env.getCtx(), "Qty"));
    productQty.setValue(new BigDecimal(1));
    productField.addEventListener(Events.ON_SELECT, this);
    productQty.addEventListener(Events.ON_CHANGE, this);
    productField.setWidth("99%");
    boxProductQty.appendChild(lblProduct.rightAlign());
    boxProductQty.appendChild(productField);
    boxProductQty.appendChild(lblQty.rightAlign());
    boxProductQty.appendChild(productQty);
    if (order) {
        keyNamePair = getOrders();
        orderField.setRows(1);
        orderField.setMold("select");
        orderField.setWidth("99%");
        for (int i = 0; i < keyNamePair.length; i++) {
            orderField.addItem(keyNamePair[i]);
        }
        Label lblOrder = new Label(Msg.translate(Env.getCtx(), "C_Order_ID"));
        Row boxOrder = rows.newRow();
        orderField.addEventListener(Events.ON_CLICK, this);
        boxOrder.appendChild(lblOrder.rightAlign());
        boxOrder.appendChild(orderField);
        boxOrder.appendChild(new Space());
        boxOrder.appendChild(new Space());
    }
    if (invoice) {
        invoiceField.setRows(1);
        invoiceField.setMold("select");
        invoiceField.setWidth("99%");
        keyNamePair = getInvoices();
        for (int i = 0; i < keyNamePair.length; i++) {
            invoiceField.addItem(keyNamePair[i]);
        }
        Label lblInvoice = new Label(Msg.translate(Env.getCtx(), "C_Invoice_ID"));
        Row boxInvoices = rows.newRow();
        invoiceField.addEventListener(Events.ON_SELECT, this);
        boxInvoices.appendChild(lblInvoice.rightAlign());
        boxInvoices.appendChild(invoiceField);
        boxInvoices.appendChild(new Space());
        boxInvoices.appendChild(new Space());
    }
    if (project) {
        projectField.setRows(1);
        projectField.setMold("select");
        projectField.setWidth("99%");
        keyNamePair = getProjects();
        for (int i = 0; i < keyNamePair.length; i++) {
            projectField.addItem(keyNamePair[i]);
        }
        Label lblProject = new Label(Msg.translate(Env.getCtx(), "C_Project_ID"));
        Row boxProject = rows.newRow();
        projectField.addEventListener(Events.ON_SELECT, this);
        boxProject.appendChild(lblProject.rightAlign());
        boxProject.appendChild(projectField);
        boxProject.appendChild(new Space());
        boxProject.appendChild(new Space());
    }
    //	Enabled in ActionPerformed
    confirmPanel.setEnabled("Ok", false);
}
Also used : Space(org.zkoss.zul.Space) Label(org.adempiere.webui.component.Label) KeyNamePair(org.compiere.util.KeyNamePair) Row(org.adempiere.webui.component.Row) Caption(org.zkoss.zul.Caption) BigDecimal(java.math.BigDecimal) Rows(org.adempiere.webui.component.Rows)

Example 8 with Caption

use of org.zkoss.zul.Caption in project adempiere by adempiere.

the class WAcctViewer method init.

// AcctViewer
/**
	 *  Static Init.
	 *  <pre>
	 *  - mainPanel
	 *      - tabbedPane
	 *          - query
	 *          - result
	 *          - graphPanel
	 *  </pre>
	 *  @throws Exception
	 */
private void init() throws Exception {
    ThemeUtils.addSclass("ad-wacctviewer", this);
    // Modal or non-modal
    if (isLookup()) {
        ThemeUtils.addSclass("modal", this);
        setTitle(Msg.getMsg(Env.getCtx(), "Posting"));
        setAttribute(Window.MODE_KEY, Window.MODE_MODAL);
        setClosable(true);
        setSizable(true);
        setMaximizable(true);
    // Move to theme
    //setBorder("normal");
    //int height = SessionManager.getAppDesktop().getClientInfo().desktopHeight * 85 / 100;
    //int width = SessionManager.getAppDesktop().getClientInfo().desktopWidth * 80 / 100;
    //setWidth(width + "px");
    //setHeight(height + "px");
    //setContentStyle("overflow: auto");
    } else {
        ThemeUtils.addSclass("embedded", this);
        setTitle(Msg.getMsg(Env.getCtx(), "InfoAccount"));
        setAttribute(Window.MODE_KEY, Window.MODE_EMBEDDED);
    // Move to theme
    //setBorder("none");
    //setWidth("100%");
    //setHeight("100%");
    //setStyle("position: absolute");
    }
    // Selection Panel
    // Accounting Schema
    Hbox boxAcctSchema = new Hbox();
    ThemeUtils.addSclass("selection-box", boxAcctSchema);
    ThemeUtils.addSclass("acct-schema", boxAcctSchema);
    boxAcctSchema.setHflex("1");
    // boxAcctSchema.setWidths("30%, 70%");
    lacctSchema.setValue(Msg.translate(Env.getCtx(), "C_AcctSchema_ID"));
    lacctSchema.setAttribute("zk_component_ID", "Lookup_Criteria_Label_C_AcctSchema_ID");
    selAcctSchema.setMold("select");
    selAcctSchema.setRows(1);
    selAcctSchema.setAttribute("zk_component_ID", "Lookup_Criteria_C_AcctSchema_ID");
    Cell cell = new Cell();
    cell.appendChild(lacctSchema);
    ThemeUtils.addSclass("label-cell", cell);
    boxAcctSchema.appendChild(cell);
    cell = new Cell();
    cell.appendChild(selAcctSchema);
    ThemeUtils.addSclass("field-cell", cell);
    boxAcctSchema.appendChild(cell);
    Hbox boxSelDoc = new Hbox();
    ThemeUtils.addSclass("selection-box", boxSelDoc);
    ThemeUtils.addSclass("select-document", boxSelDoc);
    boxSelDoc.setHflex("1");
    //boxSelDoc.setWidths("30%, 50%, 20%");
    selDocument.setLabel(Msg.getMsg(Env.getCtx(), "SelectDocument"));
    selDocument.setAttribute("zk_component_ID", "Lookup_Criteria_selDocument");
    selDocument.addEventListener(Events.ON_CHECK, this);
    selTable.setMold("select");
    selTable.setRows(1);
    selTable.setAttribute("zk_component_ID", "Lookup_Criteria_selTable");
    selRecord.setAttribute("zk_component_ID", "Lookup_Criteria_selRecord");
    cell = new Cell();
    cell.appendChild(selDocument);
    ThemeUtils.addSclass("doc-cell", cell);
    boxSelDoc.appendChild(cell);
    cell = new Cell();
    cell.appendChild(selTable);
    ThemeUtils.addSclass("table-cell", cell);
    boxSelDoc.appendChild(cell);
    cell = new Cell();
    cell.appendChild(selRecord);
    ThemeUtils.addSclass("record-cell", cell);
    boxSelDoc.appendChild(cell);
    // Posting Type
    Hbox boxPostingType = new Hbox();
    ThemeUtils.addSclass("selection-box", boxPostingType);
    ThemeUtils.addSclass("select-posting", boxPostingType);
    boxPostingType.setHflex("1");
    //boxPostingType.setWidths("30%, 70%");
    lpostingType.setValue(Msg.translate(Env.getCtx(), "PostingType"));
    selPostingType.setMold("select");
    selPostingType.setRows(1);
    selPostingType.addEventListener(Events.ON_CLICK, this);
    selPostingType.setAttribute("zk_component_ID", "Lookup_Criteria_selPostingType");
    cell = new Cell();
    cell.appendChild(lpostingType);
    ThemeUtils.addSclass("label-cell", cell);
    boxPostingType.appendChild(cell);
    cell = new Cell();
    cell.appendChild(selPostingType);
    ThemeUtils.addSclass("field-cell", cell);
    boxPostingType.appendChild(cell);
    // Date
    Hbox boxDate = new Hbox();
    ThemeUtils.addSclass("selection-box", boxDate);
    ThemeUtils.addSclass("select-date", boxDate);
    boxDate.setHflex("1");
    //boxDate.setWidths("30%, 35%, 35%");
    lDate.setValue(Msg.translate(Env.getCtx(), "DateAcct"));
    lDate.setAttribute("zk_component_ID", "Lookup_Criteria_Label_Date");
    selDateFrom.setAttribute("zk_component_ID", "Lookup_Criteria_selDateFrom");
    selDateTo.setAttribute("zk_component_ID", "Lookup_Criteria_selDateTo");
    cell = new Cell();
    cell.appendChild(lDate);
    ThemeUtils.addSclass("label-cell", cell);
    boxDate.appendChild(cell);
    cell = new Cell();
    cell.appendChild(selDateFrom);
    ThemeUtils.addSclass("date-from-cell", cell);
    boxDate.appendChild(cell);
    cell = new Cell();
    cell.appendChild(selDateTo);
    ThemeUtils.addSclass("date-to-cell", cell);
    boxDate.appendChild(cell);
    // Organization
    Hbox boxOrg = new Hbox();
    ThemeUtils.addSclass("selection-box", boxOrg);
    ThemeUtils.addSclass("select-org", boxOrg);
    boxOrg.setHflex("1");
    //boxOrg.setWidths("30%, 70%");
    lOrg.setValue(Msg.translate(Env.getCtx(), "AD_Org_ID"));
    selOrg.setMold("select");
    selOrg.setRows(1);
    selOrg.addEventListener(Events.ON_SELECT, this);
    lOrg.setAttribute("zk_component_ID", "Lookup_Criteria_Label_Org");
    selOrg.setAttribute("zk_component_ID", "Lookup_Criteria_selOrg");
    cell = new Cell();
    cell.appendChild(lOrg);
    ThemeUtils.addSclass("label-cell", cell);
    boxOrg.appendChild(cell);
    cell = new Cell();
    cell.appendChild(selOrg);
    ThemeUtils.addSclass("field-cell", cell);
    boxOrg.appendChild(cell);
    // Account
    Hbox boxAcct = new Hbox();
    ThemeUtils.addSclass("selection-box", boxAcct);
    ThemeUtils.addSclass("select-acct", boxAcct);
    boxAcct.setHflex("1");
    //boxAcct.setWidths("30%, 70%");
    lAcct.setValue(Msg.translate(Env.getCtx(), "Account_ID"));
    lAcct.setAttribute("zk_component_ID", "Lookup_Criteria_Label_Acct");
    selAcct.setAttribute("zk_component_ID", "Lookup_Criteria_selAcct");
    cell = new Cell();
    cell.appendChild(lAcct);
    ThemeUtils.addSclass("label-cell", cell);
    boxAcct.appendChild(cell);
    cell = new Cell();
    cell.appendChild(selAcct);
    ThemeUtils.addSclass("field-cell", cell);
    boxAcct.appendChild(cell);
    Hbox boxSel1 = new Hbox();
    ThemeUtils.addSclass("button-box", boxSel1);
    boxSel1.setHflex("1");
    cell = new Cell();
    cell.appendChild(lsel1);
    ThemeUtils.addSclass("label-cell", cell);
    boxSel1.appendChild(cell);
    cell = new Cell();
    cell.appendChild(sel1);
    ThemeUtils.addSclass("field-cell", cell);
    boxSel1.appendChild(cell);
    Hbox boxSel2 = new Hbox();
    ThemeUtils.addSclass("button-box", boxSel2);
    boxSel2.setHflex("1");
    cell = new Cell();
    cell.appendChild(lsel2);
    ThemeUtils.addSclass("label-cell", cell);
    boxSel2.appendChild(cell);
    cell = new Cell();
    cell.appendChild(sel2);
    ThemeUtils.addSclass("field-cell", cell);
    boxSel2.appendChild(cell);
    Hbox boxSel3 = new Hbox();
    ThemeUtils.addSclass("button-box", boxSel3);
    boxSel3.setHflex("1");
    cell = new Cell();
    cell.appendChild(lsel3);
    ThemeUtils.addSclass("label-cell", cell);
    boxSel3.appendChild(cell);
    cell = new Cell();
    cell.appendChild(sel3);
    ThemeUtils.addSclass("field-cell", cell);
    boxSel3.appendChild(cell);
    Hbox boxSel4 = new Hbox();
    ThemeUtils.addSclass("button-box", boxSel4);
    boxSel4.setHflex("1");
    cell = new Cell();
    cell.appendChild(lsel4);
    ThemeUtils.addSclass("label-cell", cell);
    boxSel4.appendChild(cell);
    cell = new Cell();
    cell.appendChild(sel4);
    ThemeUtils.addSclass("field-cell", cell);
    boxSel4.appendChild(cell);
    Hbox boxSel5 = new Hbox();
    ThemeUtils.addSclass("button-box", boxSel5);
    boxSel5.setHflex("1");
    cell = new Cell();
    cell.appendChild(lsel5);
    ThemeUtils.addSclass("label-cell", cell);
    boxSel5.appendChild(cell);
    cell = new Cell();
    cell.appendChild(sel5);
    ThemeUtils.addSclass("field-cell", cell);
    boxSel5.appendChild(cell);
    Hbox boxSel6 = new Hbox();
    ThemeUtils.addSclass("button-box", boxSel6);
    boxSel6.setHflex("1");
    cell = new Cell();
    cell.appendChild(lsel6);
    ThemeUtils.addSclass("label-cell", cell);
    boxSel6.appendChild(cell);
    cell = new Cell();
    cell.appendChild(sel6);
    ThemeUtils.addSclass("field-cell", cell);
    boxSel6.appendChild(cell);
    Hbox boxSel7 = new Hbox();
    ThemeUtils.addSclass("button-box", boxSel7);
    boxSel7.setHflex("1");
    cell = new Cell();
    cell.appendChild(lsel7);
    ThemeUtils.addSclass("label-cell", cell);
    boxSel7.appendChild(cell);
    cell = new Cell();
    cell.appendChild(sel7);
    ThemeUtils.addSclass("field-cell", cell);
    boxSel7.appendChild(cell);
    Hbox boxSel8 = new Hbox();
    ThemeUtils.addSclass("button-box", boxSel8);
    boxSel8.setHflex("1");
    cell = new Cell();
    cell.appendChild(lsel8);
    ThemeUtils.addSclass("label-cell", cell);
    boxSel8.appendChild(cell);
    cell = new Cell();
    cell.appendChild(sel8);
    ThemeUtils.addSclass("field-cell", cell);
    boxSel8.appendChild(cell);
    //selectionPanel.setWidth("100%");
    selectionPanel.setHflex("1");
    selectionPanel.appendChild(boxAcctSchema);
    selectionPanel.appendChild(boxSelDoc);
    selectionPanel.appendChild(boxPostingType);
    selectionPanel.appendChild(boxDate);
    selectionPanel.appendChild(boxOrg);
    selectionPanel.appendChild(boxAcct);
    selectionPanel.appendChild(boxSel1);
    selectionPanel.appendChild(boxSel2);
    selectionPanel.appendChild(boxSel3);
    selectionPanel.appendChild(boxSel4);
    selectionPanel.appendChild(boxSel5);
    selectionPanel.appendChild(boxSel6);
    selectionPanel.appendChild(boxSel7);
    selectionPanel.appendChild(boxSel8);
    //Display Panel
    // Display Document Info
    displayDocumentInfo.setLabel(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "DisplayDocumentInfo")));
    displayDocumentInfo.addEventListener(Events.ON_CLICK, this);
    // Display Source Info
    displaySourceAmt.setLabel(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "DisplaySourceInfo")));
    displaySourceAmt.addEventListener(Events.ON_CHECK, this);
    // Display Quantity
    displayQty.setLabel(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "DisplayQty")));
    displayQty.addEventListener(Events.ON_CHECK, this);
    Hbox boxSortDisplay = new Hbox();
    boxSortDisplay.setWidth("100%");
    boxSortDisplay.setWidths("70%, 30%");
    lSort.setValue(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "SortBy")));
    lGroup.setValue(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "GroupBy")));
    boxSortDisplay.appendChild(lSort);
    boxSortDisplay.appendChild(lGroup);
    Hbox boxSort1 = new Hbox();
    boxSort1.setWidth("100%");
    boxSort1.setWidths("70%, 30%");
    sortBy1.setMold("select");
    sortBy1.setRows(1);
    boxSort1.appendChild(sortBy1);
    boxSort1.appendChild(group1);
    Hbox boxSort2 = new Hbox();
    boxSort2.setWidth("100%");
    boxSort2.setWidths("70%, 30%");
    sortBy2.setMold("select");
    sortBy2.setRows(1);
    boxSort2.appendChild(sortBy2);
    boxSort2.appendChild(group2);
    Hbox boxSort3 = new Hbox();
    boxSort3.setWidth("100%");
    boxSort3.setWidths("70%, 30%");
    sortBy3.setMold("select");
    sortBy3.setRows(1);
    boxSort3.appendChild(sortBy3);
    boxSort3.appendChild(group3);
    Hbox boxSort4 = new Hbox();
    boxSort4.setWidth("100%");
    boxSort4.setWidths("70%, 30%");
    sortBy4.setMold("select");
    sortBy4.setRows(1);
    boxSort4.appendChild(sortBy4);
    boxSort4.appendChild(group4);
    displayPanel.setWidth("100%");
    displayPanel.appendChild(displayDocumentInfo);
    displayPanel.appendChild(displaySourceAmt);
    displayPanel.appendChild(displayQty);
    displayPanel.appendChild(boxSortDisplay);
    displayPanel.appendChild(boxSort1);
    displayPanel.appendChild(boxSort2);
    displayPanel.appendChild(boxSort3);
    displayPanel.appendChild(boxSort4);
    //"images/InfoAccount16.png"
    Groupbox groupDisplay = new Groupbox();
    Caption capDisplay = new Caption("Display");
    groupDisplay.appendChild(capDisplay);
    groupDisplay.appendChild(displayPanel);
    Groupbox groupSelection = new Groupbox();
    Caption capSelection = new Caption("Selection");
    groupSelection.appendChild(capSelection);
    groupSelection.appendChild(selectionPanel);
    Hbox boxQueryPanel = new Hbox();
    boxQueryPanel.setWidth("98%");
    boxQueryPanel.setWidths("63%,1%,36%");
    boxQueryPanel.appendChild(groupSelection);
    Separator separator = new Separator();
    separator.setOrient("vertical");
    boxQueryPanel.appendChild(separator);
    boxQueryPanel.appendChild(groupDisplay);
    //  South Panel
    bRePost.setLabel(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "RePost")));
    bRePost.setTooltiptext(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "RePostInfo")));
    bRePost.addEventListener(Events.ON_CLICK, this);
    bRePost.setVisible(false);
    forcePost.setLabel(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "Force")));
    forcePost.setTooltiptext(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "ForceInfo")));
    forcePost.setVisible(false);
    bQuery.setImage(ServletFns.resolveThemeURL("~./images/Refresh16.png"));
    bQuery.setTooltiptext(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "Refresh")));
    bQuery.addEventListener(Events.ON_CLICK, this);
    //FR[3435028]
    bExport.setImage(ServletFns.resolveThemeURL("~./images/Export16.png"));
    bExport.setTooltiptext(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "Export")));
    bExport.addEventListener(Events.ON_CLICK, this);
    bPrint.setImage(ServletFns.resolveThemeURL("~./images/Print16.png"));
    bPrint.setTooltiptext(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "Print")));
    bPrint.addEventListener(Events.ON_CLICK, this);
    southPanel.setWidth("100%");
    southPanel.setWidths("2%, 12%, 82%, 2%, 2%");
    southPanel.appendChild(bRePost);
    southPanel.appendChild(forcePost);
    southPanel.appendChild(statusLine);
    //FR[3435028]
    southPanel.appendChild(bExport);
    southPanel.appendChild(bPrint);
    southPanel.appendChild(bQuery);
    // Result Tab
    resultPanel = new Borderlayout();
    resultPanel.setStyle("position: absolute");
    resultPanel.setWidth("99%");
    resultPanel.setHeight("99%");
    result.appendChild(resultPanel);
    Center resultCenter = new Center();
    resultCenter.setHflex("true");
    resultCenter.setVflex("true");
    resultPanel.appendChild(resultCenter);
    table.setWidth("96%");
    //table.setHeight("98%");
    table.setVflex(true);
    table.setStyle("overflow: auto; position: absolute;");
    resultCenter.appendChild(table);
    pagingPanel = new South();
    resultPanel.appendChild(pagingPanel);
    pagingPanel.appendChild(paging);
    result.setWidth("100%");
    result.setHeight("100%");
    result.setStyle("position: relative");
    paging.addEventListener("onPaging", this);
    paging.setAutohide(true);
    paging.setDetailed(true);
    // Query Tab
    query.setWidth("100%");
    query.appendChild(boxQueryPanel);
    // Tabbox
    tabQuery.addEventListener(Events.ON_SELECT, this);
    tabQuery.setLabel(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "ViewerQuery")));
    tabResult.addEventListener(Events.ON_SELECT, this);
    tabResult.setLabel(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "ViewerResult")));
    tabs.appendChild(tabQuery);
    tabs.appendChild(tabResult);
    tabpanels.setWidth("100%");
    tabpanels.appendChild(query);
    tabpanels.appendChild(result);
    tabbedPane.setWidth("100%");
    tabbedPane.setHeight("100%");
    tabbedPane.appendChild(tabs);
    tabbedPane.appendChild(tabpanels);
    Borderlayout layout = new Borderlayout();
    layout.setParent(this);
    //		layout.setHeight("100%");
    //		layout.setWidth("100%");
    //		layout.setStyle("background-color: transparent");
    Center center = new Center();
    center.setParent(layout);
    center.setHflex("true");
    center.setVflex("true");
    center.setStyle("background-color: transparent");
    tabbedPane.setParent(center);
    South south = new South();
    south.setParent(layout);
    south.setHflex("true");
    south.setVflex("true");
    south.setStyle("background-color: transparent");
    southPanel.setParent(south);
//tabbedPane.addEventListener(Events.ON_SELECT, this);
}
Also used : Hbox(org.zkoss.zul.Hbox) Center(org.zkoss.zul.Center) Groupbox(org.zkoss.zul.Groupbox) South(org.zkoss.zul.South) Borderlayout(org.zkoss.zul.Borderlayout) Cell(org.zkoss.zul.Cell) Caption(org.zkoss.zul.Caption) Separator(org.zkoss.zul.Separator)

Example 9 with Caption

use of org.zkoss.zul.Caption in project adempiere by adempiere.

the class WPOSInfoProduct method init.

@Override
protected void init() {
    parameterPanel = new Panel();
    Groupbox groupPanel = new Groupbox();
    infoProductLayout = GridFactory.newGridLayout();
    Caption v_TitleBorder = new Caption(Msg.getMsg(Env.getCtx(), "InfoProduct"));
    groupPanel.appendChild(v_TitleBorder);
    groupPanel.appendChild(infoProductLayout);
    labelLayout = GridFactory.newGridLayout();
    buttonPanel = new Panel();
    buttonPanel.appendChild(labelLayout);
    parameterPanel.appendChild(groupPanel);
    buttonPanel.setStyle("border: none; width:99%;moz-box-shadow: 0 0 0px #888;-webkit-box-shadow: 0 0 0px #888;box-shadow: 0 0 0px #888;");
    labelLayout.setStyle("border: none; width:100%;moz-box-shadow: 0 0 0px #888;-webkit-box-shadow: 0 0 0px #888;box-shadow: 0 0 0px #888;");
    infoProductLayout.setStyle("border: none; width:100%; moz-box-shadow: 0 0 0px #888;-webkit-box-shadow: 0 0 0px #888;box-shadow: 0 0 0px #888;");
    parameterPanel.setStyle("border: none; width:99%;");
    Rows rows = null;
    Row row = null;
    rows = infoProductLayout.newRows();
    row = rows.newRow();
    //	For Image
    buttonImage = new Panel();
    row.appendChild(buttonImage);
    buttonImage.setWidth("138px");
    buttonImage.setHeight("130px");
    row.appendChild(buttonPanel);
    rows = labelLayout.newRows();
    row = rows.newRow();
    //	For Value
    labelValue = new Label();
    labelValue.setStyle(WPOS.FONTSIZEMEDIUM + " font-weight:bold");
    //	Add
    row.appendChild(labelValue);
    row = rows.newRow();
    //  For Price List
    labelPriceName = new Label();
    labelPriceName.setStyle(WPOS.FONTSIZEMEDIUM + " font-weight:bold");
    //	Add
    row.appendChild(labelPriceName);
    labelPrice = new Label();
    labelPrice.setStyle(WPOS.FONTSIZELARGE + "font-weight:bold");
    //	Add
    row.appendChild(labelPrice);
    labelPriceList = new Label();
    labelPriceList.setStyle(WPOS.FONTSIZELARGE + "font-weight:bold");
    //	Add
    row.appendChild(labelPriceList);
    row = rows.newRow();
    //	For Name
    labelName = new Label();
    labelName.setStyle(WPOS.FONTSIZEMEDIUM + " font-weight:bold");
    //	Add
    row.appendChild(labelName);
    row = rows.newRow();
    //  For UOM
    labelUOMSymbol = new Label(Msg.getElement(Env.getCtx(), "C_UOM_ID"));
    labelUOMSymbol.setStyle(WPOS.FONTSIZEMEDIUM + " font-weight:bold");
    //	Add
    row.appendChild(labelUOMSymbol);
    row = rows.newRow();
    //	For Category
    labelProductCategory = new Label(Msg.getElement(Env.getCtx(), "M_Product_Category_ID"));
    labelProductCategory.setStyle(WPOS.FONTSIZEMEDIUM + " font-weight:bold");
    //	Add
    row.appendChild(labelProductCategory);
    row = rows.newRow();
    //	For Category
    labelProductTax = new Label(Msg.getElement(Env.getCtx(), "C_TaxCategory_ID"));
    labelProductTax.setStyle(WPOS.FONTSIZEMEDIUM + " font-weight:bold");
    //	Add
    row.appendChild(labelProductTax);
    row = rows.newRow();
    //	For Description
    labelDescription = new Label();
    labelDescription.setHeight("19px");
    labelDescription.setClass("label-description");
    //	Add
    row.appendChild(labelDescription);
    initialValue();
}
Also used : Panel(org.adempiere.webui.component.Panel) Groupbox(org.zkoss.zul.Groupbox) Label(org.adempiere.webui.component.Label) Row(org.adempiere.webui.component.Row) Caption(org.zkoss.zul.Caption) Rows(org.adempiere.webui.component.Rows)

Example 10 with Caption

use of org.zkoss.zul.Caption in project adempiere by adempiere.

the class WCollectDetail method init.

/**
	 * Init Main Panel
	 * @author Yamel Senih, ysenih@erpcya.com, ERPCyA http://www.erpcya.com
	 * @return void
	 */
private void init() {
    v_MainPanel = new Panel();
    v_PanelChildren = new Panelchildren();
    groupPanel = new Groupbox();
    v_PanelChildren.appendChild(groupPanel);
    v_TitleBorder = new Caption("Credit Card");
    Style style = new Style();
    style.setContent(".z-fieldset legend {font-size: medium; font-weight:bold;}");
    style.setParent(v_TitleBorder);
    groupPanel.appendChild(v_TitleBorder);
    v_MainPanel.appendChild(v_PanelChildren);
    //	Load Standard Panel
    loadStandardPanel();
    //	Load Check Panel
    loadCheckPanel();
    //	Load Credit Panel
    loadCreditPanel();
    //	Load Debit Panel
    loadDebitPanel();
    //	Load Credit Note Panel
    loadCreditMemoPanel();
    //	Add to Main Panel
    groupPanel.appendChild(v_StandarPanel);
    groupPanel.appendChild(v_CheckPanel);
    groupPanel.appendChild(v_CreditPanel);
    groupPanel.appendChild(v_DebitPanel);
    groupPanel.appendChild(v_CreditMemoPanel);
    //  Change View
    changeViewPanel();
    fPayAmt.setValue(getPayAmt());
}
Also used : Panel(org.zkoss.zul.Panel) Groupbox(org.zkoss.zul.Groupbox) Style(org.zkoss.zul.Style) Panelchildren(org.zkoss.zul.Panelchildren) Caption(org.zkoss.zul.Caption)

Aggregations

Caption (org.zkoss.zul.Caption)10 Groupbox (org.zkoss.zul.Groupbox)7 Label (org.adempiere.webui.component.Label)6 Row (org.adempiere.webui.component.Row)6 Rows (org.adempiere.webui.component.Rows)6 Grid (org.adempiere.webui.component.Grid)4 Panel (org.adempiere.webui.component.Panel)4 WPOSTextField (org.adempiere.pos.WPOSTextField)3 Center (org.zkoss.zkex.zul.Center)3 North (org.zkoss.zkex.zul.North)3 Borderlayout (org.zkoss.zul.Borderlayout)2 Center (org.zkoss.zul.Center)2 Separator (org.zkoss.zul.Separator)2 South (org.zkoss.zul.South)2 Style (org.zkoss.zul.Style)2 BigDecimal (java.math.BigDecimal)1 Checkbox (org.adempiere.webui.component.Checkbox)1 Datebox (org.adempiere.webui.component.Datebox)1 ADTabPanel (org.adempiere.webui.panel.ADTabPanel)1 KeyNamePair (org.compiere.util.KeyNamePair)1