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
QianQiXiang
haoban-manage3.0
Commits
134e0bfd
Commit
134e0bfd
authored
Apr 20, 2020
by
huangZW
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'developer' of
http://115.159.76.241/haoban3.0/haoban-manage3.0.git
into developer
parents
0d47c35e
213430f2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
25 additions
and
7 deletions
+25
-7
StaffApiServiceImpl.java
.../manage/service/service/out/impl/StaffApiServiceImpl.java
+21
-6
SyncDealContoller.java
...m/gic/haoban/manage/web/controller/SyncDealContoller.java
+4
-1
No files found.
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/service/out/impl/StaffApiServiceImpl.java
View file @
134e0bfd
...
...
@@ -390,8 +390,7 @@ public class StaffApiServiceImpl implements StaffApiService {
}
}
@Override
public
void
staffEdit
(
StaffDTO
staffDTO
,
String
departmentIds
)
{
private
void
staffEditDeal
(
StaffDTO
staffDTO
,
String
departmentIds
,
boolean
syncGic
)
{
TabHaobanStaff
oldStaff
=
staffMapper
.
selectByPrimaryKey
(
staffDTO
.
getStaffId
());
logger
.
info
(
"【员工修改】oldStaff={}"
,
JSON
.
toJSONString
(
oldStaff
));
//1、先更新staff
...
...
@@ -459,7 +458,8 @@ public class StaffApiServiceImpl implements StaffApiService {
}
enterpriseId
=
store
.
getEnterpriseId
();
}
ClerkDTO
clerkDTO
=
clerkService
.
getClerkByCodeNoStatus
(
enterpriseId
,
related
.
getClerkCode
());
if
(!
syncGic
)
{
ClerkDTO
clerkDTO
=
clerkService
.
getClerkByCodeNoStatus
(
enterpriseId
,
related
.
getClerkCode
());
//if(!staffDTO.getPhoneNumber().equals(related.getPhoneNumber())||!staffDTO.getStaffName().equals(clerkDTO.getStaffName())){
logger
.
info
(
"clerkDto:{}"
,
JSONObject
.
toJSONString
(
clerkDTO
));
String
headPic
=
staffDTO
.
getHeadImg
();
...
...
@@ -473,13 +473,17 @@ public class StaffApiServiceImpl implements StaffApiService {
||
!
staffDTO
.
getPhoneNumber
().
equals
(
clerkDTO
.
getPhoneNumber
()))
||
(
org
.
apache
.
commons
.
lang3
.
StringUtils
.
isNotBlank
(
headPic
)
&&
!
headPic
.
equals
(
clerkDTO
.
getHeadImgUrl
()))
||
!
staffDTO
.
getSex
().
equals
(
Integer
.
valueOf
(
clerkDTO
.
getClerkGender
())))
{
logger
.
info
(
"【员工修改】clerkDTO={}"
,
JSON
.
toJSONString
(
clerkDTO
));
logger
.
info
(
"【员工修改】clerkDTO={}"
,
JSON
.
toJSONString
(
clerkDTO
));
logger
.
info
(
"【员工修改】{},修改地方:name:{},{};num:{},{};pic:{},{};sex:{},{}"
,
clerkDTO
.
getClerkId
(),
staffName
,
clerkDTO
.
getClerkName
(),
staffDTO
.
getPhoneNumber
(),
clerkDTO
.
getPhoneNumber
(),
headPic
,
clerkDTO
.
getHeadImgUrl
()
,
staffDTO
.
getSex
(),
clerkDTO
.
getClerkGender
());
clerkDTO
.
setClerkName
(
staffDTO
.
getStaffName
());
clerkDTO
.
setPhoneNumber
(
staffDTO
.
getPhoneNumber
());
clerkDTO
.
setHeadImgUrl
(
staffDTO
.
getHeadImg
());
clerkDTO
.
setClerkGender
(
staffDTO
.
getSex
().
toString
());
clerkService
.
updateClerk
(
clerkDTO
);
}
}
//}
}
...
...
@@ -535,6 +539,11 @@ public class StaffApiServiceImpl implements StaffApiService {
}
@Override
public
void
staffEdit
(
StaffDTO
staffDTO
,
String
departmentIds
)
{
staffEditDeal
(
staffDTO
,
departmentIds
,
false
);
}
@Override
public
void
syscGicClerk
(
String
fieldListString
)
{
// TODO Auto-generated method stub
...
...
@@ -652,7 +661,13 @@ public class StaffApiServiceImpl implements StaffApiService {
}
if
(
wxEnterpriseRelatedApiService
.
enterpriseUseNew
(
clerkMid
.
getEnterpriseId
())){
try
{
addClerkByGic
(
clerkMid
);
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
}
else
{
throw
new
RuntimeException
(
"使用好办2.0"
);
}
}
...
...
@@ -754,7 +769,7 @@ public class StaffApiServiceImpl implements StaffApiService {
departmentIds
=
departmentIds
.
substring
(
1
,
departmentIds
.
length
());
}
if
(
map
.
get
(
departmentId
)
==
null
){
this
.
staffEdit
(
staff
,
departmentIds
);
this
.
staffEditDeal
(
staff
,
departmentIds
,
true
);
}
StaffDepartmentRelatedDTO
staffRelated
=
this
.
getDepartmentIdAndStaffId
(
departmentId
,
staffId
);
StaffDepartmentRelatedDTO
isCodeExist
=
this
.
getDepartmentIdAndCode
(
departmentId
,
code
);
...
...
@@ -779,7 +794,7 @@ public class StaffApiServiceImpl implements StaffApiService {
// clerkService.updateClerk(clerkDTO);
// }
//}
this
.
staffEdit
(
staff
,
departmentIds
);
this
.
staffEditDeal
(
staff
,
departmentIds
,
true
);
}
}
}
...
...
haoban-manage3-web/src/main/java/com/gic/haoban/manage/web/controller/SyncDealContoller.java
View file @
134e0bfd
package
com
.
gic
.
haoban
.
manage
.
web
.
controller
;
import
com.alibaba.fastjson.JSONObject
;
import
com.gic.api.base.commons.Page
;
import
com.gic.haoban.base.api.common.BasePageInfo
;
import
com.gic.haoban.common.utils.HaobanResponse
;
...
...
@@ -60,11 +61,13 @@ public class SyncDealContoller extends WebBaseController {
LoginVO
login
=
(
LoginVO
)
AuthRequestUtil
.
getSessionUser
();
String
wxEnterpriseId
=
login
.
getWxEnterpriseId
();
logger
.
info
(
"login:{}"
,
JSONObject
.
toJSONString
(
login
));
String
taskLock
=
dealSyncOperationApiService
.
getTaskLock
(
wxEnterpriseId
);
if
(
null
!=
taskLock
)
{
return
resultResponse
(
HaoBanErrCode
.
ERR_10011
);
}
task
=
dealSyncOperationApiService
.
createTask
(
wxEnterpriseId
,
"门店同步"
,
login
.
getStaffDTO
().
getStaffId
()
,
"部门同步"
);
task
=
dealSyncOperationApiService
.
createTask
(
wxEnterpriseId
,
"门店同步"
,
"admin"
,
"部门同步"
);
if
(
task
==
null
)
{
return
resultResponse
(
HaoBanErrCode
.
ERR_10011
);
}
...
...
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