|
|
@@ -16,9 +16,7 @@ import com.jzg.commons.entity.vo.AgreementVo;
|
|
|
import com.jzg.commons.entity.vo.InsFeeOrdersVo;
|
|
|
import com.jzg.commons.util.idgen.IdGenerate;
|
|
|
import com.jzg.organization.client.InsOrdersClient;
|
|
|
-import com.jzg.organization.excel.listener.InvoiceReceivbleExcel4PlatformListener;
|
|
|
-import com.jzg.organization.excel.listener.InvoiceReceivbleExcel4PrivateListenerCar;
|
|
|
-import com.jzg.organization.excel.listener.InvoiceReceivbleExcel4PrivateListenerNoCar;
|
|
|
+import com.jzg.organization.excel.listener.InvoiceReceivbleExcel4AllListener;
|
|
|
import com.jzg.organization.mapper.InsOrdersPolicyMapper;
|
|
|
import com.jzg.organization.mapper.InsPlyIncomeMapper;
|
|
|
import com.jzg.organization.mapper.PtlAgreementMapper;
|
|
|
@@ -248,9 +246,11 @@ public class ImportIncomeServiceImpl implements ImportIncomeService {
|
|
|
ext.setSigningTime(data.getSigningTime().format(DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss")));
|
|
|
}
|
|
|
String agreementId = data.getAgreementId();
|
|
|
- AgreementVo agreementVo = ptlAgreementMapper.queryById(agreementId);
|
|
|
- if(agreementVo != null){
|
|
|
- ext.setPartnerCompanyId(agreementVo.getPartnerCompanyId());
|
|
|
+ if(StrUtil.isNotEmpty(agreementId)){
|
|
|
+ AgreementVo agreementVo = ptlAgreementMapper.queryById(agreementId);
|
|
|
+ if(agreementVo != null){
|
|
|
+ ext.setPartnerCompanyId(agreementVo.getPartnerCompanyId());
|
|
|
+ }
|
|
|
}
|
|
|
InsFeeOrdersVo feeOrdersVo = data.getFeeOrdersVo();
|
|
|
if(BeanUtil.isEmpty(feeOrdersVo)){
|
|
|
@@ -272,14 +272,14 @@ public class ImportIncomeServiceImpl implements ImportIncomeService {
|
|
|
* @date 2026/8/4 9:07
|
|
|
*/
|
|
|
public List<ExcelContent4Platform> parseImportExcel4Platform(MultipartFile file) {
|
|
|
- InvoiceReceivbleExcel4PlatformListener listener = new InvoiceReceivbleExcel4PlatformListener();
|
|
|
+ InvoiceReceivbleExcel4AllListener<ExcelContent4Platform> listener = new InvoiceReceivbleExcel4AllListener<>();
|
|
|
try (InputStream inputStream = file.getInputStream()) {
|
|
|
EasyExcel.read(inputStream, ExcelContent4Platform.class, listener)
|
|
|
.sheet()
|
|
|
.doRead();
|
|
|
return listener.getDataList();
|
|
|
} catch (Exception e) {
|
|
|
- log.error("InvoiceReceivbleExcel4PlatformListenery读取文件异常",e);
|
|
|
+ log.error("InvoiceReceivbleExcel4AllListener处理平台应收数据读取文件异常",e);
|
|
|
return null;
|
|
|
}
|
|
|
}
|
|
|
@@ -291,14 +291,14 @@ public class ImportIncomeServiceImpl implements ImportIncomeService {
|
|
|
* @date 2026/8/4 9:07
|
|
|
*/
|
|
|
public List<ExcelContent4PrivateSuperviseNoCar> parseImportExcel4PrivateNoCar(MultipartFile file) {
|
|
|
- InvoiceReceivbleExcel4PrivateListenerNoCar listener = new InvoiceReceivbleExcel4PrivateListenerNoCar();
|
|
|
+ InvoiceReceivbleExcel4AllListener<ExcelContent4PrivateSuperviseNoCar> listener = new InvoiceReceivbleExcel4AllListener<>();
|
|
|
try (InputStream inputStream = file.getInputStream()) {
|
|
|
EasyExcel.read(inputStream, ExcelContent4PrivateSuperviseNoCar.class, listener)
|
|
|
.sheet()
|
|
|
.doRead();
|
|
|
return listener.getDataList();
|
|
|
} catch (Exception e) {
|
|
|
- log.error("InvoiceReceivbleExcel4PlatformListenery读取文件异常",e);
|
|
|
+ log.error("InvoiceReceivbleExcel4AllListener处理私有非车险数据读取文件异常",e);
|
|
|
return null;
|
|
|
}
|
|
|
}
|
|
|
@@ -312,7 +312,7 @@ public class ImportIncomeServiceImpl implements ImportIncomeService {
|
|
|
*/
|
|
|
@Override
|
|
|
public List<ExcelContent4PrivateSuperviseCar> parseImportExcel4PrivateCar(MultipartFile file) {
|
|
|
- InvoiceReceivbleExcel4PrivateListenerCar listener = new InvoiceReceivbleExcel4PrivateListenerCar();
|
|
|
+ InvoiceReceivbleExcel4AllListener<ExcelContent4PrivateSuperviseCar> listener = new InvoiceReceivbleExcel4AllListener<>();
|
|
|
try (InputStream inputStream = file.getInputStream()) {
|
|
|
EasyExcel.read(inputStream, ExcelContent4PrivateSuperviseCar.class, listener)
|
|
|
.sheet()
|