cancel
Showing results for 
Search instead for 
Did you mean: 

Multipane Items Issue

Former Member
0 Kudos

Here is the detailed scenario.

I have an input field. Say Ex: Vendor Number. On entering the value and hitting Enter, i am triggering a Multipane. In the Multipane, The Header consists of 2 Values. One is PO # and the 2 value is Count. this count describes How many items that PO have.

After that i have to display the item deails for the PO. I am getting the PO Header in all panes. Fine. But coming to Item details, only first po Items are getting displayed in the First pane.

This is the issue. Any suggestion is appreciated.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Any Updates guys?

uday_gubbala2
Active Contributor
0 Kudos

Hi Manjunath,

Please check the output snapshots that I get for my application (I have sent them across to your mail) & let me know if its the kind of output that you wanted to get so that I can paste my coding in here.

Regards,

Uday

uday_gubbala2
Active Contributor
0 Kudos

Hi Manjunath,

I will try explain my component in detail. I have created 3 nodes at context level, INPUT (with attribute LIFNR under it & am binding it to my input field), EKKO (It has just 1 attribute EBELN under it) & EKPO (This I have created as subnode of EKKO & contains all the attributes that you want to display in the table.) I have associated a supply function S_FILL_PO_ITEMS for the subnode EKPO & an eventhandler FETCH_DATA for the event onEnter of the input field.

Below is my coding in the event handler method:

METHOD onactionfetch_data .
  DATA: lr_node TYPE REF TO if_wd_context_node,
        lv_lifnr TYPE wd_this->element_input-lifnr,
        lt_ekko TYPE wd_this->elements_ekko,
        wa_ekko TYPE wd_this->element_ekko.

  lr_node = wd_context->get_child_node( name = if_main=>wdctx_input ).
  lr_node->get_attribute( EXPORTING name  = 'LIFNR'
                          IMPORTING value = lv_lifnr ).

  SELECT ebeln INTO TABLE lt_ekko FROM ekko WHERE lifnr = lv_lifnr.
  IF sy-subrc <> 0.
"  Raise an error message if no PO exists for the entered vendor
    CALL METHOD wd_this->gv_message_manager->report_error_message
      EXPORTING
        message_text = 'No purchase orders exist for this vendor!'.
  ELSE.
"  Get the PO details & bind them to node EKKO
    lr_node = wd_context->get_child_node( name = if_main=>wdctx_ekko ).
    lr_node->bind_table( new_items = lt_ekko ).
  ENDIF.
ENDMETHOD.

This is my coding within the supply function

METHOD s_fill_po_items .
  DATA: ls_parent_attributes TYPE wd_this->element_ekko,
        lt_ekpo TYPE wd_this->elements_ekpo,
        ls_ekpo LIKE LINE OF lt_ekpo.

" This would result in the ststem fetching the PO number value being displayed in the current pane
  parent_element->get_static_attributes( IMPORTING static_attributes = ls_parent_attributes ).

" Use the obtained current PO number to fetch relevant PO item details
  SELECT * FROM ekpo INTO CORRESPONDING FIELDS OF TABLE lt_ekpo WHERE ebeln = ls_parent_attributes-ebeln.

  node->bind_table( new_items = lt_ekpo ).
ENDMETHOD.

Regards,

Uday

Answers (0)