How to get work item details programatically ?
Hi All,
I have a list of work items (process instances) and I want to retrieve each item details such as: attachments, notes, id, ...
All the items are filtered and represented as Fuego.Papi.Instance:
Fuego.Papi.Instance[] inst = busProcess.getInstancesByFilter(filter : instFilter);
But the work item details are inherited from Fuego.Lib.ProcessInstance. So, how to get the item details from inst[] ?
Would appreciate any help, may be Dan will have an advise ?
Regards,
Kim
If you have instances returned by your filter, you could extract variable information for each instance by doing something like this:
for each inst in getInstancesByFilter(ps, filter : instF) do
// here's how to get the value inside a primitive instance variable
orderAmtObj as Object = getVar(inst, var : "orderAmount")
// here's how to get the value of attributes inside a complex BPM Object instance variable
// - in this case this is an "order" object with two attributes (customerName and amount)
orderObj as Object = (getVar(inst, var : "order"))
xmlObject = Fuego.Xml.XMLObject(createXmlTextFor(DynamicXml, object : orderObj, topLevelTag : "xsi"))
logMessage "The value of the order object's customer name is: " +
selectString(xmlObject, xpath : "customerName")
logMessage "The value of the order object's order amount is: " +
selectNumber(xmlObject, xpath : "amount")
// here's a rather uninspired way to retrieve who the participant is that was assigned the instance
logMessage "The participant assigned to this instance is: " + inst.participantId
endInside the above "for" loop, you could retrieve these predefined variables (this example assumes you use "inst" in your "for" loop):
objRet as Any
objRet = inst.getVar(var : "PREDEFINE_ACTIVITY")
logMessage "Activity name = " + objRet using severity = DEBUGSubstitute "PREDEFINE_ACTIVITY" in the above logic to get this information:
PREDEFINE_PRIORITY (priority)
PREDEFINE_ACTIVITY_DEADLINE (activity.deadline)
PREDEFINE_CREATION_TIME (creation.time)
PREDEFINE_PROCESS_DEADLINE (deadline)
PREDEFINE_DESCRIPTION (description)
PREDEFINE_PROCESS (process)
PREDEFINE_RECEIVED_TIME (receptionTime)
PREDEFINE_PARTICIPANT (participant)
PREDEFINE_COPY (id.copy)
PREDEFINE_STATUS (status)
Similarly, you might want to try to get instance information using the Fuego.Papi.VarDefinition object a try. Never used it, but the logic might be as simple as:
logMessage "who created? = " + inst.getVar(Fuego.Papi.VarDefinition.CREATOR_ID) using severity = DEBUG
logMessage "does it have attachments? = " + inst.getVar(Fuego.Papi.VarDefinition.HAS_ATTACHMENTS) using severity = DEBUG
logMessage "does it have notes? = " + inst.getVar(Fuego.Papi.VarDefinition.hasnotes) using severity = DEBUGDan
Similar Messages
-
In GP how to get work items in outlook inbox
Hi,
Any one can explain me how to send work items to Outlook Mail. This option is there in ABAP work flow. I need solution in GP.
Please give any sloution.
Thanks,
SunilHi Jonathon,
in our last project, we faced the same problem and resolved it with a standard notification CO:
- we put a notification CO (+ action) in front of the action you mentioned (that one that generates the UWL's workitem and provides the CO for manual processing)
- the notification's addressee will be the current processor, who is also the guy to do the manual processing
- the notification email contains a link to the process' current workitem, which is the action you mentioned (e.g. a webdynpro form or whatever the manual processing is)
The result is, that there will be an automatically sent notification, followed by the normal manual processing. And our client was happy to be able to customize every single email.
See this link for email administration: http://help.sap.com/saphelp_nw04s/helpdata/en/43/f9097d1b607061e10000000a1553f6/frameset.htm
Best regards
Daniel -
Hi,
my requirement is to call webdyn pro screen from workflow..
i am calling webdynpro screen by using FM :CALL_BROWSER from workflow.
when webdyn pro screen is called user will enter some values . if user closed webdyn pro screen with out entering any values we need show this workitem in his inbox. so that user can again open it and enter values in the webdyn pro screen.
Please help how to stop work item complete based on conditions.
Thanks,
phaniHi,
As per my understanding, this is not a proper approach toy call web dynpro using FM CALL_BROWSER. is the web dynpro screen being called when user clicks on the work item from portal UWL OR from SAP SBWP ?
if you are calling web dynpro screen from portal UWL when user clicks on work item link, better you achieve it using SWFVISU tcode. in SWFVISU tcode you can maintain which web dynpro. application to call when particualr work item task come in user's inbox. in your web dynpro code, then you can write your buisiness logic when user clicks for example SUBMIT/SAVE button. on action submit/save button you can use FM SAP_WAPI_WORKITEM_COMPLETE to complete the worktiem once the user clicks on final submit/save button. in this way the workitem will get removed from user inbox only upon clicking on submit/save button.
You can refer below link for web dynpro for workitem:
http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/70648e99-4cc1-2c10-879d-9c61003c69d6?QuickLink=index&… -
FI drilldown reports- cant get Line item details in dynamic selection
Hi,
In FI drill down reports line item analysis, i create form in FDI4.I get document currency as a key figure.
While executing a report in tcode FDI0. i gave company code,dealer and currency as 'EUR' in dynamic selection,.
the correct output value '1245678.98' also displaying ,but i am not able to get line item details for the value '1245678.98'.
the path to get line items is Extras-->Line items.
it shows message as 'The value for characteristic Currency is not unique. Reposition the cursor'.
how to display line item details.
plz help.Hi,
You can get this functionality with Virtual Key figures.
You will have the complete dataset in the RSR00002 Enhancement in CMOD.
Thank you
Arun -
Hi Experts,
This is Chakri. How to run work item Manually ? I don't no exactly workflow.Basically i am working on EP.
Regards,
ChakriHi Chakri,
If you are after running a workitem manually then just go to txn swia give that workitem number and execute from there.
or
you can go technical details of it and complete manually.
steps:
go to technical details
click on the workitem (line)
goto menu - technical details
change menu
complete manually.
Cheers
VJ -
How to get Work schedule repor of employees
Hi all
Can any one help me out in
how to get work schedule report of employees who are works in different shifts in an organization.
Thnks in Advance
AnushaHi Anush,
Find the SAP Standard reports for Work schedules:
- PT03 - Display Work Schedule
- PT63 - Personal Work Schedule (even PT61 also helpful as biswajit said)
- PT_DSH20 - Daily Work Schedule
Otherwise you have Time Managers Workplace/ Ad Hoc Query reports to view detail reports, which are user friendly for maintain time data.
TC for Time managers workplace is PTMW
TC for Ad-hoc query is S_PH0_48000513
I suggest you to go with Ad-hoc and select all fields that what ever output you want and view the results (even you can upload also)
Cheers,
TG
Message was edited by: TG -
How to get the network details in flex4.5 web application
How to get the network details in flex 4.5 web application
similar to the nativeinterface in air applicationcheckout this document for secure web application
http://help.adobe.com/en_US/flex/using/WS2db454920e96a9e51e63e3d11c0bf6167e-7fff.html -
How to get work JavaFX WebViewBrowser sample in debian linux wheezy?
How to get work JavaFX WebViewBrowser sample in debian linux wheezy
You may also check latest version of this problem here...
The Starting point I have
Debian wheezy
java version "1.7.0_40"
Java(TM) SE Runtime Environment (build 1.7.0_40-b43)
Java HotSpot(TM) Client VM (build 24.0-b56, mixed mode)
GTK version: 2.24
NetBeans 7.3.1
Certified configuration acording to JavaFX Supported Configurations
is
Ubuntu 10.4 +
gtk2 2.18+
GTK is OK. do I require ubuntu?
first try: by downloading Java SE Downloads - javafx sample
Let's try it
zolta@zolta:~/dolgaim/IT/NetBeansProjects/javafx/javafx-samples-2.2.40$ java -jar SwingInterop.jar
# A fatal error has been detected by the Java Runtime Environment:
# SIGILL (0x4) at pc=0x9b6b4c22, pid=21172, tid=2658700144
# JRE version: Java(TM) SE Runtime Environment (7.0_40-b43) (build 1.7.0_40-b43)
# Java VM: Java HotSpot(TM) Client VM (24.0-b56 mixed mode linux-x86 )
# Problematic frame:
# C 0x9b6b4c22
# Core dump written. Default location: /home/zolta/dolgaim/IT/NetBeansProjects/javafx/javafx-samples-2.2.40/core or core.21172
# An error report file with more information is saved as:
# /tmp/hs_err_pid21172.log
# If you would like to submit a bug report, please visit:
# http://bugreport.sun.com/bugreport/crash.jsp
# The crash happened outside the Java Virtual Machine in native code.
# See problematic frame for where to report the bug.
Terminated
Let's see what core dump says
to be continued...Gusar wrote:
We need *a lot* more info than that. Could be something very simple, like the interface being up before starting wifi-menu (netctl doesn't like the interface being up, it'll only start correctly if the interface is down).
Or it could be something more. In which case, you'll need to start wpa_supplicant manually with debugging enabled:
wpa_supplicant -i wlp18s0b1 -c <(wpa_passphrase MYSSID passphrase) -d
Once this says you're connected, open another terminal and start dhcpcd. Or, if wpa_supplicant doesn't manage to connect, post the *entire* output.
Edit: Ok, you posted more info as I was writing my post. Will look through that, maybe it contains something useful. If not, follow the instructions above.
Edit2: Nope, nothing about wireless in there, except that the driver loaded.
It worked!!
I was looking into the logs and found an authentication failure...my password is very long so I made some mistakes while typing it.
So this is the solution all the way:
SOLUTION:
- No need to install or load any external drivers (all I used was already in the base installation)
- DISABLE THE HIDDEN NETWORK OPTION IN THE ROUTER (thanks for the heads-up @Gusar)
- run "# wifi-menu"
or
"# wpa_supplicant -i [interface] -c <(wpa_passphrase MYSSID passphrase) -d"
- run "# dhcpcd [interface]"
- Good to go!!
I'm sorry for the trouble guys, and like I imagined, it was really easy and now I see my newbiness hahaha ;D
Thanks. -
How to get line item net price and net value?
I have using "BAPI_SALESORDER_SIMULATE" to SIMULATE to create SO,
the return table
ORDER_ITEMS_OUT-NET_VALUE is not equals than created by VA01 .
how to get line item net price and net value?Hi,
Can u elaborate ur query ?
By this FM you cannot create a SO . Use FM --> BAPI_SALESORDER_CREATEFROMDAT2
Regards,
MAdhukar Shetty -
How to get List Item attachments name without write any custom code or any database query?
Hi,
How to get List Items attachments name without write any custom code or any database query?You can get it from Rest,
There are 2 options,
1) create a 'Result Source' which has a search query for that List which has attachments
- Use rest query to get the 'Filename' , it will have the attachment file name
For example, if the result source id is : 73e6b573-abf8-4407-9e5f-8a85a4a95159 , then the query will be
http://[site URL]/_api/search/query?querytext='*'&selectproperties='Title,Path,FileExtension,SecondaryFileExtension,Filename'&sourceid='73e6b573-abf8-4407-9e5f-8a85a4a95159'&startrow=0&rowLimit=100
You can refine the query, be giving proper 'querytext'
2) Use the List rest api
For example if your list guid is :38d524a1-e95c-439f-befd-9ede6ecd242e
You can get he attachments for 1st item using this
http://[Site URL]/_api/lists(guid'38d524a1-e95c-439f-befd-9ede6ecd242e')/items(1)/AttachmentFiles
get2pallav
Please click "Propose As Answer" if this post solves your problem or "Vote As Helpful" if this post has been useful to you. -
How to get the input details on the output screen in T code KCR0
Hi All,
How to get the input details on the output screen in T code KCR0, the issue is that we need to get the input details like Company code and payment date on the output screen while executing the report painter via t code KCR0.
I tried to chane the settings via t code KCR6 but still didn't get the required output details.
Regards,
AjayThis is the asset accounting forum. You should post your question in the proper forum.
-
How to get page item list in a page?
how to get page item list in a page?
Have a look at ISpread::GetItemsOnPage().
That should get you started. -
Can any one please tell me how to send work item ? will it be through the use of user decision or through the activity task? moreover where to provide the description and the subject of the work item?
What do you mean by "send the work item"?
If you mean "send information to a user that there is a work item waiting to be executed", read the FAQ and/or search this forum for RSWUWFML2.
If you mean "send the work item to the correct recipient", your best choice is to learn how to use rules and set possible agents. Read the FAQ and/or search the forum or SAP documentation at <a href="help.sap.com">help.sap.com</a>.
If you mean something else, then please try again to explain what you are trying to do. -
How to get GL transactions detail
How to get GL transactions detail to insert in 3rd party applicaton.? We need Journal Entry number, date, account number, debit and credit columns. We need detail table structure.
Thanks
ShafiqHi
About period balance.
To have the amount of the balance of a certain account you need to run the following query (you need to know the CODE_COMBINATION_ID of the account, the SET_OF_BOOKS_ID of the company, the PERIOD_NAME and the functional currency used)
select nvl(sum(bal.begin_balance_dr + bal_period_net_dr - bal.begin_balance_cr - bal.period_net_cr),0)
from gl_balances bal,
gl_code_combinations cc
where cc.code_combination_id = bal.code_combination_id
and bal.actual_flag = 'A'
and cc.code_combination_id = <your ccid>
and bal.period_name = <your period name>
and bal.currency_code = <your func currency>
and bal.set_of_books_id = <your sob id)
Hope this helps.
Octavio. -
Does anyone know how to get my Mailbox details from ICloud Back-up?
I deleted some emails in error and need them back.ThanksThe iCloud backup doesn't contain email. If you deleted the email and it isn't in your trash folder, there is no way to recover it.
Maybe you are looking for
-
I am trying to figure out how to get to a BC4J application from a TAB on my portal corporate page. This is just a test. My experience thus far with the UI of PORTAL is the it LEAVES MUCH TO BE DESIRED! It feels like something from the 1970's. Anyway,
-
The N9 Navigation is very limited. I did find the following limitations; 1. There is no Favourite Tab/option 2. There is no Save location option. 3. There is no Fastest/Smallest Route option. 4. Once you select a destination, the Navigation Mode keep
-
Install Failed on OSX 10.5.5
I got a PS Elements 6.0 for MAC at the apple store a few months back.<br />The wife's new mac came in on Friday, so I finally opened up the PS-Elements 6 last night and tried to install it - and I got this:<br /><br />Summary<br />Successfully instal
-
Photoshop could not be initialised due to a program error
Today i became member of the creative cloud with Photoshop and Lightroom. After installation Lightroom works allright, but after starting up Photoshop i get the message that Photoshop could not be initialised due to an program error. I run the CC cle
-
Cannot display complete document in binary XML XMLType column
I've been trying to get a query to work that will display the complete XML document stored in a column of XMLType, binary XML storage. <b/> I"m using Toad 10.6.1.3. <b/> I'm running Oracle client: {code}Oracle Database 11g Enterprise Edition Release