提交 6a49ea5e 编写于 作者: ibizdev's avatar ibizdev

ibiz4j 发布系统代码

上级 23718905
...@@ -30,6 +30,8 @@ public interface IBZDepartmentMapper extends BaseMapper<IBZDepartment>{ ...@@ -30,6 +30,8 @@ public interface IBZDepartmentMapper extends BaseMapper<IBZDepartment>{
@Override @Override
@CacheEvict( value="ibzdepartment",key = "'row:'+#p0.deptid") @CacheEvict( value="ibzdepartment",key = "'row:'+#p0.deptid")
int updateById(@Param(Constants.ENTITY) IBZDepartment entity); int updateById(@Param(Constants.ENTITY) IBZDepartment entity);
@CacheEvict(value="ibzdepartment",key = "'row:'+#p0.deptid")
int update(@Param(Constants.ENTITY) IBZDepartment entity, @Param("ew") Wrapper<ibzdepartment> updateWrapper);
@Override @Override
@CacheEvict( value="ibzdepartment",key = "'row:'+#p0") @CacheEvict( value="ibzdepartment",key = "'row:'+#p0")
int deleteById(Serializable id); int deleteById(Serializable id);
......
...@@ -26,6 +26,7 @@ public interface IBZDeptMemberMapper extends BaseMapper<IBZDeptMember>{ ...@@ -26,6 +26,7 @@ public interface IBZDeptMemberMapper extends BaseMapper<IBZDeptMember>{
int insert(IBZDeptMember entity); int insert(IBZDeptMember entity);
@Override @Override
int updateById(@Param(Constants.ENTITY) IBZDeptMember entity); int updateById(@Param(Constants.ENTITY) IBZDeptMember entity);
int update(@Param(Constants.ENTITY) IBZDeptMember entity, @Param("ew") Wrapper<ibzdeptmember> updateWrapper);
@Override @Override
int deleteById(Serializable id); int deleteById(Serializable id);
/** /**
......
...@@ -29,6 +29,8 @@ public interface IBZEmployeeMapper extends BaseMapper<IBZEmployee>{ ...@@ -29,6 +29,8 @@ public interface IBZEmployeeMapper extends BaseMapper<IBZEmployee>{
@Override @Override
@CacheEvict( value="ibzemployee",key = "'row:'+#p0.userid") @CacheEvict( value="ibzemployee",key = "'row:'+#p0.userid")
int updateById(@Param(Constants.ENTITY) IBZEmployee entity); int updateById(@Param(Constants.ENTITY) IBZEmployee entity);
@CacheEvict(value="ibzemployee",key = "'row:'+#p0.userid")
int update(@Param(Constants.ENTITY) IBZEmployee entity, @Param("ew") Wrapper<ibzemployee> updateWrapper);
@Override @Override
@CacheEvict( value="ibzemployee",key = "'row:'+#p0") @CacheEvict( value="ibzemployee",key = "'row:'+#p0")
int deleteById(Serializable id); int deleteById(Serializable id);
......
...@@ -31,6 +31,8 @@ public interface IBZOrganizationMapper extends BaseMapper<IBZOrganization>{ ...@@ -31,6 +31,8 @@ public interface IBZOrganizationMapper extends BaseMapper<IBZOrganization>{
@Override @Override
@CacheEvict( value="ibzorganization",key = "'row:'+#p0.orgid") @CacheEvict( value="ibzorganization",key = "'row:'+#p0.orgid")
int updateById(@Param(Constants.ENTITY) IBZOrganization entity); int updateById(@Param(Constants.ENTITY) IBZOrganization entity);
@CacheEvict(value="ibzorganization",key = "'row:'+#p0.orgid")
int update(@Param(Constants.ENTITY) IBZOrganization entity, @Param("ew") Wrapper<ibzorganization> updateWrapper);
@Override @Override
@CacheEvict( value="ibzorganization",key = "'row:'+#p0") @CacheEvict( value="ibzorganization",key = "'row:'+#p0")
int deleteById(Serializable id); int deleteById(Serializable id);
......
...@@ -25,22 +25,29 @@ import com.baomidou.mybatisplus.extension.service.IService; ...@@ -25,22 +25,29 @@ import com.baomidou.mybatisplus.extension.service.IService;
public interface IIBZDepartmentService extends IService<IBZDepartment>{ public interface IIBZDepartmentService extends IService<IBZDepartment>{
boolean create(IBZDepartment et) ; boolean create(IBZDepartment et) ;
@CacheEvict(value="ibzdepartment",allEntries=true)
void createBatch(List<IBZDepartment> list) ; void createBatch(List<IBZDepartment> list) ;
IBZDepartment get(String key) ; IBZDepartment get(String key) ;
boolean save(IBZDepartment et) ; boolean save(IBZDepartment et) ;
@CacheEvict(value="ibzdepartment",allEntries=true)
void saveBatch(List<IBZDepartment> list) ; void saveBatch(List<IBZDepartment> list) ;
boolean checkKey(IBZDepartment et) ; boolean checkKey(IBZDepartment et) ;
IBZDepartment getDraft(IBZDepartment et) ; IBZDepartment getDraft(IBZDepartment et) ;
boolean remove(String key) ; boolean remove(String key) ;
@CacheEvict(value="ibzdepartment",allEntries=true)
void removeBatch(Collection<String> idList) ; void removeBatch(Collection<String> idList) ;
boolean update(IBZDepartment et) ; boolean update(IBZDepartment et) ;
@CacheEvict(value="ibzdepartment",allEntries=true)
void updateBatch(List<IBZDepartment> list) ; void updateBatch(List<IBZDepartment> list) ;
Page<IBZDepartment> searchCurDept(IBZDepartmentSearchContext context) ; Page<IBZDepartment> searchCurDept(IBZDepartmentSearchContext context) ;
Page<IBZDepartment> searchDefault(IBZDepartmentSearchContext context) ; Page<IBZDepartment> searchDefault(IBZDepartmentSearchContext context) ;
List<IBZDepartment> selectByParentdeptid(String deptid) ; List<IBZDepartment> selectByParentdeptid(String deptid) ;
@CacheEvict(value="ibzdepartment",allEntries=true)
void removeByParentdeptid(String deptid) ; void removeByParentdeptid(String deptid) ;
List<IBZDepartment> selectByOrgid(String orgid) ; List<IBZDepartment> selectByOrgid(String orgid) ;
@CacheEvict(value="ibzdepartment",allEntries=true)
void removeByOrgid(String orgid) ; void removeByOrgid(String orgid) ;
@CacheEvict(value="ibzdepartment",allEntries=true)
void saveByOrgid(String orgid,List<IBZDepartment> list) ; void saveByOrgid(String orgid,List<IBZDepartment> list) ;
/** /**
*自定义查询SQL *自定义查询SQL
......
...@@ -25,21 +25,27 @@ import com.baomidou.mybatisplus.extension.service.IService; ...@@ -25,21 +25,27 @@ import com.baomidou.mybatisplus.extension.service.IService;
public interface IIBZEmployeeService extends IService<IBZEmployee>{ public interface IIBZEmployeeService extends IService<IBZEmployee>{
boolean remove(String key) ; boolean remove(String key) ;
@CacheEvict(value="ibzemployee",allEntries=true)
void removeBatch(Collection<String> idList) ; void removeBatch(Collection<String> idList) ;
IBZEmployee initPwd(IBZEmployee et) ; IBZEmployee initPwd(IBZEmployee et) ;
boolean create(IBZEmployee et) ; boolean create(IBZEmployee et) ;
@CacheEvict(value="ibzemployee",allEntries=true)
void createBatch(List<IBZEmployee> list) ; void createBatch(List<IBZEmployee> list) ;
boolean checkKey(IBZEmployee et) ; boolean checkKey(IBZEmployee et) ;
boolean update(IBZEmployee et) ; boolean update(IBZEmployee et) ;
@CacheEvict(value="ibzemployee",allEntries=true)
void updateBatch(List<IBZEmployee> list) ; void updateBatch(List<IBZEmployee> list) ;
boolean save(IBZEmployee et) ; boolean save(IBZEmployee et) ;
@CacheEvict(value="ibzemployee",allEntries=true)
void saveBatch(List<IBZEmployee> list) ; void saveBatch(List<IBZEmployee> list) ;
IBZEmployee get(String key) ; IBZEmployee get(String key) ;
IBZEmployee getDraft(IBZEmployee et) ; IBZEmployee getDraft(IBZEmployee et) ;
Page<IBZEmployee> searchDefault(IBZEmployeeSearchContext context) ; Page<IBZEmployee> searchDefault(IBZEmployeeSearchContext context) ;
List<IBZEmployee> selectByMdeptid(String deptid) ; List<IBZEmployee> selectByMdeptid(String deptid) ;
@CacheEvict(value="ibzemployee",allEntries=true)
void removeByMdeptid(String deptid) ; void removeByMdeptid(String deptid) ;
List<IBZEmployee> selectByOrgid(String orgid) ; List<IBZEmployee> selectByOrgid(String orgid) ;
@CacheEvict(value="ibzemployee",allEntries=true)
void removeByOrgid(String orgid) ; void removeByOrgid(String orgid) ;
/** /**
*自定义查询SQL *自定义查询SQL
......
...@@ -26,12 +26,16 @@ public interface IIBZOrganizationService extends IService<IBZOrganization>{ ...@@ -26,12 +26,16 @@ public interface IIBZOrganizationService extends IService<IBZOrganization>{
boolean checkKey(IBZOrganization et) ; boolean checkKey(IBZOrganization et) ;
boolean update(IBZOrganization et) ; boolean update(IBZOrganization et) ;
@CacheEvict(value="ibzorganization",allEntries=true)
void updateBatch(List<IBZOrganization> list) ; void updateBatch(List<IBZOrganization> list) ;
boolean create(IBZOrganization et) ; boolean create(IBZOrganization et) ;
@CacheEvict(value="ibzorganization",allEntries=true)
void createBatch(List<IBZOrganization> list) ; void createBatch(List<IBZOrganization> list) ;
boolean save(IBZOrganization et) ; boolean save(IBZOrganization et) ;
@CacheEvict(value="ibzorganization",allEntries=true)
void saveBatch(List<IBZOrganization> list) ; void saveBatch(List<IBZOrganization> list) ;
boolean remove(String key) ; boolean remove(String key) ;
@CacheEvict(value="ibzorganization",allEntries=true)
void removeBatch(Collection<String> idList) ; void removeBatch(Collection<String> idList) ;
IBZOrganization get(String key) ; IBZOrganization get(String key) ;
IBZOrganization getDraft(IBZOrganization et) ; IBZOrganization getDraft(IBZOrganization et) ;
...@@ -39,6 +43,7 @@ public interface IIBZOrganizationService extends IService<IBZOrganization>{ ...@@ -39,6 +43,7 @@ public interface IIBZOrganizationService extends IService<IBZOrganization>{
Page<IBZOrganization> searchSelectPOrg(IBZOrganizationSearchContext context) ; Page<IBZOrganization> searchSelectPOrg(IBZOrganizationSearchContext context) ;
Page<IBZOrganization> searchDefault(IBZOrganizationSearchContext context) ; Page<IBZOrganization> searchDefault(IBZOrganizationSearchContext context) ;
List<IBZOrganization> selectByParentorgid(String orgid) ; List<IBZOrganization> selectByParentorgid(String orgid) ;
@CacheEvict(value="ibzorganization",allEntries=true)
void removeByParentorgid(String orgid) ; void removeByParentorgid(String orgid) ;
/** /**
*自定义查询SQL *自定义查询SQL
......
...@@ -54,6 +54,10 @@ public class IBZEmployeeServiceImpl extends ServiceImpl<IBZEmployeeMapper, IBZEm ...@@ -54,6 +54,10 @@ public class IBZEmployeeServiceImpl extends ServiceImpl<IBZEmployeeMapper, IBZEm
@Lazy @Lazy
private cn.ibizlab.core.ou.service.IIBZOrganizationService ibzorganizationService; private cn.ibizlab.core.ou.service.IIBZOrganizationService ibzorganizationService;
@Autowired
@Lazy
private cn.ibizlab.core.ou.service.logic.IIBZEmployeesaveDeptMemberLogic savedeptmemberLogic;
private int batchSize = 500; private int batchSize = 500;
@Override @Override
...@@ -84,6 +88,7 @@ public class IBZEmployeeServiceImpl extends ServiceImpl<IBZEmployeeMapper, IBZEm ...@@ -84,6 +88,7 @@ public class IBZEmployeeServiceImpl extends ServiceImpl<IBZEmployeeMapper, IBZEm
return false; return false;
ibzdeptmemberService.saveByUserid(et.getUserid(),et.getIbzdeptmember()); ibzdeptmemberService.saveByUserid(et.getUserid(),et.getIbzdeptmember());
CachedBeanCopier.copy(get(et.getUserid()),et); CachedBeanCopier.copy(get(et.getUserid()),et);
savedeptmemberLogic.execute(et);
return true; return true;
} }
...@@ -106,6 +111,7 @@ public class IBZEmployeeServiceImpl extends ServiceImpl<IBZEmployeeMapper, IBZEm ...@@ -106,6 +111,7 @@ public class IBZEmployeeServiceImpl extends ServiceImpl<IBZEmployeeMapper, IBZEm
return false; return false;
ibzdeptmemberService.saveByUserid(et.getUserid(),et.getIbzdeptmember()); ibzdeptmemberService.saveByUserid(et.getUserid(),et.getIbzdeptmember());
CachedBeanCopier.copy(get(et.getUserid()),et); CachedBeanCopier.copy(get(et.getUserid()),et);
savedeptmemberLogic.execute(et);
return true; return true;
} }
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册