提交 99a8d145 编写于 作者: zhouweidong's avatar zhouweidong

消息开关

上级 077cdf7c
...@@ -67,7 +67,7 @@ public class SysEmp2UserAspect ...@@ -67,7 +67,7 @@ public class SysEmp2UserAspect
private String defaultPasswd; private String defaultPasswd;
@Value("${rocketmq.producer.isOnOff:off}") @Value("${rocketmq.producer.isOnOff:off}")
private String mqSync; private String isOnOff;
@Before(value = "execution(* cn.ibizlab.core.ou.service.ISysEmployeeService.getDraft*(..))") @Before(value = "execution(* cn.ibizlab.core.ou.service.ISysEmployeeService.getDraft*(..))")
public void BeforeGetDraft(JoinPoint point) throws Exception { public void BeforeGetDraft(JoinPoint point) throws Exception {
...@@ -329,7 +329,7 @@ public class SysEmp2UserAspect ...@@ -329,7 +329,7 @@ public class SysEmp2UserAspect
if(obj instanceof SysEmployee) if(obj instanceof SysEmployee)
{ {
SysEmployee employee = (SysEmployee)obj; SysEmployee employee = (SysEmployee)obj;
if (!"on".equalsIgnoreCase(mqSync)) { if (!"on".equalsIgnoreCase(isOnOff)) {
IBZUSER ibzuser = ibzEmp2UserMapping.toDto(employee); IBZUSER ibzuser = ibzEmp2UserMapping.toDto(employee);
if (ibzuser.getLoginname().equalsIgnoreCase("ibzadmin")) if (ibzuser.getLoginname().equalsIgnoreCase("ibzadmin"))
ibzuser.setSuperuser(1); ibzuser.setSuperuser(1);
...@@ -354,7 +354,7 @@ public class SysEmp2UserAspect ...@@ -354,7 +354,7 @@ public class SysEmp2UserAspect
else if (obj instanceof List) else if (obj instanceof List)
{ {
List<SysEmployee> list = (List<SysEmployee>) obj; List<SysEmployee> list = (List<SysEmployee>) obj;
if (!"on".equalsIgnoreCase(mqSync)) { if (!"on".equalsIgnoreCase(isOnOff)) {
ibzuserService.saveOrUpdateBatch(ibzEmp2UserMapping.toDto(list)); ibzuserService.saveOrUpdateBatch(ibzEmp2UserMapping.toDto(list));
} }
List<SysDeptMember> mebs = (List<SysDeptMember>) obj; List<SysDeptMember> mebs = (List<SysDeptMember>) obj;
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册