Hi Team,
My requirement is Create column at item level for STAGE LOCATION as drop down. drop down should populate value from custom table based on item type ..
for this i have created one AET field i.e Stage location and i have added this field on Complaint creation screen of ITEM Assignment block..For this i have created Z table which contains two fields Item_type and Sales stage. they are maintained item type - zjm,zti,zrt,sales stages value 1000,1200,1300 like that values they are created.
For getting drop down i have implemented Get_p and get_v methods.in get_v i have added the logic as below..
DATA: lt_sel_table TYPE bsp_wd_dropdown_table,
ls_sel_table TYPE LINE OF bsp_wd_dropdown_table,
lr_ddlb TYPE REF TO cl_crm_uiu_ddlb.
DATA : lt_item TYPE TABLE OF zlocation,
ls_item TYPE zlocation
******* Write your Selection lgic to fill lt_ddlb
SELECT *
FROM zlocation
INTO TABLE lt_item.
IF sy-subrc EQ 0.
INSERT INITIAL LINE INTO lt_sel_table INDEX 1. "This is for blank value
LOOP AT lt_item INTO ls_item.
ls_sel_table-key = ls_item-item_type.
ls_sel_table-value = ls_item-sloc.
APPEND ls_sel_table TO lt_sel_table.
CLEAR: ls_sel_table, ls_item.
ENDLOOP.
ENDIF.
CREATE OBJECT lr_ddlb
EXPORTING
iv_source_type = 'T'.
lr_ddlb->set_selection_table( it_selection_table = lt_sel_table ).
rv_valuehelp_descriptor = lr_ddlb.
Now iam getting drop down and drop down values..exact requirement is user based on item category created user supppoe item category is ztre then storage location 1000 it is set ,based on that item category storage should get popultaed..these values are maintained on ztable.then how to do it..please help hee.
Thanks
Kalpana