diff --git a/connector-api/src/main/java/it/pagopa/selfcare/external_interceptor/connector/model/institution/BillingToSend.java b/connector-api/src/main/java/it/pagopa/selfcare/external_interceptor/connector/model/institution/BillingToSend.java new file mode 100644 index 0000000..f9b3af5 --- /dev/null +++ b/connector-api/src/main/java/it/pagopa/selfcare/external_interceptor/connector/model/institution/BillingToSend.java @@ -0,0 +1,10 @@ +package it.pagopa.selfcare.external_interceptor.connector.model.institution; + +import lombok.Data; + +@Data +public class BillingToSend { + private String vatNumber; + private String recipientCode; + private boolean publicService; +} diff --git a/connector-api/src/main/java/it/pagopa/selfcare/external_interceptor/connector/model/institution/NotificationToSend.java b/connector-api/src/main/java/it/pagopa/selfcare/external_interceptor/connector/model/institution/NotificationToSend.java index 10b7b09..32d0446 100644 --- a/connector-api/src/main/java/it/pagopa/selfcare/external_interceptor/connector/model/institution/NotificationToSend.java +++ b/connector-api/src/main/java/it/pagopa/selfcare/external_interceptor/connector/model/institution/NotificationToSend.java @@ -21,7 +21,7 @@ public class NotificationToSend { private InstitutionToSend institution; private String fileName; private String contentType; - private Billing billing; + private BillingToSend billing; private UserToSend user; } diff --git a/connector/kafka-manager/src/test/java/it/pagopa/selfcare/external_interceptor/connector/kafka_manager/factory/SendSapNotificationTest.java b/connector/kafka-manager/src/test/java/it/pagopa/selfcare/external_interceptor/connector/kafka_manager/factory/SendSapNotificationTest.java index 078962b..78571b5 100644 --- a/connector/kafka-manager/src/test/java/it/pagopa/selfcare/external_interceptor/connector/kafka_manager/factory/SendSapNotificationTest.java +++ b/connector/kafka-manager/src/test/java/it/pagopa/selfcare/external_interceptor/connector/kafka_manager/factory/SendSapNotificationTest.java @@ -248,6 +248,7 @@ void sendInstitutionNotificationUo() throws JsonProcessingException { NotificationToSend captured = mapper.readValue(producerRecordArgumentCaptor.getValue().value(), NotificationToSend.class); checkNotNullFields(captured, "user"); checkNotNullFields(captured.getInstitution()); + assertEquals("setTaxCodeInvoicing", captured.getInstitution().getTaxCode()); } @Test