web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Unanswered

How to Apply discount on Tax inclusive amount for Customer Retention in Sales Order

(3) ShareShare
ReportReport
Posted on by 2,334
Hi,
 
How can we customize the Sales Order Invoice Posting so as to apply discount at invoice level on tax inclusive amount.
 
In UBL2.0 XML there is header level discount which applies to Total Invoice Amount (Including Tax) which reduces the Payable amount by retention amount. Later this retention amount can be separately invoiced. 
 
Looking for some pointers to start the customization in Sales Order. Not using Project management module. Even in project management, retention is first applied before tax calculations.
 
Thanks
Categories:
I have the same question (0)
  • André Arnaud de Calavon Profile Picture
    303,691 Super User 2026 Season 1 on at
    Hi MYGz,

    Can you explain more details please? I haven't seen customer retention being used with sales order invoices before. Is this a customization or are you applying a discount? Do you need help with customizations within Dynamics 365 or do you need help how to map particular data from Dynamics 365 to the UBL2.0 header information? Are you using Electronic Reporting to build the data model for the UBL generation?
  • MYGz Profile Picture
    2,334 on at
     
    I am looking or some tips on how to do customization in D365 F&O for retention invoice in sales order
    (or even for Project  Invoice, since it has the same retention behavior i.e retention amount is subtracted before tax calculation)
     
    Customization which can be then mapped to UBL 2.0 XML standard. I am not using electronic reporting, there's a middleware that accepts the data in json format similar to the ubl xml structure.
     
    Here's an article where it says VAT is to be paid on full for construction even if customer retention amount is there.
     
    Does that mean for a base amount of 100 and a 10% retention and 15% VAT, the total invoice amount should be 105 [100 (Base amount) +15 (VAT) -10(Retention)]. This can be achieved in UBL XML by applying header discount. In D365 FO I didn't find any concept of header discount, everything has to be allocated at line level.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Congratulations to our 2025 Community Spotlights

Thanks to all of our 2025 Community Spotlight stars!

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
Giorgio Bonacorsi Profile Picture

Giorgio Bonacorsi 617

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 461 Super User 2026 Season 1

#3
Syed Haris Shah Profile Picture

Syed Haris Shah 298 Super User 2026 Season 1

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans