Commit 4220a71f by jianan

0918-PEP得分详情加姓名字段

parent bb33282d
...@@ -27,13 +27,10 @@ import com.yd.api.practitioner.vo.setting.*; ...@@ -27,13 +27,10 @@ import com.yd.api.practitioner.vo.setting.*;
import com.yd.api.practitioner.vo.subordinate.SubordinateSystemMemberQueryRequestVO; import com.yd.api.practitioner.vo.subordinate.SubordinateSystemMemberQueryRequestVO;
import com.yd.api.practitioner.vo.subordinate.SubordinateSystemMemberQueryResponseVO; import com.yd.api.practitioner.vo.subordinate.SubordinateSystemMemberQueryResponseVO;
import com.yd.api.result.JsonResult; import com.yd.api.result.JsonResult;
import com.yd.dal.entity.practitioner.ScheduleTrack;
import org.apache.commons.codec.net.QCodec;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller; import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
import java.util.Map;
@Controller @Controller
@RestController @RestController
......
package com.yd.api.practitioner.service; package com.yd.api.practitioner.service;
import com.yd.api.practitioner.vo.sechedule.*; import com.yd.api.practitioner.vo.sechedule.*;
import org.springframework.stereotype.Service;
@Service("scheduleTrackService")
public interface ScheduleTrackService { public interface ScheduleTrackService {
AddScheduleTrackResponseVO insert(AddScheduleTrackRequestVO requestVO); AddScheduleTrackResponseVO insert(AddScheduleTrackRequestVO requestVO);
......
package com.yd.api.practitioner.service.impl; package com.yd.api.practitioner.service.impl;
import com.yd.api.customer.service.CustomerService;
import com.yd.api.practitioner.service.ScheduleTrackService; import com.yd.api.practitioner.service.ScheduleTrackService;
import com.yd.api.practitioner.vo.sechedule.*; import com.yd.api.practitioner.vo.sechedule.*;
import com.yd.api.result.CommonResult; import com.yd.api.result.CommonResult;
...@@ -34,6 +35,8 @@ public class ScheduleTrackServiceImpl implements ScheduleTrackService { ...@@ -34,6 +35,8 @@ public class ScheduleTrackServiceImpl implements ScheduleTrackService {
private MdDropOptionsDALService mdDropOptionsDALService; private MdDropOptionsDALService mdDropOptionsDALService;
@Autowired @Autowired
private MktLeadsAssignedTrackDALService mktLeadsAssignedTrackDALService; private MktLeadsAssignedTrackDALService mktLeadsAssignedTrackDALService;
@Autowired
private CustomerService customerService;
@Override @Override
public AddScheduleTrackResponseVO insert(AddScheduleTrackRequestVO requestVO) { public AddScheduleTrackResponseVO insert(AddScheduleTrackRequestVO requestVO) {
...@@ -328,6 +331,9 @@ public class ScheduleTrackServiceImpl implements ScheduleTrackService { ...@@ -328,6 +331,9 @@ public class ScheduleTrackServiceImpl implements ScheduleTrackService {
PEPScoreDetail.setCoachScore(coachScore); PEPScoreDetail.setCoachScore(coachScore);
PEPScoreDetail.setTrainScore(trainScore); PEPScoreDetail.setTrainScore(trainScore);
PEPScoreDetail.setMeetingScore(meetingScore); PEPScoreDetail.setMeetingScore(meetingScore);
// 根据practitionerId查询经纪人姓名
String name = scheduleTrackMapper.queryNameByPractitionerId(practitionerId);
PEPScoreDetail.setName(name);
resp.setDetail(PEPScoreDetail); resp.setDetail(PEPScoreDetail);
resp.setCommonResult(new CommonResult(true, ZHBErrorConfig.getErrorInfo("800000"))); resp.setCommonResult(new CommonResult(true, ZHBErrorConfig.getErrorInfo("800000")));
......
...@@ -5,6 +5,7 @@ import lombok.Data; ...@@ -5,6 +5,7 @@ import lombok.Data;
@Data @Data
public class PEPScoreDetail { public class PEPScoreDetail {
private String name;
private Long recruitScore; private Long recruitScore;
private Long saleScore; private Long saleScore;
private Long coachScore; private Long coachScore;
......
package com.yd.dal.mapper.marketing; package com.yd.dal.mapper.marketing;
import com.yd.dal.entity.practitioner.PEPScoreDetail;
import com.yd.dal.entity.practitioner.PersonalPEPScore; import com.yd.dal.entity.practitioner.PersonalPEPScore;
import com.yd.dal.entity.practitioner.PersonalSchedule; import com.yd.dal.entity.practitioner.PersonalSchedule;
import com.yd.dal.entity.practitioner.ScheduleTrack; import com.yd.dal.entity.practitioner.ScheduleTrack;
...@@ -28,5 +27,7 @@ public interface ScheduleTrackMapper { ...@@ -28,5 +27,7 @@ public interface ScheduleTrackMapper {
List<ScheduleTrack> queryPersonalScheduleListByTime(@Param("practitionerId")Long practitionerId, @Param("time")String time); List<ScheduleTrack> queryPersonalScheduleListByTime(@Param("practitionerId")Long practitionerId, @Param("time")String time);
void deleteScheduleTrackById(@Param("scheduleTrackId")Long scheduleTrackId); void deleteScheduleTrackById(@Param("scheduleTrackId")Long scheduleTrackId);
String queryNameByPractitionerId(Long practitionerId);
} }
...@@ -82,9 +82,9 @@ ...@@ -82,9 +82,9 @@
SELECT count(1) SELECT count(1)
FROM ag_mkt_schedule_task_tracking FROM ag_mkt_schedule_task_tracking
WHERE practitioner_id = #{practitionerId,jdbcType=BIGINT} WHERE practitioner_id = #{practitionerId,jdbcType=BIGINT}
AND to_days(created_at) = to_days(now())
AND task_time_from &lt; STR_TO_DATE(#{taskTimeEnd,jdbcType=VARCHAR}, '%H:%i:%s') AND task_time_from &lt; STR_TO_DATE(#{taskTimeEnd,jdbcType=VARCHAR}, '%H:%i:%s')
AND task_time_end &gt; STR_TO_DATE(#{taskTimeFrom,jdbcType=VARCHAR}, '%H:%i:%s') AND task_time_end &gt; STR_TO_DATE(#{taskTimeFrom,jdbcType=VARCHAR}, '%H:%i:%s')
</select> </select>
<select id="querySaleRecuitScoreFYC" resultType="com.yd.dal.entity.practitioner.PersonalPEPScore"> <select id="querySaleRecuitScoreFYC" resultType="com.yd.dal.entity.practitioner.PersonalPEPScore">
...@@ -201,4 +201,9 @@ ...@@ -201,4 +201,9 @@
delete from ag_mkt_schedule_task_tracking where id=#{scheduleTrackId,jdbcType=BIGINT} delete from ag_mkt_schedule_task_tracking where id=#{scheduleTrackId,jdbcType=BIGINT}
</delete> </delete>
<select id="queryNameByPractitionerId" resultType="String">
SELECT p.name from ag_acl_practitioner p
where p.id = #{practitionerId,jdbcType=BIGINT}
</select>
</mapper> </mapper>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment