Commit 2f7256b9 authored by lixuan's avatar lixuan

feat: 到处增加年度税收字段

parent 97f1797a
Pipeline #146622 failed with stages
in 1 second
...@@ -84,6 +84,12 @@ public class HouseResourceExport { ...@@ -84,6 +84,12 @@ public class HouseResourceExport {
@Excel(name = "2025营收") @Excel(name = "2025营收")
private BigDecimal YearSell2025; private BigDecimal YearSell2025;
@Excel(name = "2024税收")
private BigDecimal YearTax2024;
@Excel(name = "2025税收")
private BigDecimal YearTax2025;
@Excel(name = "经营(办公)场所图片") @Excel(name = "经营(办公)场所图片")
private String houseResourceUrl; private String houseResourceUrl;
......
...@@ -133,4 +133,8 @@ public class HouseResourcePage { ...@@ -133,4 +133,8 @@ public class HouseResourcePage {
private BigDecimal YearSell2024; private BigDecimal YearSell2024;
private BigDecimal YearSell2025; private BigDecimal YearSell2025;
private BigDecimal YearTax2024;
private BigDecimal YearTax2025;
} }
...@@ -30,4 +30,5 @@ public interface BusinessEntitySellMapper { ...@@ -30,4 +30,5 @@ public interface BusinessEntitySellMapper {
BusinessEntitySell selectBusinessEntitySellByBusinessEntityInfoId(@Param("businessEntityInfoId") String businessEntityInfoId, @Param("year") Integer year); BusinessEntitySell selectBusinessEntitySellByBusinessEntityInfoId(@Param("businessEntityInfoId") String businessEntityInfoId, @Param("year") Integer year);
BusinessEntitySell selectBusinessEntityTaxByBusinessEntityInfoId(@Param("businessEntityInfoId") String businessEntityInfoId, @Param("year") Integer year);
} }
...@@ -423,6 +423,18 @@ public class HouseResourceServiceImpl implements HouseResourceService { ...@@ -423,6 +423,18 @@ public class HouseResourceServiceImpl implements HouseResourceService {
x.setYearSell2025(businessEntitySell2025.getYearSell()); x.setYearSell2025(businessEntitySell2025.getYearSell());
} }
} }
BusinessEntitySell businessEntityTax2024 = businessEntitySellMapper.selectBusinessEntityTaxByBusinessEntityInfoId(x.getBusinessEntityInfoId(), 2024);
if (Objects.nonNull(businessEntityTax2024)) {
if (Objects.nonNull(businessEntityTax2024.getYearTax())) {
x.setYearTax2024(businessEntityTax2024.getYearTax());
}
}
BusinessEntitySell businessEntityTax2025 = businessEntitySellMapper.selectBusinessEntityTaxByBusinessEntityInfoId(x.getBusinessEntityInfoId(), 2025);
if (Objects.nonNull(businessEntityTax2025)) {
if (Objects.nonNull(businessEntityTax2025.getYearTax())) {
x.setYearTax2025(businessEntityTax2025.getYearTax());
}
}
}); });
if (CollectionUtils.isEmpty(list)) { if (CollectionUtils.isEmpty(list)) {
return Collections.emptyList(); return Collections.emptyList();
......
...@@ -69,4 +69,14 @@ ...@@ -69,4 +69,14 @@
WHERE t1.id = #{businessEntityInfoId} AND t2.year = #{year} WHERE t1.id = #{businessEntityInfoId} AND t2.year = #{year}
limit 1 limit 1
</select> </select>
<select id="selectBusinessEntityTaxByBusinessEntityInfoId"
resultType="com.ruoyi.system.domain.house.BusinessEntitySell">
SELECT
t2.*
FROM
business_entity_info t1
LEFT JOIN business_entity_sell t2 ON t1.id = t2.business_entity_info_id
WHERE t1.id = #{businessEntityInfoId} AND t2.year = #{year}
limit 1
</select>
</mapper> </mapper>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment