Hi experts,
My requirement is to realize a clear function like the standard search page on my own Zview to clear the search criteria inputted by user.
The problem is that even i clear the data in the context node, the data is still shown on UI, like a browser buffer problem..
But the standard view works well.
So if you have any idea on this, please kindly help me.
Thanks in advance.
Blow is my code in clear method..
METHOD eh_onclear.
DATA:
lr_col_wrap TYPE REF TO if_bol_bo_col,
lr_current TYPE REF TO cl_crm_bol_query_service,
lr_value_node TYPE REF TO cl_bsp_wd_value_node,
lr_struct_ref TYPE zclm_search_ui.
FIELD-SYMBOLS:
<struct_ref> TYPE any.
* create new value entity; clear collection; add entity to collection
lr_col_wrap ?= me->typed_context->CUSCLMQUERY->get_collection_wrapper( ).
lr_current ?= lr_col_wrap->get_current( ).
lr_current->get_properties( IMPORTING es_attributes = lr_struct_ref ).
CLEAR lr_struct_ref.
lr_current->set_properties( EXPORTING is_attributes = lr_struct_ref ).
* reset invalid input in context node
me->typed_context->CUSCLMQUERY->if_bsp_model~reset_errors( ).
ENDMETHOD.