cancel
Showing results for 
Search instead for 
Did you mean: 

Adding custom fields in Work Manager 6.1

LeonardoGomez
Advisor
Advisor
0 Kudos

Dear all,

I extended the Work Manager application to bring a cutom field at the operation level. For this I created the class ZWorkorderOperation that extends from WorkorderOperation. Then I created an implementation in the Badi on ECC to populate the custom field. At last, I changed the parameter on the config panel to point to my new class and added the custom field in Agentry. This works fine. The code of my new class is:

The issue I'm facing is when I want to update the value from Work Manager in ECC. I created new classes for the steplet, the stephandler and the BAPI class, and changed the config panel parameters accordingly.

I can see through debugging that the _wo object in the BAPI class has the operations collection of type ZWorkorderOperation, but it doesn't bring the value of my custom field. I don't know how to bring that value to populate the parameter of the BAPI.

Can anyone help me understand what I'm doing wrong?

Thank you!!

Leonardo.

Accepted Solutions (1)

Accepted Solutions (1)

jason_latko
Advisor
Advisor
0 Kudos

Leonardo,

I see your change in the new Operation class to handle fetching the value down to the client, but have you also added code in that POJO to set the custom field from the transaction property being passed up from the client?  Each Operation in _wo.Operations should have had a setProperties call that populates your custom field from "Transaction.workorder.x.operation.x.customfield".

Jason Latko - Senior Product Developer at SAP

Answers (3)

Answers (3)

LeonardoGomez
Advisor
Advisor
0 Kudos

As Jason suggested, I implemented method setProperties(user, bapi, i) and could make the fields get the value from the transaction.

Thanks to all!

Leonardo.


Former Member
0 Kudos

As Jason said , did you add your field in POJO class . can you debug end to end via external java debuger . Thanks & Regards, Kunal Varaiya

Former Member
0 Kudos

Have you also made the necessary enhancements on the Agentry frontend side, to make sure your fields are being transmitted as part of the transaction? I'd suggest debugging or adding a set of logging calls to your Java code to verify the transaction steps.