Parcourir la source

Merge branch 'han' of uskycloud/usky-modules into server-165

hanzhengyi il y a 1 an
Parent
commit
000ed550fa

+ 4 - 4
service-iot/service-iot-biz/src/main/java/com/usky/iot/service/impl/BaseFacilityTypeServiceImpl.java

@@ -41,7 +41,7 @@ public class BaseFacilityTypeServiceImpl extends AbstractCrudService<BaseFacilit
     public List<BaseGgpFacilityTypeVO> typeInfo() {
         List<BaseGgpFacilityTypeVO> list = new ArrayList<>();
         LambdaQueryWrapper<BaseFacilityType> queryWrapper = Wrappers.lambdaQuery();
-        queryWrapper.eq(BaseFacilityType::getTenantId, SecurityUtils.getTenantId());
+//        queryWrapper.eq(BaseFacilityType::getTenantId, SecurityUtils.getTenantId());
         List<BaseFacilityType> list1 = this.list(queryWrapper);
         Integer typeNum = baseMapper.selectCount(queryWrapper);
         if (CollectionUtils.isNotEmpty(list1)) {
@@ -101,7 +101,7 @@ public class BaseFacilityTypeServiceImpl extends AbstractCrudService<BaseFacilit
                 typeName)
                 .eq(StringUtils.isNotBlank(typeCode),BaseFacilityType::getTypeCode,
                         typeCode)
-                .eq(BaseFacilityType::getTenantId, SecurityUtils.getTenantId())
+//                .eq(BaseFacilityType::getTenantId, SecurityUtils.getTenantId())
                 .orderByDesc(BaseFacilityType::getId);
         page = this.page(page,lambdaQuery);
         return new CommonPage<>(page.getRecords(),page.getTotal(),page.getCurrent(),page.getSize());
@@ -109,8 +109,8 @@ public class BaseFacilityTypeServiceImpl extends AbstractCrudService<BaseFacilit
     @Override
     public List<BaseFacilityType> typeSelect(Integer id) {
         LambdaQueryWrapper<BaseFacilityType> lambdaQuery = Wrappers.lambdaQuery();
-        lambdaQuery.eq(null != id,BaseFacilityType::getId,id)
-        .eq(BaseFacilityType::getTenantId, SecurityUtils.getTenantId());
+        lambdaQuery.eq(null != id,BaseFacilityType::getId,id);
+//        .eq(BaseFacilityType::getTenantId, SecurityUtils.getTenantId());
         List<BaseFacilityType> list1 = this.list(lambdaQuery);
         return list1;
     }

+ 4 - 4
service-iot/service-iot-biz/src/main/resources/mapper/iot/BaseFacilityTypeMapper.xml

@@ -26,7 +26,7 @@
         LEFT JOIN base_ggp_facility e ON e.facility_type = d.id
         <where>
             <if test="tenantId != null and tenantId != ''">
-                and d.tenant_id = #{tenantId}
+                and e.tenant_id = #{tenantId}
             </if>
         </where>
         GROUP BY d.id
@@ -38,7 +38,7 @@
         LEFT JOIN base_ggp_facility e ON e.facility_type = d.id
         <where>
             <if test="tenantId != null and tenantId != ''">
-                and d.tenant_id = #{tenantId}
+                and e.tenant_id = #{tenantId}
             </if>
                 and e.status = 0
         </where>
@@ -51,7 +51,7 @@
         LEFT JOIN base_ggp_facility e ON e.facility_type = d.id
         <where>
             <if test="tenantId != null and tenantId != ''">
-                and d.tenant_id = #{tenantId}
+                and e.tenant_id = #{tenantId}
             </if>
             and e.status = 1
         </where>
@@ -64,7 +64,7 @@
         LEFT JOIN base_ggp_facility e ON e.facility_type = d.id
         <where>
             <if test="tenantId != null and tenantId != ''">
-                and d.tenant_id = #{tenantId}
+                and e.tenant_id = #{tenantId}
             </if>
             and e.status = 2
         </where>