Package de.forsthaus.backend.model

Examples of de.forsthaus.backend.model.Customer


    final int countRecords = 10000;

    final RandomDataEngine randomDataEngine = new RandomDataEngine();

    for (int j = 0; j < countRecords; j++) {
      final Customer customer = getCustomerService().getNewCustomer();

      customer.setKunName1(randomDataEngine.getRandomManFirstname());
      customer.setKunName2(randomDataEngine.getRandomLastname());
      customer.setKunMatchcode(customer.getKunName2().toUpperCase());
      customer.setKunOrt(randomDataEngine.getRandomCity());
      customer.setBranche(branche);
      customer.setOffice(office);
      customer.setKunMahnsperre(Boolean.FALSE);

      getCustomerService().saveOrUpdate(customer);
    }
  }
View Full Code Here


   * @throws InterruptedException
   */
  public void doSave() throws InterruptedException {

    Order anOrder = getOrder();
    Customer aCustomer = getCustomer();

    // +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
    // force validation, if on, than execute by component.getValue()
    // +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
    if (!isValidationOn()) {
View Full Code Here

    // logger.debug(event.toString());

    /** !!! DO NOT BREAK THE TIERS !!! */
    // We don't create a new DomainObject() in the frontend.
    // We GET it from the backend.
    Customer aCustomer = getCustomerService().getNewCustomer();
    aCustomer.setOffice(getUserWorkspace().getOffice()); // init
    // customer.setBranche(Workspace.getBranche()); // init
    aCustomer.setBranche(getBrancheService().getBrancheById(new Integer(1033).longValue())); // init
    aCustomer.setKunMahnsperre(false); // init

    /*
     * We can call our Dialog zul-file with parameters. So we can call them
     * with a object of the selected item. For handed over these parameter
     * only a Map is accepted. So we put the object in a HashMap.
View Full Code Here

    // get the customer
    Listitem item = listBoxCustomerSearch.getSelectedItem();
    if (item != null) {

      Customer aCustomer = (Customer) item.getAttribute("data");
      setCustomer(aCustomer);

      kunNr.setValue(getCustomer().getKunNr());
      bandbox_OrderDialog_CustomerSearch.setValue(getCustomer().getKunNr());
      kunName1.setValue(getCustomer().getKunName1() + " " + getCustomer().getKunName2() + ", " + getCustomer().getKunOrt());
View Full Code Here

   * @param event
   */
  public void onSelect$tabCustomerDialogOrders(Event event) {
    logger.debug(event.toString());

    final Customer aCustomer = getCustomer();

    /* overhanded params to the zul file */
    final HashMap<String, Object> map = new HashMap<String, Object>();
    map.put("customer", aCustomer);
    map.put("customerDialogCtrl", this);
View Full Code Here

   * @throws IOException
   */
  public void onSelect$tabCustomerDialogChart(Event event) throws IOException {
    logger.debug(event.toString());

    final Customer aCustomer = getCustomer();

    /* overhanded params to the zul file */
    HashMap<String, Object> map = new HashMap<String, Object>();
    map.put("customer", aCustomer);
    map.put("customerDialogCtrl", this);
View Full Code Here

    final Branche branche = BranchSimpleSearchListBox.show(window_customerDialog);

    if (branche != null) {
      kunBranche.setValue(branche.getBraBezeichnung());
      Customer aCustomer = getCustomer();
      aCustomer.setBranche(branche);
      setCustomer(aCustomer);
    }
  }
View Full Code Here

    Branche branche = BranchAdvancedSearchListBox.show(window_customerDialog);

    if (branche != null) {
      kunBranche.setValue(branche.getBraBezeichnung());
      Customer aCustomer = getCustomer();
      aCustomer.setBranche(branche);
      setCustomer(aCustomer);
    }
  }
View Full Code Here

    Branche branche = BranchExtendedSearchListBox.show(window_customerDialog);

    if (branche != null) {
      kunBranche.setValue(branche.getBraBezeichnung());
      Customer aCustomer = getCustomer();
      aCustomer.setBranche(branche);
      setCustomer(aCustomer);
    }
  }
View Full Code Here

   *
   * @throws InterruptedException
   */
  private void doDelete() throws InterruptedException {

    final Customer aCustomer = getCustomer();

    // for the guys who delete all times our two demo customers with order
    // and orderPositions, we stop this.
    if (aCustomer.getId() == new Long(20) || aCustomer.getId() == new Long(21)) {
      ZksampleMessageUtils.doShowNotAllowedForDemoRecords();
      return;
    }

    // Show a confirm box
    String msg = Labels.getLabel("message.Question.Are_you_sure_to_delete_this_record") + "\n\n --> " + aCustomer.getKunName1() + " " + aCustomer.getKunName2() + " ," + aCustomer.getKunOrt();
    String title = Labels.getLabel("message.Deleting.Record");

    MultiLineMessageBox.doSetTemplate();
    if (MultiLineMessageBox.show(msg, title, MultiLineMessageBox.YES | MultiLineMessageBox.NO, Messagebox.QUESTION, true, new EventListener() {
      @Override
View Full Code Here

TOP

Related Classes of de.forsthaus.backend.model.Customer

Copyright © 2018 www.massapicom. 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.