Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
yd-backend
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
AutogeneralShanghai
yd-backend
Commits
cae32cdd
Commit
cae32cdd
authored
Oct 27, 2021
by
jianan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
客户告知书4
parent
cc8065f3
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
72 additions
and
23 deletions
+72
-23
yd-api/src/main/java/com/yd/api/practitioner/service/impl/PractitionerServiceImpl.java
+26
-21
yd-api/src/main/java/com/yd/api/practitioner/vo/informed/QueryInformedSheetListRequestVO.java
+7
-0
yd-api/src/main/java/com/yd/dal/entity/marketing/MktLeadsAssignedTrack.java
+11
-1
yd-api/src/main/java/com/yd/dal/entity/marketing/MktLeadsAssigneds.java
+10
-1
yd-api/src/main/java/com/yd/dal/mapper/marketing/MktLeadsAssignedTrackMapper.java
+3
-0
yd-api/src/main/resources/mapper/marketing/MktLeadsAssignedTrackMapper.xml
+13
-0
yd-api/src/main/resources/mapper/marketing/MktLeadsAssignedsMapper.xml
+2
-0
No files found.
yd-api/src/main/java/com/yd/api/practitioner/service/impl/PractitionerServiceImpl.java
View file @
cae32cdd
...
...
@@ -3612,16 +3612,24 @@ public class PractitionerServiceImpl implements com.yd.api.practitioner.service.
CommonResultIDResponseVO
resp
=
new
CommonResultIDResponseVO
();
try
{
// 先判断传入的客户姓名和客户电话与传入的customerId是否一致
AclCustomer
aclCustomer
=
aclCustomerDALService
.
findById
(
requestVO
.
getCustomerId
());
String
customerName
=
requestVO
.
getCustomerName
();
String
customerMobile
=
requestVO
.
getCustomerMobile
();
if
(!
customerMobile
.
equals
(
aclCustomer
.
getMobileNo
()))
{
AclCustomer
oldCustomer
=
aclCustomerDALService
.
findById
(
requestVO
.
getCustomerId
());
String
newName
=
requestVO
.
getCustomerName
();
String
newMobile
=
requestVO
.
getCustomerMobile
();
if
(!
newMobile
.
equals
(
oldCustomer
.
getMobileNo
()))
{
// 如果电话不一样,就更新商机的电话
MktLeadsAssigneds
mktLeadsAssigneds
=
new
MktLeadsAssigneds
();
mktLeadsAssigneds
.
setCustomerMobile
(
newMobile
);
mktLeadsAssignedsMapper
.
updateByPrimaryKeySelective
(
mktLeadsAssigneds
);
}
if
(!
newName
.
equals
(
oldCustomer
.
getName
()))
{
// 如果名字不一样,就更新商机的名字
MktLeadsAssigneds
mktLeadsAssigneds
=
new
MktLeadsAssigneds
();
mktLeadsAssigneds
.
setCustomerName
(
newName
);
mktLeadsAssignedsMapper
.
updateByPrimaryKeySelective
(
mktLeadsAssigneds
);
}
// 数据库实体
AclCustomer
newerCustomer
=
aclCustomerDALService
.
findByMobileNo
(
newMobile
);
AgPoInformed
informed
=
new
AgPoInformed
();
BeanUtils
.
copyProperties
(
requestVO
,
informed
);
informed
.
setCustomerId
(
acl
Customer
.
getId
());
informed
.
setCustomerId
(
newer
Customer
.
getId
());
informed
.
setStatus
(
"0"
);
informed
.
setIsActive
(
1
);
...
...
@@ -3637,7 +3645,7 @@ public class PractitionerServiceImpl implements com.yd.api.practitioner.service.
// 商机更新一条告知书待签署的记录
MktLeadsAssignedTrack
track
=
new
MktLeadsAssignedTrack
();
track
.
setCustomerId
(
requestVO
.
getLeadsAssignedId
());
track
.
setCustomerId
(
requestVO
.
getLeadsAssignedId
());
// 商机的id还是得用旧的customerId
track
.
setTrackTime
(
curDate
);
track
.
setCreatedBy
(
loginId
);
track
.
setCreatedAt
(
new
Date
());
...
...
@@ -3645,20 +3653,12 @@ public class PractitionerServiceImpl implements com.yd.api.practitioner.service.
track
.
setUpdatedBy
(
loginId
);
track
.
setUpdatorType
(
1
);
track
.
setUpdatedAt
(
new
Date
());
MdDropOptions
dropOption
=
systemConfigService
.
getDropOption
(
"
action_code
"
,
"customerNotice_0"
);
MdDropOptions
dropOption
=
systemConfigService
.
getDropOption
(
"
bizchance_promotion_action
"
,
"customerNotice_0"
);
track
.
setMdDropOptionId
(
dropOption
.
getId
());
track
.
setTrackScore
(
dropOption
.
getDropOptionScore
());
//保存
mktLeadsAssignedTrackDALService
.
saveTrack
(
track
);
// 如果名字不一样,就更新商机的名字
// if () {
// AclCustomer customer = aclCustomerDALService.findById(requestVO.getCustomerId());
// }
// MktLeadsAssigneds mktLeadsAssigneds = new MktLeadsAssigneds();
// mktLeadsAssigneds
// mktLeadsAssignedsMapper.updateByPrimaryKeySelective();
resp
.
setCommonResult
(
new
CommonResult
(
true
,
ZHBErrorConfig
.
getErrorInfo
(
"800000"
)));
resp
.
setId
(
informed
.
getId
());
}
catch
(
Exception
e
)
{
...
...
@@ -3742,17 +3742,18 @@ public class PractitionerServiceImpl implements com.yd.api.practitioner.service.
informed
.
setStatus
(
"1"
);
informedMapper
.
updateByPrimaryKeySelective
(
informed
);
// 商机更新一条告知书
待
签署的记录
// 商机更新一条告知书
已
签署的记录
MktLeadsAssignedTrack
track
=
new
MktLeadsAssignedTrack
();
track
.
setCustomerId
(
informed
.
getLeadsId
());
track
.
setInformedId
(
id
);
track
.
setCustomerId
(
informed
.
getCustomerId
());
track
.
setTrackTime
(
curDate
);
track
.
setCreatedBy
(
informed
.
getLeadsId
()
);
track
.
setCreatedBy
(
-
1L
);
track
.
setCreatedAt
(
curDate
);
track
.
setCreatorType
(
1
);
track
.
setUpdatedBy
(
informed
.
getLeadsId
()
);
track
.
setUpdatedBy
(
-
1L
);
track
.
setUpdatorType
(
1
);
track
.
setUpdatedAt
(
new
Date
());
MdDropOptions
dropOption
=
systemConfigService
.
getDropOption
(
"
action_code
"
,
"customerNotice_1"
);
MdDropOptions
dropOption
=
systemConfigService
.
getDropOption
(
"
bizchance_promotion_action
"
,
"customerNotice_1"
);
track
.
setMdDropOptionId
(
dropOption
.
getId
());
track
.
setTrackScore
(
dropOption
.
getDropOptionScore
());
//保存
...
...
@@ -3794,6 +3795,10 @@ public class PractitionerServiceImpl implements com.yd.api.practitioner.service.
informed
.
setInformedOssPath
(
ossPath
);
informedMapper
.
updateByPrimaryKeySelective
(
informed
);
MktLeadsAssignedTrack
track
=
new
MktLeadsAssignedTrack
();
track
.
setInformedId
(
id
);
mktLeadsAssignedTrackDALService
.
saveTrack
(
track
);
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
...
...
yd-api/src/main/java/com/yd/api/practitioner/vo/informed/QueryInformedSheetListRequestVO.java
View file @
cae32cdd
...
...
@@ -9,4 +9,11 @@ public class QueryInformedSheetListRequestVO {
private
String
customerMobile
;
private
String
policyNo
;
private
String
signDate
;
/**
* 系统标志,区分公司营业部和体系,1,分公司,2营业部,3,S1分部,4,S2体系,5,S3纵队
*/
private
String
systemFlag
;
private
Long
s3Id
;
private
Long
s2Id
;
private
Long
s1Id
;
}
yd-api/src/main/java/com/yd/dal/entity/marketing/MktLeadsAssignedTrack.java
View file @
cae32cdd
package
com
.
yd
.
dal
.
entity
.
marketing
;
import
lombok.Data
;
import
java.io.Serializable
;
import
java.util.Date
;
import
lombok.Data
;
/**
* ag_mkt_leads_assigned_track
...
...
@@ -96,6 +97,14 @@ public class MktLeadsAssignedTrack implements Serializable {
* 关联ag_mkt_schedule_task_tracking.id 日程表
*/
private
Long
scheduleTaskTrackingId
;
/**
* 告知书记录Id
*/
private
Long
informedId
;
/**
* 告知书url
*/
private
String
informedOssPath
;
private
static
final
long
serialVersionUID
=
1L
;
}
\ No newline at end of file
yd-api/src/main/java/com/yd/dal/entity/marketing/MktLeadsAssigneds.java
View file @
cae32cdd
package
com
.
yd
.
dal
.
entity
.
marketing
;
import
lombok.Data
;
import
java.math.BigDecimal
;
import
java.util.Date
;
import
lombok.Data
;
/**
* 商机线索指派表
...
...
@@ -24,6 +25,14 @@ public class MktLeadsAssigneds {
* 经纪人商机对应的客户id
*/
private
Long
customerId
;
/**
* 客户姓名
*/
private
String
customerName
;
/**
* 客户电话
*/
private
String
customerMobile
;
/**
* 首年保费
...
...
yd-api/src/main/java/com/yd/dal/mapper/marketing/MktLeadsAssignedTrackMapper.java
View file @
cae32cdd
...
...
@@ -33,4 +33,6 @@ public interface MktLeadsAssignedTrackMapper {
List
<
SalesScoreDetail
>
getSalesScoreDetailByPractitionerId
(
@Param
(
"practitionerId"
)
Long
practitionerId
,
@Param
(
"time"
)
String
time
);
void
deleteScheduleTrackById
(
Long
scheduleTrackId
);
int
updateInformedOssPathByInformedId
(
@Param
(
"informedOssPath"
)
String
InformedOssPath
,
@Param
(
"informedId"
)
Long
informedId
);
}
\ No newline at end of file
yd-api/src/main/resources/mapper/marketing/MktLeadsAssignedTrackMapper.xml
View file @
cae32cdd
...
...
@@ -19,6 +19,7 @@
<result
column=
"track_score"
jdbcType=
"INTEGER"
property=
"trackScore"
/>
<result
column=
"leads_assigned_id"
jdbcType=
"BIGINT"
property=
"leadsAssignedId"
/>
<result
column=
"track_time"
jdbcType=
"TIMESTAMP"
property=
"trackTime"
/>
<result
column=
"informed_oss_path"
jdbcType=
"VARCHAR"
property=
"informedOssPath"
/>
</resultMap>
<sql
id=
"Base_Column_List"
>
id, order_id, order_no, sales_notice, is_active, created_at, created_by, creator_type,
...
...
@@ -104,6 +105,9 @@
<if
test=
"scheduleTaskTrackingId != null"
>
schedule_task_tracking_id,
</if>
<if
test=
"informedId != null"
>
informed_id,
</if>
</trim>
<trim
prefix=
"values ("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"orderId != null"
>
...
...
@@ -157,6 +161,9 @@
<if
test=
"scheduleTaskTrackingId != null"
>
#{scheduleTaskTrackingId,jdbcType=BIGINT},
</if>
<if
test=
"informedId != null"
>
#{informedId,jdbcType=BIGINT},
</if>
</trim>
</insert>
<update
id=
"updateByPrimaryKeySelective"
parameterType=
"com.yd.dal.entity.marketing.MktLeadsAssignedTrack"
>
...
...
@@ -383,4 +390,9 @@
delete from ag_mkt_leads_assigned_track
where schedule_task_tracking_id = #{scheduleTrackId,jdbcType=BIGINT}
</delete>
<update
id=
"updateInformedOssPathByInformedId"
>
update ag_mkt_leads_assigned_track
set informed_oss_path = #{informedOssPath,jdbcType=VARCHAR}
where informed_id = #{informedId,jdbcType=BIGINT}
</update>
</mapper>
\ No newline at end of file
yd-api/src/main/resources/mapper/marketing/MktLeadsAssignedsMapper.xml
View file @
cae32cdd
...
...
@@ -12,6 +12,8 @@
<result
column=
"time_to_close"
jdbcType=
"TIMESTAMP"
property=
"timeToClose"
/>
<result
column=
"pieces"
jdbcType=
"INTEGER"
property=
"pieces"
/>
<result
column=
"remark"
jdbcType=
"LONGVARCHAR"
property=
"remark"
/>
<result
column=
"customer_name"
jdbcType=
"VARCHAR"
property=
"customerName"
/>
<result
column=
"customer_mobile"
jdbcType=
"VARCHAR"
property=
"customerMobile"
/>
<result
column=
"is_active"
jdbcType=
"INTEGER"
property=
"isActive"
/>
<result
column=
"created_at"
jdbcType=
"TIMESTAMP"
property=
"createdAt"
/>
<result
column=
"created_by"
jdbcType=
"BIGINT"
property=
"createdBy"
/>
...
...
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