|  |  | 
 |  |  | import com.zy.crm.manager.service.CompanyService; | 
 |  |  | import com.zy.crm.manager.service.CstmrService; | 
 |  |  | import com.zy.crm.system.entity.Dept; | 
 |  |  | import com.zy.crm.system.entity.Dic; | 
 |  |  | import com.zy.crm.system.entity.Host; | 
 |  |  | import com.zy.crm.system.entity.User; | 
 |  |  | import com.zy.crm.system.service.DeptService; | 
 |  |  | import com.zy.crm.system.service.DicService; | 
 |  |  | import com.zy.crm.system.service.HostService; | 
 |  |  | import com.zy.crm.system.service.UserService; | 
 |  |  | import io.swagger.annotations.ApiModelProperty; | 
 |  |  | 
 |  |  |     private Long cstmrId; | 
 |  |  |  | 
 |  |  |     /** | 
 |  |  |      * 客户代号 | 
 |  |  |      * 项目代号 | 
 |  |  |      */ | 
 |  |  |     @ApiModelProperty(value= "客户代号") | 
 |  |  |     @ApiModelProperty(value= "项目代号") | 
 |  |  |     private String uuid; | 
 |  |  |  | 
 |  |  |     /** | 
 |  |  |      * 客户名称 | 
 |  |  |      * 跟踪项目名称 | 
 |  |  |      */ | 
 |  |  |     @ApiModelProperty(value= "客户名称") | 
 |  |  |     @ApiModelProperty(value= "跟踪项目名称") | 
 |  |  |     private String name; | 
 |  |  |  | 
 |  |  |     /** | 
 |  |  |      * 总金额 | 
 |  |  |      * 项目总金额 | 
 |  |  |      */ | 
 |  |  |     @ApiModelProperty(value= "总金额") | 
 |  |  |     @ApiModelProperty(value= "项目总金额") | 
 |  |  |     private Double money; | 
 |  |  |  | 
 |  |  |     /** | 
 |  |  | 
 |  |  |         if (Cools.isEmpty(this.createTime)){ | 
 |  |  |             return ""; | 
 |  |  |         } | 
 |  |  |         return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.createTime); | 
 |  |  |         return new SimpleDateFormat("yyyy-MM-dd HH:mm").format(this.createTime); | 
 |  |  |     } | 
 |  |  |  | 
 |  |  |     public String getUpdateBy$(){ | 
 |  |  | 
 |  |  |         if (Cools.isEmpty(this.updateTime)){ | 
 |  |  |             return ""; | 
 |  |  |         } | 
 |  |  |         return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.updateTime); | 
 |  |  |         return new SimpleDateFormat("yyyy-MM-dd HH:mm").format(this.updateTime); | 
 |  |  |     } | 
 |  |  |  | 
 |  |  |     @TableField(exist = false) | 
 |  |  |     private String pcd; | 
 |  |  |  | 
 |  |  |     public String getPcd() { | 
 |  |  |         StringBuilder sb = new StringBuilder(); | 
 |  |  |         if (!Cools.isEmpty(province)) { | 
 |  |  |             sb.append(province).append(","); | 
 |  |  |         } | 
 |  |  |         if (!Cools.isEmpty(city)) { | 
 |  |  |             sb.append(city).append(","); | 
 |  |  |         } | 
 |  |  |         if (!Cools.isEmpty(district)) { | 
 |  |  |             sb.append(district).append(","); | 
 |  |  |         } | 
 |  |  |         String s = sb.toString(); | 
 |  |  |         if (s.endsWith(",")) { | 
 |  |  |             s = s.substring(0, s.length() - 1); | 
 |  |  |         } | 
 |  |  |         return s; | 
 |  |  |     } | 
 |  |  |  | 
 |  |  |     public String getPcd$() { | 
 |  |  |         StringBuilder sb = new StringBuilder(); | 
 |  |  |         DicService service = SpringUtils.getBean(DicService.class); | 
 |  |  |         if (!Cools.isEmpty(province)) { | 
 |  |  |             Dic provinceDic = service.selectById(province); | 
 |  |  |             if (!Cools.isEmpty(provinceDic)) { | 
 |  |  |                 sb.append(provinceDic.getName()).append(","); | 
 |  |  |             } | 
 |  |  |         } | 
 |  |  |         if (!Cools.isEmpty(city)) { | 
 |  |  |             Dic cityDic = service.selectById(city); | 
 |  |  |             if (!Cools.isEmpty(cityDic)) { | 
 |  |  |                 sb.append(cityDic.getName()).append(","); | 
 |  |  |             } | 
 |  |  |         } | 
 |  |  |         if (!Cools.isEmpty(district)) { | 
 |  |  |             Dic districtDic = service.selectById(district); | 
 |  |  |             if (!Cools.isEmpty(districtDic)) { | 
 |  |  |                 sb.append(districtDic.getName()).append(","); | 
 |  |  |             } | 
 |  |  |         } | 
 |  |  |         String s = sb.toString(); | 
 |  |  |         if (s.endsWith(",")) { | 
 |  |  |             s = s.substring(0, s.length() - 1); | 
 |  |  |         } | 
 |  |  |         return s; | 
 |  |  |     } | 
 |  |  |  | 
 |  |  |     public void setPcd(String pcd) { | 
 |  |  |         this.pcd = pcd; | 
 |  |  |         if (!Cools.isEmpty(pcd)) { | 
 |  |  |             String[] split = this.pcd.split(","); | 
 |  |  |             for (int i = 0;i< split.length; i++) { | 
 |  |  |                 switch (i) { | 
 |  |  |                     case 0: | 
 |  |  |                         this.province = split[0]; | 
 |  |  |                         break; | 
 |  |  |                     case 1: | 
 |  |  |                         this.city = split[1]; | 
 |  |  |                         break; | 
 |  |  |                     case 2: | 
 |  |  |                         this.district = split[2]; | 
 |  |  |                         break; | 
 |  |  |                     default: | 
 |  |  |                         break; | 
 |  |  |                 } | 
 |  |  |             } | 
 |  |  |         } else { | 
 |  |  |             this.province = ""; | 
 |  |  |             this.city = ""; | 
 |  |  |             this.district = ""; | 
 |  |  |         } | 
 |  |  |     } | 
 |  |  |  | 
 |  |  |  |