Hello,
I'm trying to add a "Product", "Quantity" and "Unit of Measure" under the Item Details section of Txn CRMD_ORDER when creating a new service ticket using the BAPI "BAPI_BUSPROCESSND_CREATEMULTI". Here is the code I'm using but it does not work. Please note that I am calling BAPI_BUSPROCESSND_SAVE and BAPI_TRANSACTION_COMMIT after the first BAPI call. All my other fields go through fine and the ticket does get created. But somehow, these Item Details don't work. Any help is appreciated.
Item Product Id
ls_item-handle = '0000000001'.
ls_item-header_handle = '0000000001'.
ls_item-ordered_prod = 'GENERIC_TT_PROD'.
ls_item-number_int = 10. "'0000000010'.
APPEND ls_item TO lt_item.
Product Id: Input fields
ls_input_fields-ref_handle = '0000000001'.
ls_input_fields-ref_kind = 'A'.
ls_input_fields-objectname = 'ORDERADM_I'.
ls_input_fields-fieldname = 'ORDERED_PROD'.
ls_input_fields-changeable = 'X'.
APPEND ls_input_fields TO lt_input_fields.
ls_input_fields-ref_handle = '0000000001'.
ls_input_fields-ref_kind = 'A'.
ls_input_fields-objectname = 'ORDERADM_I'.
ls_input_fields-fieldname = 'NUMBER_INT'.
ls_input_fields-changeable = 'X'.
APPEND ls_input_fields TO lt_input_fields.
Product UoM
ls_product-ref_handle = '0000000001'.
ls_product-process_qty_unit = 'HRS'.
APPEND ls_product TO lt_product.
Product UoM: Input fields
ls_input_fields-ref_handle = '0000000001'.
ls_input_fields-ref_kind = 'A'.
ls_input_fields-objectname = 'PRODUCT_I'.
ls_input_fields-fieldname = 'PROCESS_QTY_UNIT'.
ls_input_fields-changeable = 'X'.
APPEND ls_input_fields TO lt_input_fields.
Quantity
Scheduline Details
ls_schedlines-item_handle = '0000000001'.
ls_schedlines-handle = '0000000001'.
ls_schedlines-quantity = 1.
APPEND ls_schedlines TO lt_schedlines.
Scheduline: Input fields
ls_input_fields-ref_handle = '0000000001'.
ls_input_fields-ref_kind = 'A'.
ls_input_fields-objectname = 'SCHEDLIN'.
ls_input_fields-fieldname = 'QUANTITY'.
ls_input_fields-changeable = 'X'.
APPEND ls_input_fields TO lt_input_fields.