cancel
Showing results for 
Search instead for 
Did you mean: 

Automatically set TU to Active when it is created

0 Kudos

Friends,

Our users would like to have TUs go to Activated automatically when they are created in EWM.  I have looked in SPRO (Configuration) but I do not see any way to set that to happen.  I have looked at several BADis and Methods and I believe I can add some code in class "/SCWM/CL_SR_BOM" Method "SAVE_TU", but it could not be an Enhancement because I would want to change the values in  lt_tu_new and  lt_act_new tables before the TU is created.  I would like to find out if anyone knows a better way before I make this change to the SAP code.  Thank you!

Kevin

Accepted Solutions (1)

Accepted Solutions (1)

former_member183610
Active Contributor
0 Kudos

Hi Kevin,

I guess, it can be possible through PPF actions by creating new PPF action to activate the TU,once it is created.

it would required to create a new action under the action profile '/SCWM/TU'.

check the classic BADIs ' EXEC_METHODCALL_PPF' and 'EVAL_SCHEDCOND_PPF'.

against the new action definition ,maintain the processing time as immediately.

BR,

C K Reddy

0 Kudos

Jobi and CK,

The use of PPF sounds good and I am looking into doing that and will let you know.  Thank you!

Kevin

This took a while as I had not used PPF before and I had other things going.  I was able to use PPF and finally got it to work when I changed a TU, but then the create TU began failing.  I had to change it from Immediate Processing to Processing when saving document and it now is working fine.  I believe that it was trying to change a database table record before the record was there from the complete and by changing to when saving it had the records in the tables to change and is happy. 

  Thank you very much!

Kevin

HST
Explorer
0 Kudos

Hi Kevin, I'm currently struggling with the same topic. Can you provide more a short guidance what you have done in that scenario. regards Stephan

Answers (2)

Answers (2)

0 Kudos

Hi!

PPF - is good solution. Also you can try to use badi /SCWM/EX_SR_SAVE, method AFTER_SAVE

BR, Alex.

jobi_t
Contributor
0 Kudos

Hi Kevin

Keep a PPF at TU and execute the PPF to activate the TU.

You can control the TU status from Planned to Active in the  program.

Cheers

Jobi