cancel
Showing results for 
Search instead for 
Did you mean: 

SAP Work Manager 6.2 Agentry class extension

Former Member
0 Kudos

Hi;

Environment: SMP 3.0 SP09

I am working on SAP Work Manager 6.2, specifically the Notifications portion, I am working on bringing/fetching in 2 additional fields from the backend.

I came across the below post and have tried implementing this with no success :

http://scn.sap.com/thread/3622119

Does the solution provided on this post apply as well for WM6.2, I have tried this solution with no success. So, does this mean that for WM6.2, when fetching new additional fields you have to extend the object, bapi, stephandler and steplet class? In my implementation, when I debug, it only breaks within the Notification extension class default constructor and then that's it, all the other methods that I am overriding do not seem to be getting called. Am I perhaps missing something here?

Thanks and Regards;

Sizo Ndlovu

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi;

Extending only the object class does not seem to do it. What I have done is, I have extended the steplet, stephandler, bapi and object class. I have gone on to change the Agentry fetch steplet class to my custom one. I can see the 2 custom fields on the device now.

Thanks and Regards;

Sizo

Former Member
0 Kudos

Interesting.

can you please confirm here once in standard stephandler class what is the return type?

like

or

My assumption is your stephandler class will be like the 2nd screen shot. If its true than if you enhance only the array type  with your custom class it will work. in that case you no need to enhance all the classes.

Thanks

Ajitesh

Former Member
0 Kudos

Ajitesh;

Please see below code :

Looks like its the first one?

Thanks and Regards;

Sizo Ndlovu

Former Member
0 Kudos

Hey i am trying to extend the classes. Can you advice me on this;

http://scn.sap.com/thread/3832640

Answers (2)

Answers (2)

mark_pe
Active Contributor
0 Kudos

Sizolwenkosi,

Hi. We will try to ask SAP consultants to see if they can assist here based on their experience.

Best Regards,

SAP Mobile Support Team

Former Member
0 Kudos

Sizo,

In WM 6.2 it is not required to enhance your steplet, stephandler, bapi class for fetching two field from SAP.

what you have to do is just extend Notification object class and import all the super class constructors.

Than override setProperties and set your custom property.

Make sure that NotificationFetchBAPI is returning those fields.

In configpanel you have to set Standard Notification object = your custom Notification class(Fully qualified name).

Make sure you are not using LAM concept. If you are using LAM than your custom class will be extend from LAM Notification class.

Hope this helps you.

Ajitesh

Former Member
0 Kudos

Hi Ajitesh;

Thank you for the response. This is for the SAP Work Manager 6.2 with the Customer Service 2.1 component as a base, so does this then imply that I have to extend CSNotification instead of Notification?


Thanks and Regards;


Sizo

Former Member
0 Kudos

You can directly extend to Notification.

Ajitesh

Former Member
0 Kudos

Hi Ajitesh;

Please see below, am I missing something here:

And my Java implementation:

I have debugged the ABAP side, and the /SMERP/CL_CS_NOTIFICATION_DO class does export these two values. Any pointers perhaps?

Thanks and Regards;

Sizo Ndlovu

Former Member
0 Kudos

Sizo,

Is your custom class getting called?

Can you also remove all the parameter defined in ZNotification constructor. Just call super method.


Ajitesh

Former Member
0 Kudos

Also have you deployed your java code in to SMP server and did you pass the custom java class path in management cockpit?

Can you please check and confirm this?

Ajitesh

Former Member
0 Kudos

Hi Ajitesh;

Removed the parameters and am now calling super:

Yes, my ZNotification class does get called but the debug only runs into the default constructor and that's its, doesn't break anywhere else.

The custom jar file is sitting together with the other jar files in the Java folder (SMP deployment)

And I also have this in the cockpit classpath.

Thanks and Regards;

Sizo Ndlovu

Former Member
0 Kudos

In that case can you please keep break point in NotificationFetchBAPI/ CSNotificationFetchBAPI's processResults() method to check which setProperties getting called? standard Notification or CSNotification class.

Former Member
0 Kudos

Hi Ajitesh;

I've tried both extending Notification or CSNotification, as for extending CSNotification, the debugger runs into the following constructor and that's it, doesn't run through any other code:

Any other suggestions perhaps?

Thanks and Regards;

Sizo Ndlovu

Former Member
0 Kudos

Sizo,

Did you put break point in NotificationFetchBAPI/ CSNotificationFetchBAPI's processResults() method to check which setProperties() getting called? standard Notification or CSNotification?

This will give us a clue.

Can you please check this once.

Ajitesh

Former Member
0 Kudos

Unfortunatley, I do not have the source code, so that might be a tough one.

Former Member
0 Kudos

you should request to SAP for java source code.

Temporary please use java decompiler plugin in your eclipse and try to debug the code.

Please install below plugin links to your eclipse and restart the eclipse.

Mchr3k Eclipse Update Site

Ajitesh