Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
J
jiedao-api-boot-master
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lanbaoming
jiedao-api-boot-master
Commits
02b7ad8c
Commit
02b7ad8c
authored
Jun 12, 2024
by
liuzeheng
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
跟进记录
parent
f2d8257e
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
103 additions
and
24 deletions
+103
-24
CustomerFollowDO.java
...omer/dal/dataobject/customer/follow/CustomerFollowDO.java
+10
-0
CustomerFollowMapper.java
...ule/customer/dal/mysql/customer/CustomerFollowMapper.java
+62
-6
CustomerFollowPageDTO.java
...dao/module/customer/dto/follow/CustomerFollowPageDTO.java
+7
-4
CustomerFollowService.java
...vice/customer/complaint/follow/CustomerFollowService.java
+2
-5
CustomerFollowServiceImpl.java
.../customer/complaint/follow/CustomerFollowServiceImpl.java
+9
-7
CustomerFollowBaseVO.java
...ule/customer/vo/customer/follow/CustomerFollowBaseVO.java
+2
-0
CustomerFollowRespVO.java
...ule/customer/vo/customer/follow/CustomerFollowRespVO.java
+9
-0
CustomerFollowController.java
...oller/admin/customer/follow/CustomerFollowController.java
+2
-2
No files found.
yudao-module-customer/yudao-module-customer-core/src/main/java/cn/iocoder/yudao/module/customer/dal/dataobject/customer/follow/CustomerFollowDO.java
View file @
02b7ad8c
...
@@ -80,6 +80,16 @@ public class CustomerFollowDO extends BaseDO {
...
@@ -80,6 +80,16 @@ public class CustomerFollowDO extends BaseDO {
*/
*/
private
Long
adminId
;
private
Long
adminId
;
private
String
followNo
;
private
String
followResult
;
private
String
followFile
;
private
Date
nextFollowTime
;
private
String
nextPlan
;
/**
/**
* 跟进业务员
* 跟进业务员
...
...
yudao-module-customer/yudao-module-customer-core/src/main/java/cn/iocoder/yudao/module/customer/dal/mysql/customer/CustomerFollowMapper.java
View file @
02b7ad8c
...
@@ -8,6 +8,7 @@ import cn.iocoder.yudao.module.customer.dal.dataobject.customer.follow.CustomerF
...
@@ -8,6 +8,7 @@ import cn.iocoder.yudao.module.customer.dal.dataobject.customer.follow.CustomerF
import
cn.iocoder.yudao.module.customer.dto.follow.CustomerFollowPageDTO
;
import
cn.iocoder.yudao.module.customer.dto.follow.CustomerFollowPageDTO
;
import
cn.iocoder.yudao.module.customer.vo.customer.follow.CustomerFollowExportReqVO
;
import
cn.iocoder.yudao.module.customer.vo.customer.follow.CustomerFollowExportReqVO
;
import
cn.iocoder.yudao.module.customer.vo.customer.follow.CustomerFollowPageReqVO
;
import
cn.iocoder.yudao.module.customer.vo.customer.follow.CustomerFollowPageReqVO
;
import
cn.iocoder.yudao.module.customer.vo.customer.follow.CustomerFollowRespVO
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
org.apache.commons.lang3.StringUtils
;
import
org.apache.commons.lang3.StringUtils
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.apache.ibatis.annotations.Mapper
;
...
@@ -94,27 +95,79 @@ public interface CustomerFollowMapper extends BaseMapperX<CustomerFollowDO> {
...
@@ -94,27 +95,79 @@ public interface CustomerFollowMapper extends BaseMapperX<CustomerFollowDO> {
IPage
<
CustomerFollowDO
>
customerFollowPage
(
@Param
(
"mpPage"
)
IPage
<
CustomerFollowDO
>
mpPage
,
@Param
(
"query"
)
CustomerFollowPageReqVO
query
,
@Param
(
"types"
)
List
<
String
>
types
);
IPage
<
CustomerFollowDO
>
customerFollowPage
(
@Param
(
"mpPage"
)
IPage
<
CustomerFollowDO
>
mpPage
,
@Param
(
"query"
)
CustomerFollowPageReqVO
query
,
@Param
(
"types"
)
List
<
String
>
types
);
@ResultType
(
CustomerFollow
D
O
.
class
)
@ResultType
(
CustomerFollow
RespV
O
.
class
)
@Select
({
@Select
({
"<script>"
,
"<script>"
,
"select "
,
"select "
,
"f.*, "
,
"f.*,c.number, "
,
"t3.phone_new phone,"
,
"u1.nickname as creatorName , "
,
"u2.nickname as updaterName , "
,
"u.nickname as follow_user_name "
,
"u.nickname as follow_user_name "
,
"from ecw_customer_follow f "
,
"from ecw_customer_follow f "
,
"left join ecw_customer c on c.id = f.customer_id "
,
"left join system_user u on u.id = f.follow_user_Id "
,
"left join system_user u on u.id = f.follow_user_Id "
,
"left join system_user u1 on u1.id = f.creator "
,
"left join system_user u2 on u2.id = f.updater "
,
"LEFT JOIN ecw_customer_contacts t3 ON c.id = t3.customer_id AND t3.is_default = 1 and t3.deleted=0"
,
"where f.deleted = 0"
,
"where f.deleted = 0"
,
"<when test = 'types != null'>"
,
"<when test = 'types != null'>"
,
"AND f.`follow_type` in "
,
"AND f.`follow_type` in "
,
"<foreach item='type' index='index' collection='types' open='(' separator=',' close=')'>#{type}</foreach> "
,
"<foreach item='type' index='index' collection='types' open='(' separator=',' close=')'>#{type}</foreach> "
,
"</when>"
,
"</when>"
,
"<when test = 'query.followNo != null and query.followNo != \"\" '>"
,
"AND f.`follow_no` like concat('%',concat(#{query.followNo},'%'))"
,
"</when>"
,
"<when test = 'query.contactName != null and query.contactName != \"\" '>"
,
"AND f.`contact_name` like concat('%',concat(#{query.contactName},'%'))"
,
"</when>"
,
"<when test = 'query.beginCreateTime != null and query.endCreateTime != null '>"
,
"AND f.`create_time` between #{query.beginCreateTime} and #{query.endCreateTime}"
,
"</when>"
,
"<when test = 'query.beginFollowTime != null and query.endFollowTime != null '>"
,
"AND f.`follow_time` between #{query.beginFollowTime} and #{query.endFollowTime}"
,
"</when>"
,
"<when test = 'query.customerId != null'>"
,
"AND f.`customer_id` = #{query.customerId}"
,
"</when>"
,
"<when test = 'query.bizId != null'>"
,
"<when test = 'query.bizId != null'>"
,
"AND f.`biz_id` = #{query.bizId}"
,
"AND f.`biz_id` = #{query.bizId}"
,
"</when>"
,
"</when>"
,
"<when test = 'query.
bizNo != null and query.bizNo != \"\"
'>"
,
"<when test = 'query.
followUserId != null
'>"
,
"AND f.`
biz_no` like concat('%',concat(#{query.bizNo},'%'))
"
,
"AND f.`
follow_user_id` = #{query.followUserId}
"
,
"</when>"
,
"</when>"
,
"group by f.id "
,
" limit #{start}, #{size} "
,
"</script>"
})
List
<
CustomerFollowRespVO
>
getFollowPage
(
@Param
(
"start"
)
int
start
,
@Param
(
"size"
)
int
size
,
@Param
(
"query"
)
CustomerFollowPageDTO
query
,
@Param
(
"types"
)
List
<
String
>
types
);
@Select
({
"<script>"
,
"select count(*) "
,
"from ecw_customer_follow f "
,
"left join ecw_customer c on c.id = f.customer_id "
,
"left join system_user u on u.id = f.follow_user_Id "
,
"where f.deleted = 0"
,
"<when test = 'types != null'>"
,
"AND f.`follow_type` in "
,
"<foreach item='type' index='index' collection='types' open='(' separator=',' close=')'>#{type}</foreach> "
,
"</when>"
,
"<when test = 'query.followNo != null and query.followNo != \"\" '>"
,
"AND f.`follow_no` like concat('%',concat(#{query.followNo},'%'))"
,
"</when>"
,
"<when test = 'query.contactName != null and query.contactName != \"\" '>"
,
"AND f.`contact_name` like concat('%',concat(#{query.contactName},'%'))"
,
"</when>"
,
"<when test = 'query.beginCreateTime != null and query.endCreateTime != null '>"
,
"<when test = 'query.beginCreateTime != null and query.endCreateTime != null '>"
,
"AND f.`follow_time` between #{query.beginCreateTime} and #{query.endCreateTime}"
,
"AND f.`create_time` between #{query.beginCreateTime} and #{query.endCreateTime}"
,
"</when>"
,
"<when test = 'query.beginFollowTime != null and query.endFollowTime != null '>"
,
"AND f.`follow_time` between #{query.beginFollowTime} and #{query.endFollowTime}"
,
"</when>"
,
"</when>"
,
"<when test = 'query.customerId != null'>"
,
"<when test = 'query.customerId != null'>"
,
"AND f.`customer_id` = #{query.customerId}"
,
"AND f.`customer_id` = #{query.customerId}"
,
...
@@ -122,7 +175,10 @@ public interface CustomerFollowMapper extends BaseMapperX<CustomerFollowDO> {
...
@@ -122,7 +175,10 @@ public interface CustomerFollowMapper extends BaseMapperX<CustomerFollowDO> {
"<when test = 'query.bizId != null'>"
,
"<when test = 'query.bizId != null'>"
,
"AND f.`biz_id` = #{query.bizId}"
,
"AND f.`biz_id` = #{query.bizId}"
,
"</when>"
,
"</when>"
,
"<when test = 'query.followUserId != null'>"
,
"AND f.`follow_user_id` = #{query.followUserId}"
,
"</when>"
,
"</script>"
"</script>"
})
})
IPage
<
CustomerFollowDO
>
getFollowPage
(
@Param
(
"mpPage"
)
IPage
<
CustomerFollowDO
>
mpPage
,
@Param
(
"query"
)
CustomerFollowPageDTO
query
,
@Param
(
"types"
)
List
<
String
>
types
);
long
getFollowPageCount
(
@Param
(
"query"
)
CustomerFollowPageDTO
query
,
@Param
(
"types"
)
List
<
String
>
types
);
}
}
yudao-module-customer/yudao-module-customer-core/src/main/java/cn/iocoder/yudao/module/customer/dto/follow/CustomerFollowPageDTO.java
View file @
02b7ad8c
...
@@ -18,14 +18,14 @@ public class CustomerFollowPageDTO extends PageParam {
...
@@ -18,14 +18,14 @@ public class CustomerFollowPageDTO extends PageParam {
@ApiModelProperty
(
value
=
"跟进业务数据ID,回访类型的就是客户id,投诉跟进类型的就是投诉id, 商务洽谈就是报价单ID"
)
@ApiModelProperty
(
value
=
"跟进业务数据ID,回访类型的就是客户id,投诉跟进类型的就是投诉id, 商务洽谈就是报价单ID"
)
private
Long
bizId
;
private
Long
bizId
;
@ApiModelProperty
(
value
=
"
业务
编号"
)
@ApiModelProperty
(
value
=
"编号"
)
private
String
biz
No
;
private
String
follow
No
;
@ApiModelProperty
(
value
=
"跟进类型 参见字典customer_follow_type 查询参数可以多个使用','分割"
)
@ApiModelProperty
(
value
=
"跟进类型 参见字典customer_follow_type 查询参数可以多个使用','分割"
)
private
String
followType
;
private
String
followType
;
//
@ApiModelProperty(value = "联系人")
@ApiModelProperty
(
value
=
"联系人"
)
//
private String contactName;
private
String
contactName
;
@ApiModelProperty
(
value
=
"跟进业务员"
)
@ApiModelProperty
(
value
=
"跟进业务员"
)
private
Long
followUserId
;
private
Long
followUserId
;
...
@@ -48,4 +48,7 @@ public class CustomerFollowPageDTO extends PageParam {
...
@@ -48,4 +48,7 @@ public class CustomerFollowPageDTO extends PageParam {
@DateTimeFormat
(
pattern
=
FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND
)
@DateTimeFormat
(
pattern
=
FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND
)
@ApiModelProperty
(
value
=
"结束创建时间"
)
@ApiModelProperty
(
value
=
"结束创建时间"
)
private
Date
endCreateTime
;
private
Date
endCreateTime
;
@ApiModelProperty
(
value
=
"跟进方式"
)
private
Integer
followMethod
;
}
}
yudao-module-customer/yudao-module-customer-core/src/main/java/cn/iocoder/yudao/module/customer/service/customer/complaint/follow/CustomerFollowService.java
View file @
02b7ad8c
...
@@ -4,10 +4,7 @@ import cn.iocoder.yudao.framework.common.pojo.PageResult;
...
@@ -4,10 +4,7 @@ import cn.iocoder.yudao.framework.common.pojo.PageResult;
import
cn.iocoder.yudao.framework.mybatis.core.service.IService
;
import
cn.iocoder.yudao.framework.mybatis.core.service.IService
;
import
cn.iocoder.yudao.module.customer.dal.dataobject.customer.follow.CustomerFollowDO
;
import
cn.iocoder.yudao.module.customer.dal.dataobject.customer.follow.CustomerFollowDO
;
import
cn.iocoder.yudao.module.customer.dto.follow.CustomerFollowPageDTO
;
import
cn.iocoder.yudao.module.customer.dto.follow.CustomerFollowPageDTO
;
import
cn.iocoder.yudao.module.customer.vo.customer.follow.CustomerFollowCreateReqVO
;
import
cn.iocoder.yudao.module.customer.vo.customer.follow.*
;
import
cn.iocoder.yudao.module.customer.vo.customer.follow.CustomerFollowExportReqVO
;
import
cn.iocoder.yudao.module.customer.vo.customer.follow.CustomerFollowPageReqVO
;
import
cn.iocoder.yudao.module.customer.vo.customer.follow.CustomerFollowUpdateReqVO
;
import
javax.validation.Valid
;
import
javax.validation.Valid
;
import
java.util.Collection
;
import
java.util.Collection
;
...
@@ -67,7 +64,7 @@ public interface CustomerFollowService extends IService<CustomerFollowDO> {
...
@@ -67,7 +64,7 @@ public interface CustomerFollowService extends IService<CustomerFollowDO> {
PageResult
<
CustomerFollowDO
>
getCustomerFollowPage
(
CustomerFollowPageReqVO
pageReqVO
);
PageResult
<
CustomerFollowDO
>
getCustomerFollowPage
(
CustomerFollowPageReqVO
pageReqVO
);
PageResult
<
CustomerFollowDO
>
customerFollowPage
(
CustomerFollowPageReqVO
pageReqVO
);
PageResult
<
CustomerFollowDO
>
customerFollowPage
(
CustomerFollowPageReqVO
pageReqVO
);
PageResult
<
CustomerFollow
D
O
>
getFollowPage
(
CustomerFollowPageDTO
pageVO
);
PageResult
<
CustomerFollow
RespV
O
>
getFollowPage
(
CustomerFollowPageDTO
pageVO
);
/**
/**
* 获得客户投诉跟进列表, 用于 Excel 导出
* 获得客户投诉跟进列表, 用于 Excel 导出
*
*
...
...
yudao-module-customer/yudao-module-customer-core/src/main/java/cn/iocoder/yudao/module/customer/service/customer/complaint/follow/CustomerFollowServiceImpl.java
View file @
02b7ad8c
...
@@ -10,10 +10,7 @@ import cn.iocoder.yudao.module.customer.convert.customer.complaint.follow.Custom
...
@@ -10,10 +10,7 @@ import cn.iocoder.yudao.module.customer.convert.customer.complaint.follow.Custom
import
cn.iocoder.yudao.module.customer.dal.dataobject.customer.follow.CustomerFollowDO
;
import
cn.iocoder.yudao.module.customer.dal.dataobject.customer.follow.CustomerFollowDO
;
import
cn.iocoder.yudao.module.customer.dal.mysql.customer.CustomerFollowMapper
;
import
cn.iocoder.yudao.module.customer.dal.mysql.customer.CustomerFollowMapper
;
import
cn.iocoder.yudao.module.customer.dto.follow.CustomerFollowPageDTO
;
import
cn.iocoder.yudao.module.customer.dto.follow.CustomerFollowPageDTO
;
import
cn.iocoder.yudao.module.customer.vo.customer.follow.CustomerFollowCreateReqVO
;
import
cn.iocoder.yudao.module.customer.vo.customer.follow.*
;
import
cn.iocoder.yudao.module.customer.vo.customer.follow.CustomerFollowExportReqVO
;
import
cn.iocoder.yudao.module.customer.vo.customer.follow.CustomerFollowPageReqVO
;
import
cn.iocoder.yudao.module.customer.vo.customer.follow.CustomerFollowUpdateReqVO
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
jodd.util.StringUtil
;
import
jodd.util.StringUtil
;
import
org.apache.commons.lang3.StringUtils
;
import
org.apache.commons.lang3.StringUtils
;
...
@@ -99,14 +96,19 @@ public class CustomerFollowServiceImpl extends AbstractService<CustomerFollowMap
...
@@ -99,14 +96,19 @@ public class CustomerFollowServiceImpl extends AbstractService<CustomerFollowMap
}
}
@Override
@Override
public
PageResult
<
CustomerFollow
D
O
>
getFollowPage
(
CustomerFollowPageDTO
pageReqVO
)
{
public
PageResult
<
CustomerFollow
RespV
O
>
getFollowPage
(
CustomerFollowPageDTO
pageReqVO
)
{
PageVO
page
=
new
PageVO
();
PageVO
page
=
new
PageVO
();
page
.
setPage
(
pageReqVO
.
getPageNo
());
page
.
setPage
(
pageReqVO
.
getPageNo
());
page
.
setRows
(
pageReqVO
.
getPageSize
());
page
.
setRows
(
pageReqVO
.
getPageSize
());
page
.
setField
(
"f.id"
);
page
.
setField
(
"f.id"
);
IPage
<
CustomerFollowDO
>
mpPage
=
MyBatisUtils
.
buildPage
(
page
);
IPage
<
CustomerFollowDO
>
mpPage
=
MyBatisUtils
.
buildPage
(
page
);
customerFollowMapper
.
getFollowPage
(
mpPage
,
pageReqVO
,
StringUtils
.
isNotBlank
(
pageReqVO
.
getFollowType
())
?
Arrays
.
asList
(
pageReqVO
.
getFollowType
().
split
(
StrUtil
.
COMMA
))
:
null
);
// customerFollowMapper.getFollowPage(mpPage, pageReqVO, StringUtils.isNotBlank(pageReqVO.getFollowType()) ? Arrays.asList(pageReqVO.getFollowType().split(StrUtil.COMMA)) : null);
return
PageResult
.
of
(
mpPage
);
// return PageResult.of(mpPage);
int
start
=
(
page
.
getPage
()
-
1
)
*
page
.
getRows
();
int
size
=
page
.
getRows
();
List
<
CustomerFollowRespVO
>
list
=
customerFollowMapper
.
getFollowPage
(
start
,
size
,
pageReqVO
,
StringUtils
.
isNotBlank
(
pageReqVO
.
getFollowType
())
?
Arrays
.
asList
(
pageReqVO
.
getFollowType
().
split
(
StrUtil
.
COMMA
))
:
null
);
long
total
=
customerFollowMapper
.
getFollowPageCount
(
pageReqVO
,
StringUtils
.
isNotBlank
(
pageReqVO
.
getFollowType
())
?
Arrays
.
asList
(
pageReqVO
.
getFollowType
().
split
(
StrUtil
.
COMMA
))
:
null
);
return
new
PageResult
<>(
list
,
total
,
mpPage
.
getSize
(),
page
.
getPage
(),
(
total
+
mpPage
.
getSize
()
-
1
)
/
mpPage
.
getSize
());
}
}
@Override
@Override
...
...
yudao-module-customer/yudao-module-customer-core/src/main/java/cn/iocoder/yudao/module/customer/vo/customer/follow/CustomerFollowBaseVO.java
View file @
02b7ad8c
...
@@ -75,4 +75,6 @@ public class CustomerFollowBaseVO {
...
@@ -75,4 +75,6 @@ public class CustomerFollowBaseVO {
@ApiModelProperty
(
value
=
"最后更新人"
)
@ApiModelProperty
(
value
=
"最后更新人"
)
private
String
updater
;
private
String
updater
;
private
String
number
;
}
}
yudao-module-customer/yudao-module-customer-core/src/main/java/cn/iocoder/yudao/module/customer/vo/customer/follow/CustomerFollowRespVO.java
View file @
02b7ad8c
...
@@ -16,4 +16,13 @@ public class CustomerFollowRespVO extends CustomerFollowBaseVO {
...
@@ -16,4 +16,13 @@ public class CustomerFollowRespVO extends CustomerFollowBaseVO {
@ApiModelProperty
(
value
=
"创建时间"
,
required
=
true
)
@ApiModelProperty
(
value
=
"创建时间"
,
required
=
true
)
private
Date
createTime
;
private
Date
createTime
;
@ApiModelProperty
(
value
=
"创建人"
,
required
=
true
)
private
String
creator
;
private
String
creatorName
;
private
String
updaterName
;
private
String
phone
;
}
}
yudao-module-customer/yudao-module-customer-rest/src/main/java/cn/iocoder/yudao/module/customer/controller/admin/customer/follow/CustomerFollowController.java
View file @
02b7ad8c
...
@@ -84,8 +84,8 @@ public class CustomerFollowController {
...
@@ -84,8 +84,8 @@ public class CustomerFollowController {
@GetMapping
(
"/followPage"
)
@GetMapping
(
"/followPage"
)
@ApiOperation
(
"跟进列表数据-分页"
)
@ApiOperation
(
"跟进列表数据-分页"
)
public
CommonResult
<
PageResult
<
CustomerFollowRespVO
>>
getFollowPage
(
@Valid
CustomerFollowPageDTO
pageVO
)
{
public
CommonResult
<
PageResult
<
CustomerFollowRespVO
>>
getFollowPage
(
@Valid
CustomerFollowPageDTO
pageVO
)
{
PageResult
<
CustomerFollow
D
O
>
pageResult
=
customerFollowService
.
getFollowPage
(
pageVO
);
PageResult
<
CustomerFollow
RespV
O
>
pageResult
=
customerFollowService
.
getFollowPage
(
pageVO
);
return
success
(
CustomerFollowConvert
.
INSTANCE
.
convertPage
(
pageResult
)
);
return
success
(
pageResult
);
}
}
//@GetMapping("/export-excel")
//@GetMapping("/export-excel")
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment