Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Next »

In the Oseberg PEPPOL solution, you can customize your data output using Events. Contact your Business Central partner for implementing custom code.

If you have questions regarding your customization needs, please contact Oseberg Support for assistance.

Extension Development

For customizing the extenison output, On Line and On Prem, you must use events.

app.json

In your app.json file, please add dependency on the app:

    {
      "id": "49206e10-c889-400d-8465-bde6555e00fc",
      "publisher": "Oseberg Solutions AS",
      "name": "E-invoice PEPPOL Bis",
      "version": "17.0.0.0"
    }

Factoring example

When using factoring, you will often need to change your paymentid and bank account according to your Factoring Vendor. You can do this by using the following code:

   [EventSubscriber(ObjectType::Codeunit, Codeunit::"OSB_PEPPOL_Management", 'GetPaymentMeansInfoOnAfterEvent', '', true, true)]
    local procedure "OSB_PEPPOL_Management_GetPaymentMeansInfoOnAfterEvent"
(
    SalesHeader: Record "Sales Header";
    var PaymentCounter: Integer;
    var PaymentCount: Integer;
    var PaymentMeansCode: Text;
    var PaymentMeansListID: text;
    var PaymentChannelCode: text;
    var PaymentID: Text;
    var PrimaryAccountNumberID: Text;
    var NetworkID: Text;
    ProcessedDocType: Enum OSB_Peppol_ProcessedDocType
)
    begin
        PaymentID = GetCustomPaymentId();

    end;


    [EventSubscriber(ObjectType::Codeunit, Codeunit::"OSB_PEPPOL_Management", 'GetPaymentMeansPayeeFinancialAcc_OnAfterEvent', '', true, true)]
    local procedure "OSB_PEPPOL_Management_GetPaymentMeansPayeeFinancialAcc_OnAfterEvent"
    (
        SalesHeader: Record "Sales Header";
        var PaymentCounter: Integer;
        var PaymentCount: integer;
        var PayeeFinancialAccountID: Text;
        var PaymentMeansSchemeID: Text;
        var FinancialInstitutionBranchID: Text;
        var FinancialInstitutionID: Text;
        var FinancialInstitutionSchemeID: Text;
        var FinancialInstitutionName: Text
    )
    begin
        PayeeFinancialAccountID := GetCustomPayeeFinancialAccount();
    end;

  • No labels