| | |
| | | package com.moral.service.impl;
|
| | |
|
| | | import static com.moral.common.bean.Constants.IS_DELETE_FALSE;
|
| | |
|
| | | import java.util.HashSet;
|
| | | import java.util.List;
|
| | | import java.util.Set;
|
| | |
| | | import com.moral.mapper.OrganizationMapper;
|
| | | import com.moral.mapper.OrganizationRelationMapper;
|
| | | import com.moral.service.OrganizationService;
|
| | | import com.moral.util.Constants;
|
| | |
|
| | | @Service
|
| | | public class OrganizationServiceImpl implements OrganizationService {
|
| | |
| | | OrganizationRelationExample example = new OrganizationRelationExample();
|
| | | example.or().andParentIdEqualTo(orgId);
|
| | | Organization organization = organizationMapper.selectByPrimaryKey(orgId);
|
| | | if (Constants.IS_DELETE_FALSE.equals(organization.getIsDelete())) {
|
| | | if (IS_DELETE_FALSE.equals(organization.getIsDelete())) {
|
| | | List<OrganizationRelation> organizationRelations = organizationRelationMapper.selectByExample(example);
|
| | | for (OrganizationRelation organizationRelation : organizationRelations) {
|
| | | Set<Integer> organizationIds = getChildOrganizationIds(organizationRelation.getParentId());
|