智慧农业后台管理
Administrator
2022-07-14 86ca03a40065388aecc60973a3359c177a9fbb4a
src/main/java/org/springblade/modules/lang/mapper/LandMapper.xml
@@ -145,10 +145,10 @@
        SELECT IFNULL(land_area, 0) as area, IFNULL(land_unit, 0) as unit FROM sys_land
        WHERE is_deleted = 0
        <if test="land.farmId!= null and land.farmId!=''">
            and sl.farm_id=#{land.farmId}
            and farm_id=#{land.farmId}
        </if>
        <if test="land.deptId!= null and land.deptId!=''">
            and sl.dept_id=#{land.deptId}
            and dept_id=#{land.deptId}
        </if>
    </select>
    <!--土地使用面积-->
@@ -158,10 +158,10 @@
        WHERE is_deleted = 0
        and type = 0
        <if test="land.farmId!= null and land.farmId!=''">
            and sl.farm_id=#{land.farmId}
            and farm_id=#{land.farmId}
        </if>
        <if test="land.deptId!= null and land.deptId!=''">
            and sl.dept_id=#{land.deptId}
            and dept_id=#{land.deptId}
        </if>
    </select>
    <!--土地未使用面积-->
@@ -171,10 +171,10 @@
        WHERE is_deleted = 0
        and type = 1
        <if test="land.farmId!= null and land.farmId!=''">
            and sl.farm_id=#{land.farmId}
            and farm_id=#{land.farmId}
        </if>
        <if test="land.deptId!= null and land.deptId!=''">
            and sl.dept_id=#{land.deptId}
            and dept_id=#{land.deptId}
        </if>
    </select>
@@ -186,7 +186,7 @@
            and sl.farm_id=#{land.farmId}
        </if>
        <if test="land.deptId!= null and land.deptId!=''">
            and sl.dept_id=#{land.deptId}
            and sfp.dept_id=#{land.deptId}
        </if>
        GROUP BY sfp.strain_id
    </select>