|
@@ -695,12 +695,14 @@ public class BuildingTreeServiceImpl implements BuildingTreeServiceI {
|
695
|
695
|
if (type.equals("roomNo")) {
|
696
|
696
|
TpLevel tpLevel = tpLevelMapper.selectById(id);
|
697
|
697
|
QueryWrapper<TpBuildingOwnerInfo> tpBuildingOwnerInfo = new QueryWrapper<>();
|
698
|
|
- tpBuildingOwnerInfo.eq("community_id", tpLevel.getCommunityId())
|
699
|
|
- .eq("phase_id", tpLevel.getPhaseId())
|
700
|
|
- .eq("building_id", tpLevel.getBuildingId())
|
701
|
|
- .eq("unit_id", tpLevel.getUnitId())
|
702
|
|
- .eq("level_id", tpLevel.getId())
|
703
|
|
- .eq("verify_status", 1);
|
|
698
|
+ if (null!=tpLevel) {
|
|
699
|
+ tpBuildingOwnerInfo.eq("community_id", tpLevel.getCommunityId())
|
|
700
|
+ .eq("phase_id", tpLevel.getPhaseId())
|
|
701
|
+ .eq("building_id", tpLevel.getBuildingId())
|
|
702
|
+ .eq("unit_id", tpLevel.getUnitId())
|
|
703
|
+ .eq("level_id", tpLevel.getId())
|
|
704
|
+ .eq("verify_status", 1);
|
|
705
|
+ }
|
704
|
706
|
List<TpBuildingOwnerInfo> ifoBuid = tpBuildingOwnerInfoMapper .selectList(tpBuildingOwnerInfo);
|
705
|
707
|
if (null != ifoBuid && ifoBuid.size()>0) {
|
706
|
708
|
return false;
|
|
@@ -709,10 +711,12 @@ public class BuildingTreeServiceImpl implements BuildingTreeServiceI {
|
709
|
711
|
if (type.equals("level")) {
|
710
|
712
|
TpUnit tpUnit = tpUnitMapper.selectById(id);
|
711
|
713
|
QueryWrapper<TpBuildingOwnerInfo> tpBuildingOwnerInfo = new QueryWrapper<>();
|
712
|
|
- tpBuildingOwnerInfo.eq("community_id", tpUnit.getCommunityId())
|
713
|
|
- .eq("phase_id", tpUnit.getPhaseId())
|
714
|
|
- .eq("building_id", tpUnit.getBuildingId())
|
715
|
|
- .eq("verify_status", 1);
|
|
714
|
+ if (null!=tpUnit) {
|
|
715
|
+ tpBuildingOwnerInfo.eq("community_id", tpUnit.getCommunityId())
|
|
716
|
+ .eq("phase_id", tpUnit.getPhaseId())
|
|
717
|
+ .eq("building_id", tpUnit.getBuildingId())
|
|
718
|
+ .eq("verify_status", 1);
|
|
719
|
+ }
|
716
|
720
|
List<TpBuildingOwnerInfo> ifoBuid = tpBuildingOwnerInfoMapper.selectList(tpBuildingOwnerInfo);
|
717
|
721
|
if (null != ifoBuid && ifoBuid.size()>0) {
|
718
|
722
|
return false;
|
|
@@ -722,10 +726,12 @@ public class BuildingTreeServiceImpl implements BuildingTreeServiceI {
|
722
|
726
|
//判断书否有已审核人员
|
723
|
727
|
TpBuilding tpBuilding = tpBuildingMapper.selectById(id);
|
724
|
728
|
QueryWrapper<TpBuildingOwnerInfo> tpBuildingOwnerInfo = new QueryWrapper<>();
|
725
|
|
- tpBuildingOwnerInfo.eq("community_id", tpBuilding.getCommunityId())
|
726
|
|
- .eq("phase_id", tpBuilding.getPhaseId())
|
727
|
|
- .eq("building_id", tpBuilding.getId())
|
728
|
|
- .eq("verify_status", 1);
|
|
729
|
+ if (null!=tpBuilding) {
|
|
730
|
+ tpBuildingOwnerInfo.eq("community_id", tpBuilding.getCommunityId())
|
|
731
|
+ .eq("phase_id", tpBuilding.getPhaseId())
|
|
732
|
+ .eq("building_id", tpBuilding.getId())
|
|
733
|
+ .eq("verify_status", 1);
|
|
734
|
+ }
|
729
|
735
|
List<TpBuildingOwnerInfo> ifoBuid = tpBuildingOwnerInfoMapper.selectList(tpBuildingOwnerInfo);
|
730
|
736
|
if (null != ifoBuid && ifoBuid.size()>0) {
|
731
|
737
|
return false;
|
|
@@ -733,10 +739,12 @@ public class BuildingTreeServiceImpl implements BuildingTreeServiceI {
|
733
|
739
|
}
|
734
|
740
|
if (type.equals("building")) {
|
735
|
741
|
TpPhase phase = tpPhaseMapper.selectById(id);
|
736
|
|
- QueryWrapper<TpBuildingOwnerInfo> tpBuildingOwnerInfo = new QueryWrapper<>();
|
737
|
|
- tpBuildingOwnerInfo.eq("community_id", phase.getCommunityId())
|
738
|
|
- .eq("phase_id", phase.getId())
|
739
|
|
- .eq("verify_status", 1);
|
|
742
|
+ QueryWrapper<TpBuildingOwnerInfo> tpBuildingOwnerInfo = new QueryWrapper<>();
|
|
743
|
+ if (null!=phase) {
|
|
744
|
+ tpBuildingOwnerInfo.eq("community_id", phase.getCommunityId())
|
|
745
|
+ .eq("phase_id", phase.getId())
|
|
746
|
+ .eq("verify_status", 1);
|
|
747
|
+ }
|
740
|
748
|
List<TpBuildingOwnerInfo> ifoBuid = tpBuildingOwnerInfoMapper.selectList(tpBuildingOwnerInfo);
|
741
|
749
|
if (null != ifoBuid && ifoBuid.size()>0) {
|
742
|
750
|
return false;
|