Esempio n. 1
0
  public Customer modifyCustomer(
      Integer customerId,
      String name,
      String tel,
      String occupation,
      String identityCard,
      String birthday,
      String email,
      String note,
      Integer introducerTypeId,
      String introducer) {
    subaruDao.modifyCustomer(
        customerId,
        name,
        tel,
        occupation,
        identityCard,
        birthday,
        email,
        note,
        introducerTypeId,
        introducer);

    return null;
  }
Esempio n. 2
0
  public Customer createCustomer(
      String name,
      String tel,
      String occupation,
      String identityCard,
      String birthday,
      String email,
      String note,
      Integer introducerType,
      String introducer) {
    subaruDao.createCustomer(
        name, tel, occupation, identityCard, birthday, email, note, introducerType, introducer);

    return null;
  }
Esempio n. 3
0
 public Customer getCustomer(String customerTel) {
   Map<String, Object> infos = subaruDao.getCustomerByTel(customerTel);
   if (!infos.isEmpty()) {
     String introducerTypeId = infos.get("introducerTypeId").toString();
     Customer customer =
         new Customer(
             Integer.valueOf(infos.get("customerId").toString()),
             infos.get("name").toString(),
             infos.get("customerTel").toString(),
             infos.get("occupation").toString(),
             infos.get("identityCard").toString(),
             infos.get("birthday").toString(),
             infos.get("email").toString(),
             infos.get("note").toString(),
             StringUtils.hasText(introducerTypeId) ? Integer.parseInt(introducerTypeId) : 0,
             infos.get("introducer").toString(),
             0);
     return customer;
   }
   return null;
 }
Esempio n. 4
0
 public void delCustomer(Integer id) {
   subaruDao.delCustomer(id);
 }
Esempio n. 5
0
 public void delCustomer(String customerTel) {
   subaruDao.delCustomer(customerTel);
 }