Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
haoban-manage3.0
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
haoban3.0
haoban-manage3.0
Commits
8c233bfe
Commit
8c233bfe
authored
Feb 14, 2022
by
yaosai
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'bugfix-0214' into 'master'
修复导购删除bug和导购重复bug See merge request
!166
parents
fbedf0c7
148f6b10
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
38 additions
and
2 deletions
+38
-2
StaffMapper.java
...com/gic/haoban/manage/service/dao/mapper/StaffMapper.java
+12
-0
StaffService.java
...a/com/gic/haoban/manage/service/service/StaffService.java
+8
-1
StaffServiceImpl.java
.../haoban/manage/service/service/impl/StaffServiceImpl.java
+5
-0
StaffApiServiceImpl.java
.../manage/service/service/out/impl/StaffApiServiceImpl.java
+3
-0
StaffMapper.xml
...manage3-service/src/main/resources/mapper/StaffMapper.xml
+9
-0
ClerkController.java
...com/gic/haoban/manage/web/controller/ClerkController.java
+1
-1
No files found.
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/dao/mapper/StaffMapper.java
View file @
8c233bfe
...
@@ -132,4 +132,15 @@ public interface StaffMapper {
...
@@ -132,4 +132,15 @@ public interface StaffMapper {
*/
*/
TabHaobanStaff
selectByPhoneNumberAndEnterpriseId
(
@Param
(
"phoneNumber"
)
String
phoneNumber
,
TabHaobanStaff
selectByPhoneNumberAndEnterpriseId
(
@Param
(
"phoneNumber"
)
String
phoneNumber
,
@Param
(
"wxEnterpriseId"
)
String
wxEnterpriseId
);
@Param
(
"wxEnterpriseId"
)
String
wxEnterpriseId
);
/**
* 删除同wxUserId的其他staff
*
* @param wxUserId 微信用户id
* @param staffId 导购id
* @param wxEnterpriseId wx企业标识
*/
void
delOtherStaffByWxUserId
(
@Param
(
"wxUserId"
)
String
wxUserId
,
@Param
(
"staffId"
)
String
staffId
,
@Param
(
"wxEnterpriseId"
)
String
wxEnterpriseId
);
}
}
\ No newline at end of file
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/service/StaffService.java
View file @
8c233bfe
...
@@ -97,5 +97,12 @@ public interface StaffService {
...
@@ -97,5 +97,12 @@ public interface StaffService {
*/
*/
int
updateOpenUserIdsByUserId
(
String
wxEnterpriseId
,
String
wxUserId
,
String
wxOpenUseId
);
int
updateOpenUserIdsByUserId
(
String
wxEnterpriseId
,
String
wxUserId
,
String
wxOpenUseId
);
/**
* 删除同wxUserId的其他staff
*
* @param wxUserId 微信用户id
* @param staffId 导购id
* @param wxEnterpriseId wx企业标识
*/
void
delOtherStaffByWxUserId
(
String
wxUserId
,
String
staffId
,
String
wxEnterpriseId
);
}
}
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/service/impl/StaffServiceImpl.java
View file @
8c233bfe
...
@@ -120,4 +120,9 @@ public class StaffServiceImpl implements StaffService {
...
@@ -120,4 +120,9 @@ public class StaffServiceImpl implements StaffService {
return
mapper
.
updateOpenUserIdsByUserId
(
wxEnterpriseId
,
wxUserId
,
wxOpenUseId
);
return
mapper
.
updateOpenUserIdsByUserId
(
wxEnterpriseId
,
wxUserId
,
wxOpenUseId
);
}
}
@Override
public
void
delOtherStaffByWxUserId
(
String
wxUserId
,
String
staffId
,
String
wxEnterpriseId
)
{
mapper
.
delOtherStaffByWxUserId
(
wxUserId
,
staffId
,
wxEnterpriseId
);
}
}
}
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/service/out/impl/StaffApiServiceImpl.java
View file @
8c233bfe
...
@@ -390,6 +390,9 @@ public class StaffApiServiceImpl implements StaffApiService {
...
@@ -390,6 +390,9 @@ public class StaffApiServiceImpl implements StaffApiService {
String
nationCode
=
arr
[
0
];
String
nationCode
=
arr
[
0
];
String
phoneNumber
=
arr
[
1
];
String
phoneNumber
=
arr
[
1
];
TabHaobanStaff
staff
=
staffService
.
selectByPhoneNumberAndEnterpriseId
(
phoneNumber
.
trim
(),
wxEnterpriseId
);
TabHaobanStaff
staff
=
staffService
.
selectByPhoneNumberAndEnterpriseId
(
phoneNumber
.
trim
(),
wxEnterpriseId
);
if
(
staff
!=
null
){
staffService
.
delOtherStaffByWxUserId
(
staff
.
getWxUserId
(),
staff
.
getStaffId
(),
wxEnterpriseId
);
}
staff
=
(
staff
==
null
?
new
TabHaobanStaff
()
:
staff
);
staff
=
(
staff
==
null
?
new
TabHaobanStaff
()
:
staff
);
staff
.
setWxUserId
(
userId
);
staff
.
setWxUserId
(
userId
);
staff
.
setUpdateTime
(
new
Date
());
staff
.
setUpdateTime
(
new
Date
());
...
...
haoban-manage3-service/src/main/resources/mapper/StaffMapper.xml
View file @
8c233bfe
...
@@ -42,6 +42,15 @@
...
@@ -42,6 +42,15 @@
where staff_id = #{staffId,jdbcType=VARCHAR}
where staff_id = #{staffId,jdbcType=VARCHAR}
</delete>
</delete>
<update
id=
"delOtherStaffByWxUserId"
>
update tab_haoban_staff
set status_flag = 0,update_time = now()
where wx_enterprise_id = #{wxEnterpriseId}
and wx_user_id = #{wxUserId}
and status_flag = 1
and staff_id != #{staffId}
</update>
<insert
id=
"insertSelective"
parameterType=
"com.gic.haoban.manage.service.entity.TabHaobanStaff"
>
<insert
id=
"insertSelective"
parameterType=
"com.gic.haoban.manage.service.entity.TabHaobanStaff"
>
insert into tab_haoban_staff
insert into tab_haoban_staff
<trim
prefix=
"("
suffix=
")"
suffixOverrides=
","
>
<trim
prefix=
"("
suffix=
")"
suffixOverrides=
","
>
...
...
haoban-manage3-wx/src/main/java/com/gic/haoban/manage/web/controller/ClerkController.java
View file @
8c233bfe
...
@@ -122,7 +122,7 @@ public class ClerkController extends WebBaseController {
...
@@ -122,7 +122,7 @@ public class ClerkController extends WebBaseController {
resultList
.
add
(
dto
);
resultList
.
add
(
dto
);
}
}
}
}
return
resultResponse
(
HaoBanErrCode
.
ERR_1
,
result
l
ist
);
return
resultResponse
(
HaoBanErrCode
.
ERR_1
,
result
L
ist
);
}
}
...
...
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