package de.rwth.idsg.velocity.web.rest.dto.view;

import lombok.Getter;
import lombok.ToString;
import org.joda.time.LocalDate;

/**
 * Created by swam on 05/06/14.
 */
@ToString(includeFieldNames = true)
public class ViewCustomerDTO {

    @Getter private String login;
    @Getter private String customerId;
    @Getter private String fullName;
    @Getter private String mailAddress;
    @Getter private Boolean isActivated;
    @Getter private LocalDate birthday;
    @Getter private String cardId;

    public ViewCustomerDTO(String login, String customerId, String firstname, String lastname,
                           String mailAddress, Boolean isActivated,
                           LocalDate birthday, String cardId) {
        this.login = login;
        this.customerId = customerId;
        this.fullName = firstname + " " + lastname;
        this.mailAddress = mailAddress;
        this.isActivated = isActivated;
        this.birthday = birthday;
        this.cardId = cardId;
    }

}
@@ -43,16 +43,154 @@
 .view;%0A%0A
+import com.fasterxml.jackson.databind.annotation.JsonSerialize;%0Aimport de.rwth.idsg.velocity.web.rest.dto.util.CustomLocalDateSerializer;%0A
 import l
@@ -583,27 +583,83 @@
 ate 
-LocalDate birthday;
+String cardId;%0A%0A    @JsonSerialize(using = CustomLocalDateSerializer.class)
 %0A   
@@ -658,32 +658,36 @@
 ass)%0A    @Getter
+%0A   
  private String 
@@ -675,37 +675,42 @@
     private 
-String cardId
+LocalDate birthday
 ;%0A%0A    publi

json serialize birthday