public void initComponentState() { fieldAmount.setVisible(false); fieldAmountafterppn.setVisible(false); fieldDisc1rp.setVisible(false); // fieldDisc1rpafterppn.setVisible(false); fieldDisc.setVisible(false); fieldDisc2.setVisible(false); fieldDisc2rp.setVisible(false); fieldDisc2rpafterppn.setVisible(false); fieldDiscrp.setVisible(false); // fieldDiscrpafterppn.setVisible(false); fieldPpnpercent.setVisible(false); fieldAmountpay.setVisible(false); fieldAmountpayfaterppn.setVisible(false); checkSaldo.setVisible(false); fieldDisc.setVisible(false); fieldAmount.setVisible(false); fieldPpnrp.setVisible(false); fieldAmountafterdisc.setVisible(false); fieldAmountafterdiscafterppn.setVisible(false); // btnLapselisih.setVisible(false); }
// Build the UI components private void buildview() { logger.info( "Company ID : " + companyid + " | User Name : " + username + " > " + "Painting Email logger UI"); btnAdd.setVisible(false); btnDownload.setVisible(false); btnEdit.setVisible(false); btnAuditRecords.setVisible(false); // Email-id text box tfemailid = new TextField("Email Id"); // product combo box cbproduct = new GERPComboBox("Product Name"); cbproduct.setItemCaptionPropertyId("prodname"); loadProductList(); // Email start date dfemailStartdate = new GERPPopupDateField("Log Start Dt"); dfemailStartdate.setInputPrompt("Select Date"); // Email End date dfemailEndDate = new GERPPopupDateField("Log End Dt"); dfemailEndDate.setInputPrompt("Select Date"); btndelete = new Button("Delete"); btndelete.addStyleName("delete"); btndelete.setEnabled(true); btndelete.setVisible(true); btndelete.addClickListener( new ClickListener() { private static final long serialVersionUID = 1L; @Override public void buttonClick(ClickEvent event) { btndelete.setEnabled(true); if (cockeckall.getValue().equals(true)) { for (EmailLoggerDM obj : emailList) { serviceemailLogger.delete(obj.getEmaillogId()); } } else { delete(); } loadSrchRslt(); /* btndelete.setEnabled(false); cockeckall.setValue(false);*/ } }); cockeckall = new CheckBox("Select All"); cockeckall.addStyleName("delete"); cockeckall.setEnabled(true); cockeckall.setVisible(true); setCheckBoxTable(); cockeckall.setImmediate(true); cockeckall.addValueChangeListener( new Property.ValueChangeListener() { private static final long serialVersionUID = 1L; public void valueChange(ValueChangeEvent event) { if (event.getProperty().getValue().equals(true)) { loadSrchRslt(); btndelete.setEnabled(true); } else { loadSrchRslt(); btndelete.setEnabled(false); } } }); hlCmdBtnLayout.addComponent(cockeckall); hlCmdBtnLayout.setSpacing(true); hlCmdBtnLayout.setComponentAlignment(cockeckall, Alignment.MIDDLE_RIGHT); hlCmdBtnLayout.addComponent(btndelete); hlCmdBtnLayout.setComponentAlignment(btndelete, Alignment.MIDDLE_RIGHT); hlCmdBtnLayout.setExpandRatio(btndelete, 1); // build search layout hlSearchLayout = new GERPAddEditHLayout(); assembleSearchLayout(); hlSrchContainer.addComponent(GERPPanelGenerator.createPanel(hlSearchLayout)); resetFields(); loadSrchRslt(); }