on 01-29-2015 12:43 PM
Hello Experts,
There is no WorkCenter field in Notification edit. WorkCenter exists in transaction and object property, so i easily added WorkCenter to NotificationEdit Screen , but it does not replicate when i deploy and run on client.
Please suggest where i am doing wrong.
Regards
Manish
Hello Manish,
Does it means that standard code does not support Work center update for notification.
Can you tell me what changes we need to do in SAP side also to get the work center update.
Thanks,
Madhur
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Manish,
Ensure from client - you could use Agentry Test Evironment - where you are getting work center from the client.
Debug java eg: Notification.java where you are setting the work center that you are getting from the transaction.
From WM6.2 - Notification Post current transaction calls Notification Post steplet - where you could put break point from execute() - you could navigate the dubug and identify the problem. Hope this helps.
Thanks
Resmi
Hello Resmi,
Quick question is work center update not a standard out of box solution provided by SAP.
When we transfer work order using work center . We need to transfer notification and update work center field over there.
My assignment both work order and for notification is at header work center level.
Looking forward to hear from you soon.
Thanks,
Madhur kanungo
Madhur,
Please create a Discussion marked as a Question. Not only so others may benefit from your solution once it is found, but also because you will have more folks looking to provide a solution when your issue has the greater visibility of a Discussion. Also suggest that you visit the Getting Started link at the top right of each SCN page for help with creating a good Discussion.
--Bill
I am not posting entry while editing, i am posting while creating an notification.
But not able to get the planner group value, it is going as blank.
Not able to get the hit this method.
public void setProperties(User u, ZNotificationPostBAPI bapi)
throws Exception
{
super.setProperties(u, bapi);
setPlannerGroup(u.getString("transaction.notification.PlannerGroup"));
setPlanningPlant(u.getString("transaction.notifcation.PlanningPlant"));
setWorkCenter(u.getString("transaction.notification.WorkCenter"));
}
any idea how to call this method.
Thanks,
Madhur
Hello
Work Center update is not working don't know where i am going wrong.
Regards
Manish
Manish,
You need to analyze where the issue exists
1) Put a break point in custom JAVA code and check whether controls stops in your code. if control doesn't stop then your most likely your JAVA code is not called at the runtime.. Couple of things to check a) It is mostly related to parameters definition in config. panel. - check if all relevant parameters are changed point to Z class. Cross check against any standard parameter. b) Make sure that if SMP server is restarted after parameter change
2) if you see Work center value populated in JAVA layer then put a break point on SAP side..to check if work center value is received, Basically you have to debug and check what happens with WC value passed from Agentry client.
Hope it my answers help you to narrow down issue.
Thanks
Manju.
I have tested backend by passing value in debugger to check if work center updates or not, it works fine.
We are facing problem from Agentry itself, value is not passing from agentry.
Work center field is already there in object properties and transaction.
We have extended following BAPI
1. NotificationEditBAPI
2. NotificationPostBAPI
Steps we followed
1. Extended mentioned above classes.
2. Extended steplet and step handler for both the above classes.
3. Maintained java class for steplet in agentry steps
4. Changed config for both above classes in syclo config panel
Do we need to write steplet and steplet handler , as in forum it was said not to use step and stephandler for SAP WM 6.2 version.
Please suggesr
Regards
Manish
Manish,
if work center value is not passed from Agentry side then there is no point in debugging on SAP side.
Couple of things are not clear to me - Under steps we followed section you said you have extended step let and step handler but towards the end your asking
whether to extend steplet and stephanlder.
is your issue :-
1) is work Center value not passed from Agentry to JAVA ? or
2) Is custom java code not invoked at the runtime ?
for case 1) use ATE to debugging why Work Center value is getting cleared ? Debug Notification Add/Edit transaction and check it out ? Check any rules or transmit action which I believe creates transaction on the fly.
case 2) extend steplet and step handler check what happens ? Just follow standard product way of doing things.
Unfortunately there is no easy answer to your issue. Debug is the only option to analyze your issue.
check this thread http://scn.sap.com/thread/3511278 ,http://scn.sap.com/thread/3542583
Thanks
Manju.
Hello Experts,
It was screen platform issue. Now i can see the work center, when i populate and transmit it does not replicate in SAP. What changes i need to do in java side. I am using NotificationEdit transaction.
Regards
Manish
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Manish,
The Notification Edit is a two step transaction process. You will need to look at the NotificationPostCurrent action which is responsible for sending the change to the backend. This in turn will call the NotificationPostSteplet which will call the NotificationPostStepHandler which you will probably need to be extended to set the WorkCenter in the backend.
--Bill
Can you check this code, what is wrong here. I am not getting debugger on setHeaderParameter.
package com.syclo.sap.component.notification.custom.bapi;
import java.util.ArrayList;
import com.syclo.sap.*;
import com.syclo.sap.component.notification.bapi.NotificationPostBAPI;
import com.syclo.sap.jco.JCO;
public class ZnotificationPostBAPI extends NotificationPostBAPI{
public ZnotificationPostBAPI(User u) throws Exception {
super(u);
}
@Override
protected void setHeaderParameters(Logger log) throws Exception{
if (_bapiType.equals("CREATE")) {
if (_notification.getIsLocal()) {
JCO.Structure header = _imports.getStructure("IS_NOTIF_HEADER");
setValue(header, log, "PM_WKCTR", _notification.getWorkCenter());
}
}
else if (_bapiType.equals("UPDATE")) {
JCO.Structure header = _imports.getStructure("IS_NOTIF_HEADER");
JCO.Structure xStruct = _imports.getStructure("IS_NOTIF_HEADER_X");
setEditValue(header, xStruct, log, "PM_WKCTR", _notification.getWorkCenter());
}
}
}
Regards
Manish
If the debugger is not stopping then the problem is not related to the code.
Set a breakpoint to the execute() method in the standard steplet class called when a Notification is created/edited in Agentry. In WM 6.1 this is the class: com.syclo.sap.component.notification.steplet.NotificationPostSteplet
Then you can debug all the process. In the step handler class you will see if your custom class is retrieved from the configuration portal, which probably is the cause of your problem
Dear Manish,
I have written similar code to update Planner group field in SAP. But getting this error in POJO class.
Are you aware on how to resolve it.
Please find my BAPI and POJO code.
POJO Class:-
POJO class has error on line number 50; The type com.syclo.agentry.User cannot be resolved. It is indirectly referenced from required .class files.
But i have added all libaries and references, still i am getting that error.
BAPI CLass for reference:.
It is giving me error in steplet class, JAVA class not found, I have configured the custom class properly in SAP config panel.
Any help would be much appreciated.
Thanks.
Madhur Kanungo
User | Count |
---|---|
84 | |
25 | |
12 | |
9 | |
6 | |
6 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.