/
8.3. BAdI to get the name reason

8.3. BAdI to get the name reason

Definition of the BADI: /EDGE/BADI_SII_NOMBRE_RAZON.

BAdI interface: /EDGE/IF_SII_NOMBRE_RAZON

Default implementation in the product: Yes

Implementation class: /EDGE/CL_SII_NOMBRE_RAZON

Uso: Mapping for "Nombre razón"

Methods:

  • GET_NOMBRE_RAZON:  Map the name reason from a NIF to be able to make the pagination in some specific cases. In this method the mapping of the name reason field is performed from the NIF and it is called from the corresponding communication class for the MESSAGE_CONCILIA method. When a query of more than 10,000 records is made, it is necessary to inform the paging structure with the fields:
    • NIF
    • CODIGO_PAIS
    • IDTYPE
    • ID
    • NOMBRE_RAZON
    • FECHA_EXPEDICION_FACTURA_EMISO
    • NUM_SERIE_FACTURA_EMISOR

When the reconciliation is made for received invoices in the response structure of the query, in the part of the Invoice ID, the name reason is not indicated, so it is necessary to take it from another site to inform the paging structure. In an invoice that is not DUA this data is taken from the counterparty, however when the invoice is DUA, the counterpart corresponds to the holder and not to the Invoice ID so the data name reason is not correct to take it from there.

For this case, this BAdI has been created, which is called at this moment by passing the NIF and from this, search the master data and return the field name reason that will be mapped to the paging structure so that it is able to continue with the reconciliation from record 10,001.

Avvale 2024