Browse Source

服务跟进导出后台修改开发

anderx 7 years ago
parent
commit
d6b42a14e3

+ 1 - 1
src/main/java/com/goafanti/common/mapper/DemandFollowMapper.xml

@@ -353,7 +353,7 @@
       select df.id ,df.demand_id as demandId,df.organization,df.contacts,df.contact_mobile contactMobile,df.remark,
   df.`result`,df.last_follow_time as lastFollowTime,d.name,d.employer_name as employerName,df.sources,
   d.employer_contacts_mobile as employerContactsMobile,d.employer_contacts_mailbox as employerContactsMailbox,
-  d.create_time as createTime, a.name as adminName 
+  d.create_time as createTime, a.name as adminName ,df.sources
     from  demand_follow df
     left join demand d on df.demand_id=d.id
     left join admin a on d.tech_broker_id=a.id 

+ 5 - 1
src/main/java/com/goafanti/common/model/DemandFollowDetail.java

@@ -34,10 +34,13 @@ public class DemandFollowDetail {
 	 */
 	private Date createTime;
 
+	
+	
 	/**
 	 * This method was generated by MyBatis Generator. This method returns the value of the database column demand_follow_detail.id
 	 * @return  the value of demand_follow_detail.id
 	 * @mbg.generated  Thu Mar 22 14:44:52 CST 2018
+	 *
 	 */
 	public String getId() {
 		return id;
@@ -124,7 +127,6 @@ public class DemandFollowDetail {
 		this.createTime = createTime;
 	}
 	
-
 	public String getCreateTimeFormattedDate(){
 		if (null==getCreateTime()) {
 			return null;
@@ -133,5 +135,7 @@ public class DemandFollowDetail {
 		}
 		
 	}
+
+	
 	
 }

+ 1 - 1
src/main/java/com/goafanti/demand/bo/DemandFollowDetailListBo.java

@@ -15,7 +15,7 @@ public class DemandFollowDetailListBo  extends DemandFollowDetail{
 		if (null==getCreateTime()) {
 			return null;
 		}else {
-			return DateFormatUtils.format(getCreateTime(), AFTConstants.YYYYMMDDHHMMSS);
+			return DateFormatUtils.format(getCreateTime(), AFTConstants.YYYYMMDD);
 		}
 		
 	}

+ 14 - 16
src/main/java/com/goafanti/demand/bo/DemandFollowListBo.java

@@ -1,6 +1,7 @@
 package com.goafanti.demand.bo;
 
-import java.util.Date;
+
+import java.util.List;
 
 import org.apache.commons.lang3.time.DateFormatUtils;
 
@@ -12,8 +13,9 @@ public class DemandFollowListBo extends DemandFollow{
 	private String employerName;
 	private String employerContactsMobile;
 	private String employerContactsMailbox;
-	private Date createTime;
-	private String adminName; 
+	private String adminName;
+	private List<?> demandFollowDetail;
+	
 	
 	public String getName() {
 		return name;
@@ -39,9 +41,7 @@ public class DemandFollowListBo extends DemandFollow{
 	public void setEmployerContactsMailbox(String employerContactsMailbox) {
 		this.employerContactsMailbox = employerContactsMailbox;
 	}
-	public Date getCreateTime() {
-		return createTime;
-	}
+	
 	public String getLastFollowTimeFormattedDate() {
 		if (getLastFollowTime() == null) {
 			return null;
@@ -49,20 +49,18 @@ public class DemandFollowListBo extends DemandFollow{
 			return DateFormatUtils.format(getLastFollowTime(), AFTConstants.YYYYMMDD);
 		}
 	}
-	public String getCreateTimeFormattedDate() {
-		if (this.createTime == null) {
-			return null;
-		} else {
-			return DateFormatUtils.format(getCreateTime(), AFTConstants.YYYYMMDDHHMMSS);
-		}
-	}
-	public void setCreateTime(Date createTime) {
-		this.createTime = createTime;
-	}
+	
+	
 	public String getAdminName() {
 		return adminName;
 	}
 	public void setAdminName(String adminName) {
 		this.adminName = adminName;
 	}
+	public List<?> getDemandFollowDetail() {
+		return demandFollowDetail;
+	}
+	public void setDemandFollowDetail(List<?> demandFollowDetail) {
+		this.demandFollowDetail = demandFollowDetail;
+	}
 }

+ 4 - 1
src/main/java/com/goafanti/demand/bo/DemandManageDetailBo.java

@@ -1,9 +1,11 @@
 package com.goafanti.demand.bo;
 
 import java.math.BigDecimal;
+import java.util.List;
 
 import com.fasterxml.jackson.annotation.JsonFormat;
 import com.fasterxml.jackson.annotation.JsonFormat.Shape;
+import com.goafanti.common.model.DemandFollowDetail;
 
 public class DemandManageDetailBo extends DemandManageListBo {
 
@@ -51,6 +53,8 @@ public class DemandManageDetailBo extends DemandManageListBo {
 
 	private String      coverImg;
 	
+	
+	
 
 	public String getEmployerAddress() {
 		return employerAddress;
@@ -229,5 +233,4 @@ public class DemandManageDetailBo extends DemandManageListBo {
 		this.coverImg = coverImg;
 	}
 
-
 }

+ 1 - 1
src/main/java/com/goafanti/demand/controller/AdminDemandApiController.java

@@ -315,7 +315,7 @@ public class AdminDemandApiController extends CertifyApiController {
 	 * 组织用户详情(个人组织合并)
 	 */
 	@RequestMapping(value = "/orgDemandDetail", method = RequestMethod.GET)
-	public Result orgDemandDetail(String id,int dataCategory) {
+	public Result orgDemandDetail(String id,Integer dataCategory) {
 		Result res = new Result();
 
 		if (StringUtils.isBlank(id)) {

+ 7 - 1
src/main/java/com/goafanti/demand/service/impl/DemandFollowServiceImpl.java

@@ -79,7 +79,13 @@ public class DemandFollowServiceImpl extends BaseMybatisDao<DemandFollowMapper>
 		}
 		Map<String, Object> params=new HashMap<String, Object>();
 		params.put("id", id);
-		return (Pagination<DemandFollowListBo>) findPage("findDemandFollowListByPage", "findDemandFollowCount", params, pNo, pSize);
+		Pagination<DemandFollowListBo> p=(Pagination<DemandFollowListBo>) findPage("findDemandFollowListByPage", "findDemandFollowCount", params, pNo, pSize);
+		List<DemandFollowListBo> list =(List<DemandFollowListBo>) p.getList();
+		for (DemandFollowListBo d : list) {
+			d.setDemandFollowDetail(demandFollowDetailMapper.selectDemandFollowDetail(d.getId()));
+			
+		}
+		return p;
 	}
 
 	@Override

+ 6 - 0
src/main/java/com/goafanti/demand/service/impl/DemandServiceImpl.java

@@ -24,6 +24,7 @@ import com.goafanti.common.dao.AchievementDemandMapper;
 
 import com.goafanti.common.dao.AchievementKeywordMapper;
 import com.goafanti.common.dao.AchievementMapper;
+import com.goafanti.common.dao.DemandFollowDetailMapper;
 import com.goafanti.common.dao.DemandInterestMapper;
 import com.goafanti.common.dao.DemandKeywordMapper;
 import com.goafanti.common.dao.DemandMapper;
@@ -52,6 +53,7 @@ import com.goafanti.common.enums.UserType;
 import com.goafanti.common.model.AchievementDemand;
 import com.goafanti.common.model.AchievementDemandCount;
 import com.goafanti.common.model.Demand;
+import com.goafanti.common.model.DemandFollowDetail;
 import com.goafanti.common.model.DemandKeyword;
 import com.goafanti.common.model.Notice;
 import com.goafanti.common.model.OrganizationIdentity;
@@ -113,6 +115,9 @@ public class DemandServiceImpl extends BaseMybatisDao<DemandMapper> implements D
 	private UserInterestMapper	userInterestMapper;
 	@Autowired
 	ProjectInterestMapper	projectInterestMapper; 
+	
+	
+	DemandFollowDetailMapper	demandFollowDetailMapper;
 
 	@SuppressWarnings("unchecked")
 	@Override
@@ -301,6 +306,7 @@ public class DemandServiceImpl extends BaseMybatisDao<DemandMapper> implements D
 
 	@Override
 	public DemandManageDetailBo selectOrgDemandDetail(String id) {
+		
 		return demandMapper.selectOrgDemandDetail(id);
 	}