Commit 6a43aa20 authored by lixuan's avatar lixuan

feat: 房源

parent 15350216
......@@ -81,8 +81,8 @@ public class HouseResourceController {
}
@PostMapping("/saveYearTax")
public AjaxResult postSaveYearTax(@RequestBody YearTaxSaveUpdateDto dto) {
houseResourceService.saveYearTax(dto);
public AjaxResult postSaveYearTax(@RequestBody List<YearTaxSaveUpdateDto> dtos) {
houseResourceService.saveYearTax(dtos);
return AjaxResult.success();
}
}
......@@ -30,5 +30,5 @@ public interface HouseResourceService {
PageBusinessEntityStatisticsDetail pageBusinessEntityStatistics(PageBusinessEntityStatisticsQuery query);
void saveYearTax(YearTaxSaveUpdateDto dto);
void saveYearTax(List<YearTaxSaveUpdateDto> dtos);
}
......@@ -436,11 +436,13 @@ public class HouseResourceServiceImpl implements HouseResourceService {
}
@Override
public void saveYearTax(YearTaxSaveUpdateDto dto) {
BusinessEntitySell businessEntitySell = new BusinessEntitySell();
BeanUtils.copyProperties(dto, businessEntitySell);
businessEntitySell.setId(UUID.randomUUID().toString().replaceAll("-", ""));
businessEntitySellMapper.insertBusinessEntitySell(businessEntitySell);
public void saveYearTax(List<YearTaxSaveUpdateDto> dtos) {
for (YearTaxSaveUpdateDto dto : dtos) {
BusinessEntitySell businessEntitySell = new BusinessEntitySell();
BeanUtils.copyProperties(dto, businessEntitySell);
businessEntitySell.setId(UUID.randomUUID().toString().replaceAll("-", ""));
businessEntitySellMapper.insertBusinessEntitySell(businessEntitySell);
}
}
private List<HouseResourcePage> handleHouseList(List<HouseResourcePage> list) {
......
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