示例#1
0
  public boolean delete() {

    if (accountTypeDTO.getCustomers().size() > 0) {
      return false;
    }

    for (AccountInformationTypeDTO ait : accountTypeDTO.getInformationTypes()) {
      new AccountInformationTypeBL(ait.getId()).delete();
    }
    accountTypeDTO.getInformationTypes().clear();
    accountTypeDAS.delete(accountTypeDTO);
    return true;
  }
示例#2
0
  public static final AccountTypeWS getWS(AccountTypeDTO dto) {

    return getWS(
        dto.getId(),
        dto.getCompany().getId(),
        dto.getInvoiceDesign(),
        dto.getDateCreated(),
        dto.getCreditNotificationLimit1(),
        dto.getCreditNotificationLimit2(),
        dto.getCreditLimit(),
        dto.getInvoiceDeliveryMethod(),
        dto.getCurrencyId(),
        dto.getLanguageId(),
        dto.getDescription(),
        UserBL.convertMainSubscriptionToWS(dto.getBillingCycle()),
        dto.getInformationTypes(),
        dto.getPaymentMethodTypes(),
        dto.getPreferredNotificationAitId());
  }