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
89f910cb
Commit
89f910cb
authored
Oct 09, 2024
by
zhangfeng
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat-510: 会员注册,关联客户档案日志中的会员ID改为会员编号
parent
993be209
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
10 additions
and
7 deletions
+10
-7
CustomerApiImpl.java
...er/yudao/module/customer/service/api/CustomerApiImpl.java
+2
-2
CustomerApi.java
...cn/iocoder/yudao/module/ecw/api/customer/CustomerApi.java
+3
-1
UserRespDTO.java
...iocoder/yudao/module/member/api/user/dto/UserRespDTO.java
+1
-0
MemberUserServiceImpl.java
...dao/module/member/service/user/MemberUserServiceImpl.java
+1
-1
OrderServiceImpl.java
...dao/module/order/service/order/impl/OrderServiceImpl.java
+2
-2
OfferServiceImpl.java
...udao/module/sale/service/offer/impl/OfferServiceImpl.java
+1
-1
No files found.
yudao-module-customer/yudao-module-customer-core/src/main/java/cn/iocoder/yudao/module/customer/service/api/CustomerApiImpl.java
View file @
89f910cb
...
...
@@ -29,7 +29,7 @@ public class CustomerApiImpl implements CustomerApi {
@Resource
private
CountryService
countryService
;
public
void
associateCustomerAuto
(
String
areaCode
,
String
phone
,
Long
memberUserId
,
String
newName
)
{
public
void
associateCustomerAuto
(
String
areaCode
,
String
phone
,
Long
memberUserId
,
String
newName
,
String
memberCode
)
{
//先查询此用户是否有关联老客户
CustomerContactsDO
customerContactsDO
=
customerContactsService
.
getUniqueOneAndValidate
(
areaCode
,
phone
,
null
);
...
...
@@ -82,7 +82,7 @@ public class CustomerApiImpl implements CustomerApi {
customerCreateReqVO
.
setCustomerContacts
(
Arrays
.
asList
(
customerContactsCreateReqVO
));
customerCreateReqVO
.
setCustomerOperateLogRemark
(
"会员注册关联创建客户. 会员
id:"
+
memberUserId
+
"; 电话:"
+
phone
);
customerCreateReqVO
.
setCustomerOperateLogRemark
(
"会员注册关联创建客户. 会员
编号:"
+
memberCode
+
"; 电话:"
+
phone
);
customerService
.
createCustomer
(
customerCreateReqVO
);
}
...
...
yudao-module-ecw/yudao-module-ecw-api/src/main/java/cn/iocoder/yudao/module/ecw/api/customer/CustomerApi.java
View file @
89f910cb
...
...
@@ -2,8 +2,10 @@ package cn.iocoder.yudao.module.ecw.api.customer;
public
interface
CustomerApi
{
void
associateCustomerAuto
(
String
areaCode
,
String
phone
,
Long
userId
,
String
newName
);
void
associateCustomerAuto
(
String
areaCode
,
String
phone
,
Long
userId
,
String
newName
,
String
memberCode
);
void
approvalCustomerDelay
(
String
approveId
,
Integer
result
);
void
approvalCustomerTransfer
(
String
approveId
,
Integer
result
);
}
yudao-module-member/yudao-module-member-api/src/main/java/cn/iocoder/yudao/module/member/api/user/dto/UserRespDTO.java
View file @
89f910cb
...
...
@@ -50,5 +50,6 @@ public class UserRespDTO {
private
Integer
country
;
private
Integer
city
;
private
String
code
;
}
yudao-module-member/yudao-module-member-impl/src/main/java/cn/iocoder/yudao/module/member/service/user/MemberUserServiceImpl.java
View file @
89f910cb
...
...
@@ -236,7 +236,7 @@ public class MemberUserServiceImpl implements MemberUserService {
clientInternalMessageApi
.
createInternalMessage
(
dto
);
//关联或创建后端客户
customerApi
.
associateCustomerAuto
(
areacode
,
mobile
,
user
.
getId
(),
englishName
);
customerApi
.
associateCustomerAuto
(
areacode
,
mobile
,
user
.
getId
(),
englishName
,
user
.
getCode
()
);
applicationContext
.
publishEvent
(
new
MemberRegEvent
(
user
.
getId
()));
...
...
yudao-module-order/yudao-module-order-core/src/main/java/cn/iocoder/yudao/module/order/service/order/impl/OrderServiceImpl.java
View file @
89f910cb
...
...
@@ -512,7 +512,7 @@ public class OrderServiceImpl extends AbstractService<OrderMapper, OrderDO> impl
// 如果客户联系人为空,则创建新的客户信息,重新查询
customerApi
.
associateCustomerAuto
(
memberUserDO
.
getAreaCode
(),
memberUserDO
.
getMobile
(),
memberUserDO
.
getId
(),
memberUserDO
.
getNickname
());
memberUserDO
.
getNickname
()
,
memberUserDO
.
getCode
()
);
customerContacts
=
customerContactsService
.
getOne
(
new
LambdaQueryWrapper
<
CustomerContactsDO
>()
.
and
(
we
->
we
.
eq
(
CustomerContactsDO:
:
getUserid
,
memberUserDO
.
getId
())
.
or
()
...
...
@@ -2872,7 +2872,7 @@ public class OrderServiceImpl extends AbstractService<OrderMapper, OrderDO> impl
orderConsignorDO
.
setUpdater
(
updater
);
if
(
Objects
.
isNull
(
customerContacts
))
{
// 如果客户联系人为空,则创建新的客户信息,重新查询
customerApi
.
associateCustomerAuto
(
memberUserDO
.
getAreaCode
(),
memberUserDO
.
getMobile
(),
memberUserDO
.
getId
(),
memberUserDO
.
getNickname
());
customerApi
.
associateCustomerAuto
(
memberUserDO
.
getAreaCode
(),
memberUserDO
.
getMobile
(),
memberUserDO
.
getId
(),
memberUserDO
.
getNickname
()
,
memberUserDO
.
getCode
()
);
customerContacts
=
customerContactsService
.
getOne
(
new
LambdaQueryWrapper
<
CustomerContactsDO
>()
.
and
(
we
->
we
.
eq
(
CustomerContactsDO:
:
getUserid
,
memberUserDO
.
getId
())
.
or
()
...
...
yudao-module-sale/yudao-module-sale-core/src/main/java/cn/iocoder/yudao/module/sale/service/offer/impl/OfferServiceImpl.java
View file @
89f910cb
...
...
@@ -1433,7 +1433,7 @@ public class OfferServiceImpl extends AbstractService<OfferMapper, OfferDO> impl
customerContactsDOList
=
customerContactsService
.
getByPhone
(
userRespDTO
.
getAreaCode
(),
userRespDTO
.
getMobile
());
// 当此客户端用户不存在绑定的有效客户信息时需要去关联创建
if
(
CollectionUtil
.
isEmpty
(
customerContactsDOList
)
||
customerContactsDOList
.
size
()
==
0
)
{
customerApi
.
associateCustomerAuto
(
userRespDTO
.
getAreaCode
(),
userRespDTO
.
getMobile
(),
userRespDTO
.
getId
(),
userRespDTO
.
getNickname
());
customerApi
.
associateCustomerAuto
(
userRespDTO
.
getAreaCode
(),
userRespDTO
.
getMobile
(),
userRespDTO
.
getId
(),
userRespDTO
.
getNickname
()
,
userRespDTO
.
getCode
()
);
customerContactsDOList
=
customerContactsService
.
getByMemberUserId
(
loginUser
.
getId
());
}
else
{
customerContactsService
.
update
(
new
LambdaUpdateWrapper
<
CustomerContactsDO
>()
...
...
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