Search in sources :

Example 16 with South

use of org.zkoss.zkex.zul.South in project adempiere by adempiere.

the class WDeleteEntity method zkInit.

private void zkInit() throws Exception {
    //Form Init()
    form.appendChild(mainLayout);
    mainLayout.setWidth("100%");
    mainLayout.setHeight("100%");
    clientLabel.setText(Msg.getElement(Env.getCtx(), "AD_Client_ID"));
    tableLabel.setText(Msg.getElement(Env.getCtx(), "AD_Table_ID"));
    dryRun = new Checkbox(Msg.getMsg(Env.getCtx(), "DryRun"));
    dryRun.setChecked(true);
    ConfirmPanel panel = new ConfirmPanel(false, false, false, false, false, false, false);
    bRefresh = panel.createButton(ConfirmPanel.A_REFRESH);
    bRefresh.addActionListener(this);
    //	
    parameterPanel.appendChild(parameterLayout);
    North north = new North();
    north.setStyle("border: none");
    mainLayout.appendChild(north);
    north.appendChild(parameterPanel);
    Rows rows = null;
    Row row = null;
    parameterLayout.setWidth("100%");
    rows = parameterLayout.newRows();
    row = rows.newRow();
    row.appendChild(clientLabel.rightAlign());
    row.appendChild(clientPick);
    row.appendChild(tableLabel.rightAlign());
    row.appendChild(tablePick);
    //	For Button
    row = rows.newRow();
    row.appendChild(new Hbox());
    row.appendChild(dryRun);
    row.appendChild(new Hbox());
    row.appendChild(bRefresh);
    //	
    centerPanel.appendChild(centerLayout);
    centerLayout.setWidth("100%");
    Center center = new Center();
    mainLayout.appendChild(center);
    center.setStyle("border: none");
    center.appendChild(centerPanel);
    tree = new Tree();
    treeCols = new Treecols();
    treeCol = new Treecol("");
    treeCol2 = new Treecol();
    centerPanel.appendChild(tree);
    treeCols.appendChild(treeCol);
    treeCols.appendChild(treeCol2);
    tree.appendChild(treeCols);
    center.setFlex(true);
    center.setAutoscroll(true);
    South south = new South();
    south.appendChild(southPanel);
    southPanel.appendChild(southLayout);
    southPanel.setWidth("100%");
    mainLayout.appendChild(south);
    Rows rows2 = southLayout.newRows();
    Row south_row = rows2.newRow();
    south_row.appendChild(confirmPanel);
    confirmPanel.addActionListener(this);
}
Also used : Treecol(org.zkoss.zul.Treecol) Hbox(org.zkoss.zul.Hbox) Treecols(org.zkoss.zul.Treecols) Center(org.zkoss.zkex.zul.Center) ConfirmPanel(org.adempiere.webui.component.ConfirmPanel) Checkbox(org.zkoss.zul.Checkbox) South(org.zkoss.zkex.zul.South) Tree(org.zkoss.zul.Tree) North(org.zkoss.zkex.zul.North) Row(org.adempiere.webui.component.Row) Rows(org.adempiere.webui.component.Rows)

Example 17 with South

use of org.zkoss.zkex.zul.South in project adempiere by adempiere.

the class FindWindow method initAdvanced.

/**
     * initialise Advanced Tab
     * @throws IOException 
     *
    **/
private void initAdvanced() throws IOException {
    ToolBarButton btnNew = new ToolBarButton();
    btnNew.setImage("/images/New24.png");
    btnNew.setAttribute("name", "btnNewAdv");
    btnNew.addEventListener(Events.ON_CLICK, this);
    ToolBarButton btnDelete = new ToolBarButton();
    btnDelete.setAttribute("name", "btnDeleteAdv");
    btnDelete.setImage("/images/Delete24.png");
    btnDelete.addEventListener(Events.ON_CLICK, this);
    ToolBarButton btnSave = new ToolBarButton();
    btnSave.setAttribute("name", "btnSaveAdv");
    btnSave.setImage("/images/Save24.png");
    btnSave.addEventListener(Events.ON_CLICK, this);
    fQueryName = new Combobox();
    fQueryName.setTooltiptext(m_sToolTipText);
    fQueryName.setReadonly(false);
    fQueryName.addEventListener(Events.ON_FOCUS, this);
    fQueryName.addEventListener(Events.ON_BLUR, this);
    fQueryName.addEventListener(Events.ON_SELECT, this);
    //	Get from Action
    WAppsAction action = new WAppsAction(ConfirmPanel.A_OK, null, ConfirmPanel.A_OK);
    Button btnOk = action.getButton();
    btnOk.setName("btnOkAdv");
    btnOk.addEventListener(Events.ON_CLICK, this);
    //	
    action = new WAppsAction(ConfirmPanel.A_CANCEL, null, ConfirmPanel.A_CANCEL);
    Button btnCancel = action.getButton();
    btnCancel.setName("btnCancel");
    btnCancel.addEventListener(Events.ON_CLICK, this);
    Panel pnlButtonRight = new Panel();
    //	Change to Standard button order
    pnlButtonRight.appendChild(btnCancel);
    pnlButtonRight.appendChild(btnOk);
    pnlButtonRight.setAlign("right");
    ToolBar toolBar = new ToolBar();
    toolBar.appendChild(btnNew);
    toolBar.appendChild(btnDelete);
    toolBar.appendChild(fQueryName);
    toolBar.appendChild(btnSave);
    toolBar.setWidth("100%");
    fQueryName.setStyle("margin-left: 3px; margin-right: 3px; position: relative; top: 5px;");
    btnSave.setDisabled(m_AD_Tab_ID <= 0);
    Hbox confirmPanel = new Hbox();
    confirmPanel.appendChild(pnlButtonRight);
    confirmPanel.setWidth("100%");
    advancedPanel = new Listbox();
    ListHead listhead = new ListHead();
    listhead.setSizable(true);
    ListHeader lstHAndOr = new ListHeader();
    lstHAndOr.setLabel(Msg.getMsg(Env.getCtx(), "And/Or"));
    lstHAndOr.setWidth("40px");
    ListHeader lstHLeftBracket = new ListHeader();
    lstHLeftBracket.setLabel("(");
    lstHLeftBracket.setWidth("20px");
    ListHeader lstHColumn = new ListHeader();
    lstHColumn.setLabel(Msg.translate(Env.getCtx(), "AD_Column_ID"));
    lstHColumn.setWidth("100px");
    ListHeader lstHOperator = new ListHeader();
    lstHOperator.setLabel(Msg.getMsg(Env.getCtx(), "Operator"));
    ListHeader lstHQueryValue = new ListHeader();
    lstHQueryValue.setLabel(Msg.getMsg(Env.getCtx(), "QueryValue"));
    lstHQueryValue.setWidth("170px");
    ListHeader lstHQueryTo = new ListHeader();
    lstHQueryTo.setLabel(Msg.getMsg(Env.getCtx(), "QueryValue2"));
    lstHQueryTo.setWidth("170px");
    ListHeader lstHRightBracket = new ListHeader();
    lstHRightBracket.setLabel(")");
    lstHRightBracket.setWidth("20px");
    listhead.appendChild(lstHAndOr);
    listhead.appendChild(lstHLeftBracket);
    listhead.appendChild(lstHColumn);
    listhead.appendChild(lstHOperator);
    listhead.appendChild(lstHQueryValue);
    listhead.appendChild(lstHQueryTo);
    listhead.appendChild(lstHRightBracket);
    advancedPanel.appendChild(listhead);
    advancedPanel.setVflex(true);
    Borderlayout layout = new Borderlayout();
    layout.setStyle("height: 100%; width: 99%; position: relative;");
    winAdvanced.appendChild(layout);
    North north = new North();
    layout.appendChild(north);
    north.appendChild(toolBar);
    Center center = new Center();
    layout.appendChild(center);
    center.appendChild(advancedPanel);
    center.setFlex(true);
    South south = new South();
    layout.appendChild(south);
    south.appendChild(confirmPanel);
    winAdvanced.setHeight("100%");
    winAdvanced.setWidth("100%");
    winAdvanced.addEventListener(Events.ON_OK, this);
}
Also used : Hbox(org.zkoss.zul.Hbox) Center(org.zkoss.zkex.zul.Center) ToolBarButton(org.adempiere.webui.component.ToolBarButton) Combobox(org.adempiere.webui.component.Combobox) South(org.zkoss.zkex.zul.South) Borderlayout(org.zkoss.zkex.zul.Borderlayout) WAppsAction(org.adempiere.webui.component.WAppsAction) Panel(org.adempiere.webui.component.Panel) ConfirmPanel(org.adempiere.webui.component.ConfirmPanel) Button(org.adempiere.webui.component.Button) ToolBarButton(org.adempiere.webui.component.ToolBarButton) ListHead(org.adempiere.webui.component.ListHead) ToolBar(org.adempiere.webui.component.ToolBar) ListHeader(org.adempiere.webui.component.ListHeader) North(org.zkoss.zkex.zul.North) Listbox(org.adempiere.webui.component.Listbox)

Example 18 with South

use of org.zkoss.zkex.zul.South in project adempiere by adempiere.

the class WScanBarUI method productPanel.

/**
     * Creates the account panel.
     *
     * The account panel contains:
     * <li>a table detailing all accounts
     * <li>a button for creating charges for selected accounts
     */
private void productPanel() {
    Borderlayout borderlayout = new Borderlayout();
    borderlayout.setStyle("position: absolute");
    borderlayout.setWidth("100%");
    borderlayout.setHeight("100%");
    productPanel.appendChild(borderlayout);
    North north = new North();
    north.setBorder("none");
    borderlayout.appendChild(north);
    Label label = new Label(Msg.translate(Env.getCtx(), "M_Product_ID"));
    label.setStyle("font-weight: bold;");
    north.appendChild(label);
    Center center = new Center();
    center.setBorder("none");
    center.setFlex(true);
    center.setAutoscroll(true);
    borderlayout.appendChild(center);
    center.appendChild(productTable);
    South south = new South();
    south.setBorder("none");
    borderlayout.appendChild(south);
    Panel southPanel = new Panel();
    southPanel.setAlign("right");
    south.appendChild(southPanel);
    return;
}
Also used : Panel(org.adempiere.webui.component.Panel) ConfirmPanel(org.adempiere.webui.component.ConfirmPanel) Center(org.zkoss.zkex.zul.Center) Label(org.adempiere.webui.component.Label) South(org.zkoss.zkex.zul.South) North(org.zkoss.zkex.zul.North) Borderlayout(org.zkoss.zkex.zul.Borderlayout)

Example 19 with South

use of org.zkoss.zkex.zul.South in project adempiere by adempiere.

the class ProcessPanel method initComponents.

/**
	 * Initialize components
	 */
@Override
public void initComponents() {
    m_separators = new ArrayList<Label>();
    rows = new Rows();
    //
    mainPanel = new Panel();
    parameterPanel = GridFactory.newGridLayout();
    parameterPanel.setInnerWidth(width);
    //setup columns
    Columns columns = new Columns();
    parameterPanel.appendChild(columns);
    int colN = getColumns() * 2;
    if (colN != 0) {
        int percent = 100 / colN;
        for (int i = 0; i < colN; i++) {
            Column col = new Column();
            col.setWidth((i == 0 ? ((int) percent / 2) : percent) + "%");
            columns.appendChild(col);
        }
    }
    //	Add Rows
    parameterPanel.appendChild(rows);
    //	
    mainLayout = new Borderlayout();
    mainLayout.setStyle("border: none; overflow: auto");
    //	Message Panel
    if (isShowDescription()) {
        messageDiv = new Div();
        message = new Html();
        messageDiv.appendChild(message);
        messageDiv.setStyle(MESSAGE_DIV_STYLE);
        messagePanel = new North();
        messagePanel.appendChild(messageDiv);
        messagePanel.setAutoscroll(true);
        messagePanel.setStyle("border: none;");
        mainLayout.appendChild(messagePanel);
    }
    //	Parameter Panel
    centerPanel = new Center();
    mainLayout.appendChild(centerPanel);
    centerPanel.appendChild(parameterPanel);
    centerPanel.setFlex(false);
    centerPanel.setStyle("border: none");
    //	Buttons Panel
    if (isShowButtons()) {
        Grid southRowPanel = GridFactory.newGridLayout();
        Rows rows = southRowPanel.newRows();
        Row row = rows.newRow();
        Hbox hBox = new Hbox();
        hBox.appendChild(lSaved);
        fSavedName.addEventListener(Events.ON_CHANGE, this);
        hBox.appendChild(fSavedName);
        bSave.setEnabled(false);
        bSave.setImage("/images/Save24.png");
        bSave.setSclass("action-button");
        bSave.addActionListener(this);
        hBox.appendChild(bSave);
        bDelete.setEnabled(false);
        bDelete.setImage("/images/Delete24.png");
        bDelete.setSclass("action-button");
        bDelete.addActionListener(this);
        hBox.appendChild(bDelete);
        row.appendChild(hBox);
        Panel confParaPanel = new Panel();
        confParaPanel.setAlign("right");
        //	BR [ 300 ]
        try {
            //	Set Ok
            WAppsAction action = new WAppsAction(ConfirmPanel.A_OK, null, ConfirmPanel.A_OK);
            bOK = action.getButton();
            //	Set to Cancel
            action = new WAppsAction(ConfirmPanel.A_CANCEL, null, ConfirmPanel.A_CANCEL);
            bCancel = action.getButton();
            //	Add Listener
            bOK.addEventListener(Events.ON_CLICK, this);
            bCancel.addEventListener(Events.ON_CLICK, this);
            //	Add to Panel
            confParaPanel.appendChild(bCancel);
            confParaPanel.appendChild(bOK);
        } catch (Exception e) {
            log.severe("Error loading Buttons " + e.getLocalizedMessage());
        }
        //	
        row.appendChild(confParaPanel);
        South south = new South();
        south.appendChild(southRowPanel);
        //	Add to Main panel
        mainLayout.appendChild(south);
    }
    //	Set Text
    if (isShowDescription()) {
        message.setContent(getTextMsg());
    }
    //	
    mainPanel.appendChild(mainLayout);
    mainPanel.setHeight("100%");
    mainPanel.setWidth("100%");
}
Also used : Hbox(org.zkoss.zul.Hbox) Center(org.zkoss.zkex.zul.Center) Grid(org.adempiere.webui.component.Grid) Label(org.adempiere.webui.component.Label) South(org.zkoss.zkex.zul.South) Columns(org.adempiere.webui.component.Columns) Html(org.zkoss.zul.Html) Borderlayout(org.adempiere.webui.component.Borderlayout) WAppsAction(org.adempiere.webui.component.WAppsAction) Div(org.zkoss.zul.Div) Panel(org.adempiere.webui.component.Panel) ConfirmPanel(org.adempiere.webui.component.ConfirmPanel) Column(org.adempiere.webui.component.Column) North(org.zkoss.zkex.zul.North) Row(org.adempiere.webui.component.Row) Rows(org.adempiere.webui.component.Rows)

Example 20 with South

use of org.zkoss.zkex.zul.South in project adempiere by adempiere.

the class WAllocation method zkInit.

/**
	 *  Static Init
	 *  @throws Exception
	 */
private void zkInit() throws Exception {
    //	
    confirmPanel = new ConfirmPanel(true);
    form.appendChild(mainLayout);
    mainLayout.setWidth("100%");
    mainLayout.setHeight("100%");
    dateLabel.setText(Msg.getMsg(Env.getCtx(), "Date"));
    autoWriteOff.setSelected(false);
    autoWriteOff.setText(Msg.getMsg(Env.getCtx(), "AutoWriteOff", true));
    autoWriteOff.setTooltiptext(Msg.getMsg(Env.getCtx(), "AutoWriteOff", false));
    //
    parameterPanel.appendChild(parameterLayout);
    allocationPanel.appendChild(allocationLayout);
    bpartnerLabel.setText(Msg.translate(Env.getCtx(), "C_BPartner_ID"));
    paymentLabel.setText(" " + Msg.translate(Env.getCtx(), "C_Payment_ID"));
    invoiceLabel.setText(" " + Msg.translate(Env.getCtx(), "C_Invoice_ID"));
    paymentPanel.appendChild(paymentLayout);
    invoicePanel.appendChild(invoiceLayout);
    invoiceInfo.setText(".");
    paymentInfo.setText(".");
    chargeLabel.setText(" " + Msg.translate(Env.getCtx(), "C_Charge_ID"));
    differenceLabel.setText(Msg.getMsg(Env.getCtx(), "Difference"));
    differenceField.setText("0");
    differenceField.setStyle("text-align: right");
    descriptionLabel.setText(Msg.getMsg(Env.getCtx(), "Description"));
    confirmPanel.addActionListener(this);
    currencyLabel.setText(Msg.translate(Env.getCtx(), "C_Currency_ID"));
    multiCurrency.setText(Msg.getMsg(Env.getCtx(), "MultiCurrency"));
    multiCurrency.addActionListener(this);
    allocCurrencyLabel.setText(".");
    organizationLabel.setText(Msg.translate(Env.getCtx(), "AD_Org_ID"));
    apartLabel.setText(Msg.translate(Env.getCtx(), "APAR"));
    North north = new North();
    north.setStyle("border: none");
    mainLayout.appendChild(north);
    north.appendChild(parameterPanel);
    Rows rows = null;
    Row row = null;
    parameterLayout.setWidth("100%");
    rows = parameterLayout.newRows();
    row = rows.newRow();
    row.appendChild(bpartnerLabel.rightAlign());
    row.appendChild(bpartnerSearch.getComponent());
    row.appendChild(dateLabel.rightAlign());
    row.appendChild(dateField.getComponent());
    row.appendChild(organizationLabel.rightAlign());
    row.appendChild(organizationPick.getComponent());
    row = rows.newRow();
    row.appendChild(currencyLabel.rightAlign());
    row.appendChild(currencyPick.getComponent());
    Div div = new Div();
    div.setStyle("text-align: center");
    div.appendChild(multiCurrency);
    row.appendChild(div);
    row.appendChild(apartLabel.rightAlign());
    row.appendChild(aparPick.getComponent());
    row.appendChild(new Space());
    row.appendChild(new Space());
    row.setSpans("1,1,2,1,1");
    row = rows.newRow();
    row.appendChild(new Space());
    row.appendChild(autoWriteOff);
    row.appendChild(new Space());
    row.appendChild(new Space());
    row.appendChild(new Space());
    row.appendChild(new Space());
    South south = new South();
    south.setStyle("border: none");
    mainLayout.appendChild(south);
    south.appendChild(southPanel);
    southPanel.appendChild(allocationPanel);
    allocationPanel.appendChild(allocationLayout);
    allocationLayout.setWidth("100%");
    rows = allocationLayout.newRows();
    row = rows.newRow();
    row.appendChild(differenceLabel.rightAlign());
    row.appendChild(allocCurrencyLabel.rightAlign());
    row.appendChild(differenceField);
    row.appendChild(new Space());
    row.appendChild(chargeLabel.rightAlign());
    row.appendChild(chargePick.getComponent());
    row.appendChild(new Space());
    row.appendChild(descriptionLabel.rightAlign());
    row.appendChild(descriptionField);
    row.appendChild(new Space());
    row.appendChild(confirmPanel);
    paymentPanel.appendChild(paymentLayout);
    paymentPanel.setWidth("100%");
    paymentPanel.setHeight("100%");
    paymentLayout.setWidth("100%");
    paymentLayout.setHeight("100%");
    paymentLayout.setStyle("border: none");
    invoicePanel.appendChild(invoiceLayout);
    invoicePanel.setWidth("100%");
    invoicePanel.setHeight("100%");
    invoiceLayout.setWidth("100%");
    invoiceLayout.setHeight("100%");
    invoiceLayout.setStyle("border: none");
    north = new North();
    north.setStyle("border: none");
    paymentLayout.appendChild(north);
    north.appendChild(paymentLabel);
    south = new South();
    south.setStyle("border: none");
    paymentLayout.appendChild(south);
    south.appendChild(paymentInfo.rightAlign());
    Center center = new Center();
    paymentLayout.appendChild(center);
    center.appendChild(paymentTable);
    paymentTable.setWidth("99%");
    paymentTable.setHeight("100%");
    paymentTable.setMultiSelection(true);
    center.setStyle("border: none");
    north = new North();
    north.setStyle("border: none");
    invoiceLayout.appendChild(north);
    north.appendChild(invoiceLabel);
    south = new South();
    south.setStyle("border: none");
    invoiceLayout.appendChild(south);
    south.appendChild(invoiceInfo.rightAlign());
    center = new Center();
    invoiceLayout.appendChild(center);
    center.appendChild(invoiceTable);
    invoiceTable.setWidth("99%");
    invoiceTable.setHeight("99%");
    invoiceTable.setMultiSelection(true);
    center.setStyle("border: none");
    //
    center = new Center();
    center.setFlex(true);
    mainLayout.appendChild(center);
    center.appendChild(infoPanel);
    infoPanel.setStyle("border: none");
    infoPanel.setWidth("100%");
    infoPanel.setHeight("100%");
    north = new North();
    north.setStyle("border: none");
    north.setHeight("49%");
    infoPanel.appendChild(north);
    north.appendChild(paymentPanel);
    north.setSplittable(true);
    center = new Center();
    center.setStyle("border: none");
    center.setFlex(true);
    infoPanel.appendChild(center);
    center.appendChild(invoicePanel);
}
Also used : Div(org.zkoss.zul.Div) Space(org.zkoss.zul.Space) Center(org.zkoss.zkex.zul.Center) ConfirmPanel(org.adempiere.webui.component.ConfirmPanel) South(org.zkoss.zkex.zul.South) North(org.zkoss.zkex.zul.North) Row(org.adempiere.webui.component.Row) Rows(org.adempiere.webui.component.Rows)

Aggregations

South (org.zkoss.zkex.zul.South)20 Center (org.zkoss.zkex.zul.Center)17 North (org.zkoss.zkex.zul.North)16 ConfirmPanel (org.adempiere.webui.component.ConfirmPanel)12 Panel (org.adempiere.webui.component.Panel)11 Borderlayout (org.zkoss.zkex.zul.Borderlayout)10 Row (org.adempiere.webui.component.Row)8 Rows (org.adempiere.webui.component.Rows)8 Borderlayout (org.adempiere.webui.component.Borderlayout)5 Label (org.adempiere.webui.component.Label)5 Div (org.zkoss.zul.Div)5 Separator (org.zkoss.zul.Separator)5 Grid (org.adempiere.webui.component.Grid)4 WAppsAction (org.adempiere.webui.component.WAppsAction)4 Hbox (org.zkoss.zul.Hbox)4 Button (org.adempiere.webui.component.Button)3 Listbox (org.adempiere.webui.component.Listbox)2 ToolBarButton (org.adempiere.webui.component.ToolBarButton)2 Pre (org.zkoss.zhtml.Pre)2 Text (org.zkoss.zhtml.Text)2