on 08-02-2006 8:25 AM
Hi,
we are working with SRM 2.0 classic scenario. I have following problem:
We take over lead time from a supplier catalog via OCI in EBP. This works but the lead time does not consider holidays and weekends. How can I activate the Factory Calender?
Thanks Thomas
Hello,
did you activate factory calendar in general settings?
Look at note 814100 The delivery date lies outside of the factory calendar. It may also help you.
HTH
Gordan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Gordon,
thank you for your help! Actualy I don't have any warnings or errors in EBP when I select a delivery date that is no working day. I just know the customizing point "maintain calender". I don't know where to assign or activate the factory calender, as I don't have plants or work centers in EBP like in R/3...
Regards Thomas
Hello,
I just sniff arround and found out that EBP 3.0 does not support factory calendar.
You should use BBP_DOC_CHECK_BADI or BADI BBP_CATALOG_TRANSFER and call within this BADI the function modules requesting the factory calendar data via RFC on the backend.
i.e.
get the target system of the follow-on document
SELECT log_sys from BBP_DET_LOGSYS INTO wa_logsys-log_sys
WHERE CATEGORY = ls_item-category.
ENDSELECT.
read table T001WK
CALL FUNCTION 'META_READ_TABLE'
EXPORTING
query_table = 'T001W'
logical_system = wa_logsys-log_sys
TABLES
options = options
fields = fields
data = tabcont
EXCEPTIONS
OTHERS = 1.
fill the internal table xt001w
LOOP AT tabcont INTO la_tabcont.
MOVE la_tabcont-content+3(4) TO la_xt001w-werks.
MOVE la_tabcont-content+61(2) TO la_xt001w-fabkl.
APPEND la_xt001w TO xt001w.
ENDLOOP.
SORT xt001w BY werks.
get the fabric calendar related to the plant
READ TABLE xt001w INTO ma_XT001W
with KEY werks = ls_item-BE_PLANT.
check if delivery date is a working day
CALL FUNCTION 'DATE_CONVERT_TO_FACTORYDATE'
DESTINATION wa_logsys-log_sys
EXPORTING
DATE = ls_item-DELIV_DATE
FACTORY_CALENDAR_ID = ma_XT001W-fabkl
IMPORTING
WORKINGDAY_INDICATOR = W_IND.
get an error message if delivery date is not a working date
IF W_IND = '+'.
CLEAR ls_message.
ls_message-msgty = 'E'.
ls_message-msgid = 'ZBBP'.
ls_message-msgno = 'xxx'.
ls_message-msgv1 = 'error message text, e.g. delivery date not
working date'.
ls_message-item_guid = ls_item-guid. "assign message to item
APPEND ls_message TO et_messages.
ENDIF.
endloop.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.