Screen exit MEREQ001- Copy 1 PR line item custom fields values in all
Hi,
I have implemented the Enhancement MEREQ001 to add a new tab for Purchase Requistion screen at line item level .
Requirement for me is to show the same data in the newly added tab for all line items and also to save the same data in EBAN table.
I am facing a problem while saving the data. In EBAN table, the data was saved for all line items. But the custom added field values are saved for only the line item displayed.
I ll explain with an example for better understanding.
I have created a PR with 3 line items ITEM1, ITEM2 ,and ITEM2
When i saved the data when ITEM1 is displayed, EBAN have custom added field values for ITEM1 but not for ITEM2 and item3.
The same way, if I save data when ITEM2 is displayed, EBAN has custom added field values for ITEM2 but not for ITEM3 and ITEM1.
Now, my requirement is to get the all line items ITEM1 & ITEM2 and ITEM3 updated with custom added field values in EBAN.
The logic i added in ME_PROCESS_REQ_CUST~CHECK are as below.
i_items TYPE mmpur_requisition_ite ,
lv_if_item TYPE REF TO if_purchase_requisition_item,
lt_itm_data TYPE mereq_item .
DATA : LV_dept TYPE EBAN-ZZDEPARTMENT ,
lx_itm_data type mereq_itemx.
CALL METHOD im_header->get_items
RECEIVING
re_items = i_items.
LOOP AT i_items INTO wa_item.
lv_if_item = wa_item-item.
CALL METHOD lv_if_item->get_data
RECEIVING
re_data = lt_itm_data.
CALL METHOD lv_if_item->get_datax
RECEIVING
re_datax = lx_itm_data.
IF lt_itm_data-zzdepartment IS INITIAL.
lt_itm_data-zzdepartment = LV_dept .
lx_itm_data-zzdepartment = 'X' .
ELSE.
Lv_dept = lt_itm_data-zzdepartment.
ENDIF.
To set the value for all line item.
CALL METHOD lv_if_item->SET_DATAX
EXPORTING
IM_DATAX = lx_itm_data.
CALL METHOD lv_if_item->Set_data
EXPORTING
IM_data = lt_itm_data.
ENDLOOP. " LOOP AT i_items INTO wa_item.
ENDIF. " IF ( NOT ls_header1-banfn IS INITIAL
BUT above logic is not working
Please give your inputs
Thanks in advance
Deepanker Dwivedi
HI,
You can use GET CURSOR LINE LINE_NO this will give you the sy-index so that you can read the itab like
read table itab index line_no. This is one option and second is if you have row selector.
read table itab with key mark = 'X'.
If you want the Row contents befor the PAI triggers
[Check this Thread|Table Control dynamic F4;
Hope this is clear to you.
Regards
Ram
Similar Messages
-
PO service item - custom field value not copied to GR
Hi All,
I have a custom field in SC,PO and GR. For a sevice and limit items, the value in custom field in PO is not copied to GR. For goods, it is copied.
When I debugged, I found that the system tries to match PO item internal number with that of backend item internal number. If this is matched, the custom field values are copied.
But here it is not matched. What can be the possible reason. Is there any configuration for item internal numbers?
I found a note 848797 for transfer. But exactly at the corrected code in note, program is failing.
Have anyone faced this issue before?
Thanks
NandalalYes Disha, the notes are correctly implemented.
I am confused on whether the internal number generated for the item is copied from some configured internal range, because when I enter two service items, the items shows backend internal numbers like 0000000010 and 0000000020 (increment by 10). But in SRM it is 0000000001 and 0000000002.
When the code tries to match the respective numbers, it fails and skips the logic to copy custom fields.
I dont have access to r/3 data.
Please help.
Have anyone tried to create a GR with service item and has custom field?
Thanks
Nandalal -
Want to copy Delivery address of one line item in shopping cart to all item
Hi Experts,
We are upgrading from SRM 5.0 to SRM 7.0,In SC Creation We want to copy Delivery address of one line item in shopping cart to all line items in Shopping cart by clicking Change All Items button.This is custom button we added this button and we had written code to achieve the functionality but it is not working.This is same like Change All Items button in Account Assigment for copy accont details of one line item to all other line items in SC.
Web Dynpro Component:/SAPSRM/WDC_UI_DO_SHIPTO
Web Dynpro View:V_DODC_SHIPTO
Thanks,
Aarthi.Hi Prasad,
Our customer needs that button,they want whenever they are clicking the button delivery address should copy to all line items.
In my action ONCHANGE_ALL_ITEMS i called this method
wd_this->mo_dodm_shipto->zchange_all_items( ).
zchange_all_items( ) is implemented in class /SAPSRM/CL_CH_WD_DODM_SHIPTO.
the code i wrote inside zchange_all_items( )
*Error
DATA: LX_PDO_ABORT TYPE REF TO /SAPSRM/CX_PDO_ABORT, " Class for Fatal error caught by PDO Layer
LX_PDO_ERROR TYPE REF TO /SAPSRM/CX_PDO_ERROR. " Class for PDO General Exception
Object Instances
DATA: LO_MSG_CONSUMER TYPE REF TO /SAPSRM/IF_PDO_MSG_CONSUMER,
LO_PDO_SHIPTO TYPE REF TO /SAPSRM/IF_PDO_DO_PARTNER.
Context-Data
DATA: lte_cll_shipto TYPE /sapsrm/if_ch_wd_set_facade=>gt_guid_element,
loe_cll_shipto TYPE REF TO /sapsrm/if_ch_wd_set_element.
Field Symbols
FIELD-SYMBOLS <lse_cll_shipto> LIKE LINE OF lte_cll_shipto.
DATA : lo_pdo_acc TYPE REF TO /sapsrm/if_pdo_do_acct_assgmnt.
DATA : ls_shipto_cll type /SAPSRM/S_CLL_SHIPTO,
lt_pdo_partnerdetails TYPE bbp_pdt_partner,
ls_pdo_partnerdetails TYPE bbp_pds_partner,
LV_GUID TYPE BBP_GUID,
lv_item_guid type bbp_guid,
lv_filled TYPE wdy_boolean.
*exceptions
DATA : LX_ABORT TYPE REF TO /SAPSRM/CX_PDO_ABORT.
*Constants
CONSTANTS : LC_OBJECT_ID TYPE CRMT_SUBOBJECT_CATEGORY_DB VALUE 'BUS2121001',
LC_ADDR_ORIGIN TYPE /SAPSRM/S_CLL_SHIPTO-ADDR_ORIGIN VALUE 'B'.
IF LV_FILLED = ABAP_TRUE.
Downcasting to shipto
LO_PDO_SHIPTO ?= MO_PDO.
insert the clipboard into facade and update and submit update
me->/sapsrm/if_cll_do_mapper~insert_from_clipboard( io_set_facade = mon_cll_set_facade ).
Add new Accounting entries.
lte_cll_shipto = mon_cll_set_facade->get_data_elements( ). "get all elements from the context
LOOP AT lte_cll_shipto ASSIGNING <lse_cll_shipto>.
loe_cll_shipto = <lse_cll_shipto>-set_element.
loe_cll_shipto->get_static_attributes( IMPORTING rv_attributes = ls_shipto_cll ).
Map ui-structure to pdo-structure
MOVE-CORRESPONDING ls_shipto_cll TO ls_pdo_partnerdetails.
IF LS_SHIPTO_CLL-PARTNER_FCT = mv_part_func.
LS_PDO_PARTNERDETAILS-PARTNER_FCT = ''.
ELSE.
LS_PDO_PARTNERDETAILS-PARTNER_FCT = LS_SHIPTO_CLL-PARTNER_FCT.
ENDIF.
IF ls_pdo_partnerdetails-del_ind NE 'X'.
CALL FUNCTION 'GUID_CREATE'
IMPORTING
ev_guid_16 = ls_pdo_partnerdetails-p_guid.
mv_acc_guid_split = ls_pdo_shipto-guid .
IF mo_scope = 1.
ls_pdo_partnerdetails-p_guid = mon_cll_set_facade->get_bo_guid( ).
ELSE.
ls_pdo_partnerdetails-p_guid = mo_parent_bo_mapper->items_get_lead_selection( ).
ENDIF.
APPEND ls_pdo_partnerdetails TO lt_pdo_partnerdetails.
ENDIF.
CLEAR : ls_pdo_partnerdetails, ls_shipto_cll.
ENDLOOP.
Add New items to PDO
IF NOT lt_pdo_partnerdetails[] IS INITIAL.
TRY.
LO_PDO_SHIPTO->update_item_partners( EXPORTING it_partner = lt_pdo_partnerdetails
iv_item_guid = lv_item_guid
CHANGING co_message_handler = mo_pdo_message_consumer ).
CATCH /sapsrm/cx_pdo_abort INTO lx_pdo_abort.
mo_cll_message_handler->set_abort( io_pdo_abort_exception = lx_pdo_abort ).
CATCH /sapsrm/cx_pdo_error INTO lx_pdo_error.
mo_cll_message_handler->add_exception( io_pdo_error_exception = lx_pdo_error ).
ENDTRY.
Update PDO with the changed data.
TRY.
mo_pdo->submit_update( ).
CATCH /sapsrm/cx_pdo_abort INTO lx_pdo_abort.
mo_cll_message_handler->set_abort( io_pdo_abort_exception = lx_pdo_abort ).
CATCH /sapsrm/cx_pdo_error INTO lx_pdo_error.
mo_cll_message_handler->add_exception( io_pdo_error_exception = lx_pdo_error ).
ENDTRY.
Fire refresh of DO Mappers registered for refresh since the item table has acc related data.
mo_parent_bo_mapper->fire_event_refresh( iv_perform_updates = abap_false ).
ENDIF.
ENDIF.
Thanks,
Aarthi. -
Vendor Line Item Display-Default value for customer items
Is it possible in selection screen of transaction FBL1N (Vendor line item display) the default value of field "customer items" to be checked?
Thanks in advance.hi Tsiami
it's not possible. if u want check customer line items go throw this TC:FBL5N
plz assign points
regards
sivareddy. -
Is there a user exit to modify PO line item level..
Dear Friends,
Is there a user exit to modify PO line item level..
RaviHi...I'm not sure on any available customer exits for this purpose. However you can use the check function exit 'EXIT_SAPMM06E_012' of customer exit MM06E005 and using memory pointers you can change the item level data.
The other option is to use BADI ME_PROCESS_PO_CUST's method PROCESS_ITEM to change the item level value. I would prefer the BADI rather than the customer exit.. Hope it works..
Thanks,
Jude -
Transaction VKM1 - Changes Sales Order Line Items Custom Fileds
Hi,
I have a challenge to indentify the impact of VKM1 on a Sales Order Line Item Customer Enhanced Fields. When credit hold for the customer is released in VKM1, I want to prevent some of the changes to the line items in the User Exit. The Problems I am not sure, How VKM1 is calling the Transaction VA02 or those Sales Order User Exits to modify certain customer enhanced fields. I tried Activation of Break Point in Update Task but did not stop at the Break points set up in the User Exit. How does Transaction VKM1 call the Sales Orders to execute changes? Is it through BAPI or Call Transaction VA02 or some thing else.
Can any One please help me? Appreciate Your Help in advance.
Thanks,
KannanVKM1 uses FM SD_ORDER_CREDIT_RELEASE to release orders on credit.
-
SRM 4.0: Source of Supplier not copying in line item on Shopping Cart
We are using SRM 4.0 in an extended classic setup and currently experiencing a problem with the source of supplier not being copied on line items. The user stated that when copying a line items in a shopping cart the source of supplier is not copying to the new line. It happens sometimes but not everytime the client uses the line copy option.
It was initially thought that based on the amount of the line item (>=$25,000) that would cause the source of supplier (vendor) not to copy to the new line item but it has been verified by client that is not the case. If anyone has seen this issue and know of what the root cause could be please let me know.
ThanksYann,
Actually this is occurring when the user is creating a shopping cart from scratch. He added a line item either from catalog or free text, sources the item and then uses the copy function to copy the line item. When the client does this the item is copied but the vendor disappears from the 2nd line item and client has to add it again.
So that OSS notes doesn't apply unless I'm missing something. -
User Exit for Purchase Order Line Items.
I have been trying to search for a User Exit for Purchase Order Line Items and have been unable to do find anything. I need to overwrite the Net Price and Pricing Condition on a certain type of material based upon the Pricing Condition for that Line Item which is on the Sales Document. Any direction you can point me into would be greatly appreciated. Thanks.
Thanks for pointing me in the right direction. I was able to create my first BADI using the PROCESS_ITEM method. The following link was also very helpful: Re: BADI ME_PROCESS_PO_CUST Method:PROCESS_ITEM
-
Disable e-mail field when line item created by copying another line item
Hi All,
I need your help. Actually our user wants to create a line item by copying existing line item in shopping cart. While doing so the requirement is the e-mail address field remains disable after the line item is copied. Please guide me how to do it. Please feel free to ask me any further questions.
Regards
Praveen GhoshHi Zaid,
Thank you for your response. Assets are not my area so I’m not sure if I missed a transaction or step in the process. I tested this out by doing the following steps:
Created AUC Asset class with line item checked
Assigned PM Order type as non-investment with no investment profile and created order number
Created a main asset number
Created an AUC sub asset number to step 3
Created settlement rule to sub asset number on order
Posted costs to order
Settled from order to AUC with transaction KO88
Created distribution rules for asset with transaction AIAB
Settled from sub asset to main asset number with transaction AIBU
When I settled from the sub to the main asset number in step 9, I found I lost the line item detail. Is there another configuration setting I need to make to allow me to see the line item detail when I use AIBU?
Thank you, -
Adds selection field at the first screen of FBL3N (G/L line item display)
I would like to adds line item selection field at the default first screen of FBL3N.
The field I'd like to add at the default selection screen is :Amount.
This field can be selected at dynamic selection. But I'd like to use the field at the first screen of FBL3N, not in daynamic selection screen.
If anyone knows how to add the fields into FBL3N first screen, please advice me how to do it.
Edited by: Itchy31 on Jul 23, 2009 8:30 AMHi,
You can not add the new fields in the selection criteria thats the reason dynamic options are given for the further selection.
If you still want to add in the selection screen then go for a customisation and coordinate with the ABAPer which is not suggestable as it is readily avilable in dynamic selection. -
Exit/badi for ME22 line item change
hi gurus,
pls mention any exit/badi for ME22 line item changes......Hi,
Check below thread
BADI in ME21
Regards,
Atish -
Purchase Order item customer fields
I have the following scenario:
- I need to save some customer fields in Purchase Order item, when it is generated through the Shopping Cart (EBP).
- When EBP will generate a PO in backend (R/3), it calls B470_PO_CREATE function module and inside it calls BAPI_PO_CREATE1 in R/3. This call does not use extensionin parameter.
- I have all the values in PO_ITEMS parameters. (an append structure in bapi_mepoitem).
- Trying to solve this, I think I have to use EXIT_SAPL2012_001 to create the extensionin parameter.
- Anyone else has this problem?
- How can I create the extensionin parameter? Is it only necessary to add 'BAPI_TE_MEPOITEM' and 'BAPI_TE_MEPOITEMX'?
- Do you have an example?
Thank you!Hi
You have to extend CI_EKPODBX with the same fieldnames with type BAPIUPDATE (in SE11), and then while passing the EXTENSIONIN to the bapi, you have to flag those. Like the following:
DATA: wa_extensionin TYPE BAPIPAREX,
wa_BAPIPAREX TYPE BAPIPAREX,
wa_BAPI_TE_MEPOITEM TYPE BAPI_TE_MEPOITEM,
wa_BAPI_TE_MEPOITEMX TYPE BAPI_TE_MEPOITEMX.
wa_BAPI_TE_MEPOITEM-po_item = <PO Line No.>.
wa_BAPI_TE_MEPOITEM-ZZZ_FIELD1 = <z-field value>.
wa_BAPIPAREX-STRUCTURE = 'BAPI_TE_MEPOITEM'.
wa_BAPIPAREX-VALUEPART1 = wa_BAPI_TE_MEPOITEM.
APPEND wa_BAPIPAREX TO extensionin.
wa_BAPI_TE_MEPOITEMX-po_item = <PO Line No.>.
wa_BAPI_TE_MEPOITEMX-ZZZ_FIELD1 = 'X'.
wa_BAPIPAREX-STRUCTURE = 'BAPI_TE_MEPOITEMX'.
wa_BAPIPAREX-VALUEPART1 = wa_BAPI_TE_MEPOITEMX.
APPEND wa_BAPIPAREX TO extensionin.
This will work. Please let me know if it does not.
See related links ->
Re: BAPI_PO_CREATE1 and EXTENSIONIN structure
Re: Passing custom fields to BAPI
Problem in populating userfields in PO using BAPI_PO_CREATE1
Re: BAPI_PO_CHANGE
Yann i need ur help..
Re: Custom field values are not being transfered to the backend system
Problem in populating userfields in PO using BAPI_PO_CREATE1
Re: Implement ME_PROCESS_PO_CUST-Urgently!
Re: Purchase Order (BAPI_PO_CREATE! --> EXTENSIONIN)
Re: How to use BAPI extensions?
Re: BAPI_PO_CREATE1 user fields not saving on EKPO
BAPI_PO_CREATE1 - EXIT_SAPL2012_001
Do let me know.
Regards
- Atul -
Sales order with line items having multiple values in multiple currency
Please suggest solution for creating sales order having line items with multiple values in multiple currencies.
e.g. Line Item A Qty/1 No, value 100INR100$100EUR. Customer wants all three values to display at sales order line item level and create billing in 3 currencies.Hi,
As far as my understanding it may be possible round the solution,
For 1 company code we can able to maintain 3 currancies,
1 currancy is hard currance & other two are dual currancies.
Create sales order with 3 line items having 3 diffrant currancies
Spilt invoice on the basis of currancy
Last pass to this invoices to accounting.
Whole process is
Sales order >>> Delivery >>> Invoice 1, Invoice 2, Invoice 3(Split invoice on basis of Currancy).
Consult with FI Team they will tell you about dual currancy & hard currancy
Kapil -
PO Line Item wise gross value for combination of WBS and Material Group
Hello,
Our requirement is to get report for PO Line Item wise gross value for combination of WBS and Material Group. Standard report ME2J gives net price but not gross value for Material Line items. Please let me know if any standard report( or ME2J) will suffice this requirement.
Regards,
Milind DumbreDear Milind
No standard report available to get the PO Line Item wise gross value for combination of WBS and Material Group. Please go for development by taking reference ME2J.
Warm regards
Ramakrishna -
Multi line text custom field is not coming in ms project Professional
Pradeep,
You cannot access Multiline text fields from Project Professional and in Project Server Views. These fields are for use in Project Details pages and with workflow for demand management in Project Server. Please refer to the article shared in earlier post.
I would recommend you to create a Excel/SSRS report if you would like to show data available in this fields to end users.
Hope this helps.
===================================================
Thank you,
Kiran K.
If a post answers your question, please click "Mark As Answer" on that post and "Vote as Helpful
Maybe you are looking for
-
Can I import???
I own a new JVC Hard Drive video camera that records in MPEG-2 format (yeah bummer). Is there anyway of importing into iMovie or other Mac software (like Final Cut...)??? The camera does not have firewire only USB (yeah double bummer). PLEASE say the
-
Confuse which ipsw need i download?
Hello..i want to know. Which ipsw 7.1 i should download for my iphone 5s A1530. is it gsm? cdma? or gsm+cdma?
-
Hello colleagues! I have got new problem during transporting roles via templates. I put content of my role in txt and 2 xls files. After clicking on Foreground button I have got message: "Role not imported; unable to determine matching org. level for
-
My code runs on Java 5. The callables I submit to a given ExecutorService are pure-computational, meaning: no calls to "low-level blocking methods". I'd like these computations to be cancellable in a ASAP fashion: that means I'll sometimes call cance
-
Is it method of creating workflow with screen is correct
I have created the wF and web dynpro deswigned the screens for different steps which include condition, fork and message send this the way to interact the right way or otherwise develop through ABAP development. give some answers to the question