package cn.momia.api.user.dto;

import org.apache.commons.lang3.StringUtils;

public class Contact extends User {
    private User user;

    public Contact(User user) {
        this.user = user;
    }

    public String getName() {
        if (StringUtils.isBlank(user.getName())) return user.getNickName();
        return user.getName();
    }

    public String getMobile() {
        return user.getMobile();
    }
}

@@ -96,75 +96,156 @@
 act 
-extends User %7B%0A    private User user;%0A%0A    public Contact(User user
+%7B%0A    private String name;%0A    private String mobile;%0A%0A    public String getName() %7B%0A        return name;%0A    %7D%0A%0A    public void setName(String name
 ) %7B%0A
@@ -261,19 +261,19 @@
 his.
-user = user
+name = name
 ;%0A  
@@ -302,29 +302,206 @@
  get
-Name() %7B%0A        if (
+Mobile() %7B%0A        return mobile;%0A    %7D%0A%0A    public void setMobile(String mobile) %7B%0A        this.mobile = mobile;%0A    %7D%0A%0A    public Contact() %7B%7D%0A%0A    public Contact(User user) %7B%0A        this.name = 
 Stri
@@ -535,16 +535,10 @@
 e())
-) return
+ ?
  use
@@ -556,24 +556,10 @@
 me()
-;%0A        return
+ :
  use
@@ -579,57 +579,25 @@
     
-%7D%0A%0A
     
-public String getMobile() %7B%0A        return
+this.mobile =
  use

fix bug