cancel
Showing results for 
Search instead for 
Did you mean: 

Need to make "opening date" mandatory in SRM RFx Header Screen

Former Member
0 Kudos
145

Dear All,

Working for SRM component "/SAPSRM/WDC_DODC_RFQ_H_BD" there is field "OPEN_DATE_TIME" which i need to make it mandatory .

There is standard config to do the same but its not happening through that is there any way I could do the same.

I have also tried to enhanced the application and made it mandatory in MODIFYVEW method and given the error message also but it allowed the RFx to get publised even tough the date is not entered.

Really appreciate the same if anyone has come across such requirement.

Thanks

Ankit Jain

Accepted Solutions (1)

Accepted Solutions (1)

RicardoRomero_1
Active Contributor
0 Kudos

Hi,

For display the field as mandatory you can add a new entry in the following path in SPRO:

SAP Supplier Relationship Management --> SRM Server --> Cross-Application Basic Settings --> Extensions and Field Control (Personalization) --> Configure Field Control --> Configure Control for Fields on Header Level --> Metadata for Fields on Document Headers

Add a new entry with:

Field: OPEN_TIME_DATE

Bus: BUS2200

And check the checkboxes; Visible, Enabled and Requiered.

But, with this you only display the field as mandatory. For add a message of error you need to implement the badi BBP_DOC_CHECK_BADI for the filter BUS2200.

Regards,

Ricardo

Former Member
0 Kudos

This I have alrready tried but the at the time of publish it doesnot give me error if not enter the Opening Date .

Thanks,

Ankit

RicardoRomero_1
Active Contributor
0 Kudos

In my system works fine, I've added the following code in badi BBP_DOC_CHECK_BADI and I can't publish my RFX without filling that field...

DATA: ls_bid_header TYPE bbp_pds_bid_header_d,
        ls_messages TYPE LINE OF bbp_tmessages_badi.
  IF flt_val EQ 'BUS2200'.
    CALL FUNCTION 'BBP_PD_BID_GETDETAIL'
      EXPORTING
        i_guid   = iv_doc_guid
      IMPORTING
        e_header = ls_bid_header.
    IF ls_bid_header-open_time IS INITIAL.
      CLEAR ls_messages.
      ls_messages-msgty = 'E'.
      ls_messages-msgid = 'ZYOUR_MESSAGE_CLASS'.
      ls_messages-msgno = 000.
      APPEND ls_messages TO et_messages.
    ENDIF.
  ENDIF.

Former Member
0 Kudos

Thanks for the updates

Yeah I agree this wont allow to publish the RFx . BAPI will written the data which is saved in the database . And here when we will give error this will stop us to publish the RFx.

But the thing is if User has enter the data at run time and we could read this data MODIFYVIEW at this point when we read data we wont get current data in the BADI. So we wont be able to track the same.

We will give error message in a MODIFYVIEW this will allow us publish just try publishing from some other TAB except the header tab . Want functionality same as SUBMISSION DEADLINE just above this field.

Thanks & Regards,

Ankit

RicardoRomero_1
Active Contributor
0 Kudos

I think BAPI retrieve the data from buffer (that means runtime data) if you call the function module with the guid. If you use the object_id I think retrieve the data from data base. If you use it within these BADIs...

In my system if I change some data i got the runtime data in my "check badi"...

try and tell us.

Former Member
0 Kudos

Really Great this has solved my issues. Its gets the data from buffer you are right.

Thanks

ankit

Answers (1)

Answers (1)

Former Member
0 Kudos

Hello,

Please let me know coding that you have done in MODIFYVEW.

Or try to use below one.

data: lr_input_field type ref to cl_wd_input_field.

lr_input_field ?= view->get_element( 'OPEN_TIME_DATE' ).

lr_input_field->set_state( cl_wd_input_field=>e_state-required ).

endif.

Thanks,

Neelima

Former Member
0 Kudos

Hi,

CALL METHOD LO_EL_RFQ_PARAMETERS->SET_ATTRIBUTE_PROPERTY

EXPORTING

ATTRIBUTE_NAME = 'OPEN_TIME_DATE'

PROPERTY = LO_EL_RFQ_PARAMETERS->e_property-required

VALUE = ABAP_TRUE.

I have used this.But is doesnt work when I click on publish .

Thanks,

Ankit

Former Member
0 Kudos

Hello,

Which SRM version your using.

Your enchance the webdynpro comeponent right.

I coding this logic in Modify view post exit?

Regards,

neelima

Former Member
0 Kudos

I am using SRM7.0 version .

Thanks

Ankit