Commit 1750eb0b by qwmqiuwenmin

fix

parent 27888ca8
......@@ -91,6 +91,12 @@
<artifactId>gic-wechat-api</artifactId>
<version>${gic-wechat-api}</version>
</dependency>
<dependency>
<groupId>com.gic</groupId>
<artifactId>gic-clerk-api</artifactId>
<version>${gic-clerk-api}</version>
</dependency>
</dependencies>
<build>
......
......@@ -18,6 +18,8 @@ import cn.hutool.core.collection.CollectionUtil;
import com.alibaba.fastjson.JSON;
import com.gic.api.base.commons.JSONResponse;
import com.gic.api.base.commons.Page;
import com.gic.clerk.api.dto.ClerkDTO;
import com.gic.clerk.api.service.ClerkService;
import com.gic.commons.util.EntityUtil;
import com.gic.haoban.base.api.common.BasePageInfo;
import com.gic.haoban.common.utils.HaobanResponse;
......@@ -64,6 +66,10 @@ public class StaffApiServiceImpl implements StaffApiService {
private WxApplicationService wxApplicationService;
@Autowired
private DepartmentService departmentService;
@Autowired
private ClerkService clerkService;
@Autowired
private com.gic.enterprise.api.service.DepartmentService gicDepartmentService;
@Override
public StaffDTO selectById(String staffId) {
......@@ -299,7 +305,12 @@ public class StaffApiServiceImpl implements StaffApiService {
if(org.apache.commons.lang3.StringUtils.isNoneBlank(related.getClerkCode())){
if(!staffDTO.getPhoneNumber().equals(related.getPhoneNumber())||!staffDTO.getStaffName().equals(oldStaff.getStaffName())){
//TODO 通知gic同步修改姓名和手机号
TabHaobanDepartment department = departmentService.selectById(addId);
com.gic.enterprise.api.dto.DepartmentDTO dto = gicDepartmentService.getDeptment(department.getRelatedId());
ClerkDTO clerkDTO= clerkService.getClerkByCodeNoStatus(dto.getEnterpriseId(),related.getClerkCode());
clerkDTO.setClerkName(staffDTO.getStaffName());
clerkDTO.setPhoneNumber(staffDTO.getPhoneNumber());
clerkService.updateClerk(clerkDTO);
}
}
......@@ -315,10 +326,10 @@ public class StaffApiServiceImpl implements StaffApiService {
if(!departmentIds.contains(tab1.getDepartmentId())){
StaffDepartmentRelatedDTO related = EntityUtil.changeEntityByJSON(StaffDepartmentRelatedDTO.class, tab1);
staffDepartmentRelatedService.del(related);
if(org.apache.commons.lang3.StringUtils.isNoneBlank(tab1.getClerkCode())){
//TODO 通知gic解绑
}
// if(org.apache.commons.lang3.StringUtils.isNoneBlank(tab1.getClerkCode())){
// //TODO 通知gic解绑
//
// }
}
}
......
......@@ -43,5 +43,6 @@
<dubbo:reference interface="com.gic.haoban.manage.api.service.WxApplicationApiService" id="wxApplicationApiService"/>
<dubbo:reference interface="com.gic.haoban.communicate.api.service.valid.ValidationCodeService" id="validationCodeService"/>
<dubbo:reference interface="com.gic.haoban.manage.api.service.WxEnterpriseRelatedApiService" id="wxEnterpriseRelatedApiService
</beans>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment