on 2023 Mar 29 10:09 AM
Hello everyone,
we are using S/4HANA Service OP 2021 and we create SD Billing Requests from Service Confirmations.
In our Service Confirmation we maintain some custom Partners which we would like to see in the Billing Request too, so we are able to create forms and invoices with e.g. custom Contact Persons attached:
Unfortunately only the four main Party Roles (Sold-to-Party, Bill-to-Party, Payer-Party and Ship-to-Party) are copied from Service Confirmation to Billing Request:
Therefore the question arises how we are able to copy our custom roles too. There is no real copy control between S/4 Service and S/4 Sales. Because of that we analysed the abap code in backend during data exchange between those two LoB's.
It seems like that by standard coding only the four Party Roles described above are used for creation of billing requests:
Is there any way to unify the Partner header data between our two documents apart from redefining the method above or has anyone successfully managed to implement our requirement?
Thanks for your help in advance!
Best regards,
Thomas Prekel
Request clarification before answering.
Hi tprekel & Dennis,
I'm currently processing the incident reported by you "Forwarding Service Confirmation Partners to Billing Requests in S/4HANA Service"
I also thought that system used the old CRM setting "Mapping Partner Function", however I received the following information from our colleagues from development support :
"The customizing of partner mapping you have mentioned is only relevant for external billing scenario in suite.This is not related to Service solution in S4 Hana Service solution.
The partner mapping in your current release is only transferring the following partner from the service document to the BDR:
'AG' = 'SOLDTOPARTY'
'RE' = 'BILLTOPARTY'
'RG' = 'PAYERPARTY'
'WE' = 'SHIPTOPARTY'
Currently the interface for creating the BDR from service document does not allow processing of additional partners within your release. There are enhancements to this interface being done (to allow additional partners), but this will be available only with S/4HANA OP 2021.
So if you would like to add additional partners in your current release, I would like you to use the standard invoice userexits in includes RV60AFZA / RV60AFZD.
FORM USEREXIT_AVBPAK_ADD will probably fit best.
You will need to read the data from the predecessor document and adapt the partner tables accordingly"
This answer means :Anja Hartmann 's solution is valid from 2021 (your version) . You can choose it or use the enhance FORM USEREXIT_AVBPAK_ADD as my colleague explained.
Customer with versions lower than 2021 can't redefine the method CL_CRMS4_BILLING_PROCESS_FWD. so they MUST use the SD user-exit
I think that this information is interesting for all S/4HANA Consultants so I share it.
Best regards
Silvia Ventura
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Thomas,
I actually had some problems with redefining and therefore added an Enhancement at the end of method "PARTNER_AND_ADDRESS_ASSIGNMENT" of class CL_CRMS4_BILLING_PROCESS_FWD.
Additionally I had to map partners in Customizing
Service -> Basic Functions -> Partner Processing -> Map Partner Functions
Mapping did not work for all Partner Function Categories. I coudn't manage to map a partner function of partner function category 0012 Vendor.
Regards Anja
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Thomas,
we have the same problem and only managed it by a redefinition / assignment.
We added the following coding at the end of the mothod:
DATA: ls_billing_partner TYPE bapiparnr4,
lv_businesspartner TYPE bu_partner,
lv_employeeid TYPE pernr_d,
lv_parnr TYPE parnr.
LOOP AT ct_billing_item ASSIGNING <ls_billing_item_ext>.
lv_item_id = <ls_billing_item_ext>-precedingdocumentitem.
LOOP AT it_billing_partner ASSIGNING <ls_billing_partner>
WHERE itm_number = lv_item_id
AND partn_role NE 'AG'
AND partn_role NE 'RE'
AND partn_role NE 'RG'
AND partn_role NE 'WE'.
ls_billing_partner-partn_role = <ls_billing_partner>-partn_role.
ls_billing_partner-partn_numb = <ls_billing_partner>-partn_numb.
INSERT fill_ebdr_request_party_line( is_billing_header = is_billing_header
is_billing_item = <ls_billing_item_ext>
is_billing_partner = ls_billing_partner )
INTO TABLE et_ebdr_request_party.
ENDLOOP.
LOOP AT it_billing_partner ASSIGNING <ls_billing_partner>
WHERE itm_number = lc_itm_number_init
AND partn_role NE 'AG'
AND partn_role NE 'RE'
AND partn_role NE 'RG'
AND partn_role NE 'WE'.
READ TABLE it_billing_partner TRANSPORTING NO FIELDS
WITH KEY itm_number = lv_item_id
partn_role = <ls_billing_partner>-partn_role.
IF sy-subrc = 0.
CONTINUE.
ENDIF.
ls_billing_partner-partn_role = <ls_billing_partner>-partn_role.
IF ls_billing_partner-partn_role = 'YM' OR ls_billing_partner-partn_role = 'ZM'.
lv_businesspartner = <ls_billing_partner>-partn_numb.
CALL FUNCTION 'BAPI_BUPA_GET_EMPLOYEE_FROM_BP'
EXPORTING
businesspartner = lv_businesspartner
IMPORTING
employeeid = lv_employeeid.
ls_billing_partner-partn_numb = lv_employeeid.
ELSEIF ls_billing_partner-partn_role = 'AP'.
SELECT SINGLE customer_cont FROM cvi_cust_ct_link INTO lv_parnr
WHERE person_guid = <ls_billing_partner>-partn_guid.
ls_billing_partner-partn_numb = lv_parnr.
ELSE.
ls_billing_partner-partn_numb = <ls_billing_partner>-partn_numb.
ENDIF.
INSERT fill_ebdr_request_party_line( is_billing_header = is_billing_header
is_billing_item = <ls_billing_item_ext>
is_billing_partner = ls_billing_partner )
INTO TABLE et_ebdr_request_party.
ENDLOOP.
ENDLOOP.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
18 | |
3 | |
2 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.