Examples of Mechanic


Examples of com.expositds.ars.domain.user.Mechanic

  }

  @Test
  public void getMechanicByPliRegNoTest() {
    try {
      Mechanic mechanic = mechanicService.getMechanicByPliRegNo("1003000323");
      log.info(mechanic);
    } catch (WrongMechanicPliRegNoException e) {
      e.printStackTrace();
    }
   
View Full Code Here

Examples of com.expositds.ars.domain.user.Mechanic

    log.info(mechanic);
  }

  @Test
  public void updateMechanicTest() {
    Mechanic mechanic = mechanicService.getMechanicById(new Long(6));
    mechanic.setName("����");
   
    log.info(mechanic);
  }
View Full Code Here

Examples of net.caece.fmII.hibernate.Mechanic

        }

    }

    public void add() {
        Mechanic obj = (Mechanic) viewToObj(null);
        MechanicDao dao = new MechanicDao();
        add(dao, obj);
    }
View Full Code Here

Examples of net.caece.fmII.hibernate.Mechanic

    public boolean validate() {
        return true;
    }

    public Object viewToObj(Object obj) {
        Mechanic var = new Mechanic();
        if (obj != null) {
            try {
                BeanUtils.copyProperties(var, obj);
            } catch (Exception iae) {
                iae.printStackTrace();
            }
        }


        Radiogroup hasCitizenshipRG = (Radiogroup) getFellow("hasCitizenship");
        Textbox mechanicNameTB = (Textbox) getFellow("mechanicName");
        Textbox uniIdTB = (Textbox) getFellow("uniId");
        Combobox companyCB = (Combobox) getFellow("company");
        Radiogroup sexRG = (Radiogroup) getFellow("sex");

        var.setHasCitizenship(
                hasCitizenshipRG.getSelectedItem().getValue());
        var.setMechanicName(mechanicNameTB.getText());
        var.setUniId(uniIdTB.getText());
        if (companyCB.getSelectedItem() != null) {
            var.setCompany((Org) companyCB.getSelectedItem().getValue());
        }
        var.setSex(sexRG.getSelectedItem().getValue());


        Datebox birthdayDB = (Datebox) getFellow("birthday");
        Textbox homePhoneTB = (Textbox) getFellow("homePhone");
        Textbox mobileTB = (Textbox) getFellow("mobile");
        Textbox informPeopleTB = (Textbox) getFellow("informPeople");
        Textbox relationTB = (Textbox) getFellow("relation");

        var.setBirthday(birthdayDB.getValue());
        var.setHomePhone(homePhoneTB.getText());
        var.setMobile(mobileTB.getText());
        var.setInformPeople(informPeopleTB.getText());
        var.setRelation(relationTB.getText());


        Textbox informPhoneTB = (Textbox) getFellow("informPhone");
        Textbox deliveryZipTB = (Textbox) getFellow("deliveryZip");
        Textbox deliveryAddressTB = (Textbox) getFellow("deliveryAddress");
        Textbox billZipTB = (Textbox) getFellow("billZip");
        Textbox billAddressTB = (Textbox) getFellow("billAddress");

        var.setInformPhone(informPhoneTB.getText());
        var.setDeliveryZip(deliveryZipTB.getText());
        var.setDeliveryAddress(deliveryAddressTB.getText());
        var.setBillZip(billZipTB.getText());
        var.setBillAddress(billAddressTB.getText());

        return var;
    }
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.