cancel
Showing results for 
Search instead for 
Did you mean: 

Modifying UWL Tasks view

Former Member
0 Kudos

Dear experts-

I tryign to customize the action for reject button on the UWL tasks.

As of now, in UWL tasks tab the approver sees approve and reject button.

The requirement is the tasks can not be rejected without comments. There is no editor where he can put his tasks.

Can any one suggest me how to insert the text ediot and defien action on reject to mandate the comments.

Thanks,

John.

Accepted Solutions (1)

Accepted Solutions (1)

former_member201257
Active Contributor
0 Kudos

See slides 16 and 17 of this presentation:

http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/a002d1eb-33f0-2b10-f391-e1e0c3057...

Get the correct values for the decisionKey by running function module SAP_WAPI_DECISION_READ against any work item based on the relevant workflow task.

If you use, <Property name="UserDecisionNote" value="mandatory"/> then a reason will become mandatory for that action.

Thanks,

Shanti

Former Member
0 Kudos

Hi Shanti-

I created a XML file and uploaded it with high priority in UWL configuration. But I dont see any difference prior to uploading and post upload of configuration. Can you please let me know if I have to change anything,

Below is the xml I am using

<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE UWLConfiguration PUBLIC '-//SAP//UWL1.0//EN' 'uwl_configuration.dtd'
  >
<UWLConfiguration version="1.0">
  <ItemTypes>

    <ItemType name="uwl.task.webflow.TS80000003.SAP_ECC" connector="WebFlowConnector" 
	defaultView="com.sap.pct.erp.mss.tra.view.TripApprovalView" 
	defaultAction="com.sap.pct.erp.mss.tra.action.DisplayExpenseForm" 
	executionMode="default">
<ItemTypeCriteria systemId="SAP_ECC" externalType=" TS80000003"  
     connector="WebFlowConnector"/>
      <CustomAttributes>
       		 <CustomAttributeSource id="WEBFLOW_CONTAINER" objectIdHolder="externalId"   
            objectType="WebflowContainer" cacheValidity="final">
       		    <Attribute name="TripNumber" type="string" displayName="Trip Number"/>
<Attribute name="EmployeeNumber" type="string" displayName="Employee Number"/>
         </CustomAttributeSource>
       </CustomAttributes>
      <Actions>
        <Action name="launchWebDynPro" handler="SAPWebDynproLauncher">
          <Properties>
            <Property name="WebDynproApplication" value="ShowWorkitemId"/>
            <Property name="WebDynproDeployableObject" value="local/UWLbook"/>
            <Property name="System" value="SAP_ECC"/>
          </Properties>
        </Action>
        
        <Action name="approved" groupAction="yes" handler="UserDecisionhandler">
          <Properties>
            <Property name="UserDecisionTitle" value="Enter a Rejection Reason"/>
            <Property name="decisionKey" value="1"/>
			</Properties> 
            <Descriptions default="Approved"/>
           
        </Action>
        
        
        <Action name="rejected" groupAction="yes" handler="UserDecisionhandler" returnToDetailViewAllowed="yes" launchInNewWindow="no">
          <Properties>
            <Property name="UserDecisionNote" value="Mandatory"/>
            <Property name="decisionKey" value="2"/>
         </Properties>   
            <Descriptions default="Approved"/>
           
        </Action>
            
        
        
      </Actions>
    </ItemType>

  </ItemTypes>
</UWLConfiguration>

Thanks,

John

former_member201257
Active Contributor
0 Kudos

1. Did you clear the UWL cache after uploading your new XML configuration file ?

2. Firstly, turn on the UWL support information from System Administration - System Configuration - Universal Worklist & Workflow - Universal Worklist - Administration.

Under Optional Universal Worklist Service Configuration - Open the Tray for the Optional UWL Service Configuration - Display support information to TRUE.

Now, when you are in the Universal Worklist view, you can see a whole lot of information below your tasks. This will give you information on which XML is getting picked up and which one needs to be modified.

Make sure that the new XML configuration you have uploaded is picked up.

3. Your XML doesn't look right. There are numerous problems that I see. Copy the XML from the standard delivered XML configuration file that came with your ESS and MSS BPs and include the additional attributes.

I am using Webdynpro ABAP applications for travel and the following configuration works fine for me. You can see it for your reference:

<ItemType name="uwl.task.webflow.decision.TS20000131.ESS_UWL" connector="WebFlowConnector" defaultView="com.sap.pct.erp.mss.tra.view.TripApprovalView" defaultAction="com.sap.pct.erp.mss.tra.action.DisplayExpenseForm" executionMode="default">
      <ItemTypeCriteria systemId="ESS_UWL" externalType="TS20000131" connector="WebFlowConnector"/>
      <CustomAttributes>
        <CustomAttributeSource id="WEBFLOW_CONTAINER" objectIdHolder="externalId" objectType="WebflowContainer" cacheValidity="final">
          <Attribute name="TripNumber" type="string" displayName="Trip Number"/>
          <Attribute name="EmployeeNumber" type="string" displayName="Employee Number"/>
        </CustomAttributeSource>
      </CustomAttributes>
      <Actions>
        <Action reference="viewMemos"/>
        <Action reference="addMemo"/>
        <Action reference="com.sap.pct.erp.mss.tra.action.DisplayExpenseForm"/>
        <Action name="com.sap.pct.erp.mss.tra.action.approver.ApproveTrip" groupAction="yes" handler="UserDecisionHandler" returnToDetailViewAllowed="no" launchInNewWindow="no">
          <Properties>
            <Property name="decisionKey" value="1"/>
          </Properties>
          <Descriptions default="Approve Trip"/>
        </Action>
        <Action name="com.sap.pct.erp.mss.tra.action.approver.SendBackTrip" groupAction="yes" handler="UserDecisionHandler" returnToDetailViewAllowed="no" launchInNewWindow="no">
          <Properties>
            <Property name="UserDecisionNote" value="mandatory"/>
            <Property name="decisionKey" value="2"/>
          </Properties>
          <Descriptions default="Send Trip Back for Corrections"/>
        </Action>
        <Action name="com.sap.pct.erp.mss.tra.action.approver.RejectTrip" groupAction="yes" handler="UserDecisionHandler" returnToDetailViewAllowed="no" launchInNewWindow="no">
          <Properties>
            <Property name="UserDecisionNote" value="mandatory"/>
            <Property name="decisionKey" value="3"/>
          </Properties>
          <Descriptions default="Reject Trip"/>
        </Action>
      </Actions>
    </ItemType>

Former Member
0 Kudos

Thanks for reply.

I set Display support information to be true.

I see the configuration which is picked up is.

Item Type Configuration Name: uwl.webflow.SAP_ECC_Travel ( it is not the one which I uploaded) I uploaded XML file with the content which I pasted earlier)

Do I have to make a copy of the xml file from that configuration i.e, uwl.webflow.SAP_ECC_Travel ?

It has lot of items in it. I am using ABAP webdynpro apps for travel too.

In case If I have to copy the whole file Where should I insert the code you suggested?

Regards,

John.

former_member201257
Active Contributor
0 Kudos

1. With your UWL support information turned ON, go to your UWL and select the item for you would like to customize.

You can see additional information below the UWL table now. Under "Current Item Information", see what's the External Item Type. For example, this would be some thing like TS20000131. This needs to be included in your XML configuration correctly.

2. Now, from UWL administration - look for the XML configuration file that says - com.sap.pct.erp.mss.tra - this should have come with your Business package.

Download this file and make a copy of it with your own custom name. Look for the item type definition of your item that has been identified in Step 1. Replace that item type definition with the configuration I posted above.

Please note that the item type might be different in your case.

Make sure to change the item types in your XML configuration correctly - including the tag - externalType="TS20000131"

3. Upload this new configuration file to UWL with high priority.

4. Clear the UWL cache - If you don't do this - you cannot see the changes

5. Go to your UWL view and make sure that the new XML configuration file is getting picked up. You can do so by verifying the property "Item Type Configuration Name" - under "Current Item Information".

- Shanti

Former Member
0 Kudos

xworked for me. Thanks for you help. Just didnt udnerstand why I had to use mss configuration? By default system was using a configuration uwl.webflow.SAP_ECC I thought I had to modify it. But it didnt work. The changes made to xml with mss worked.

Edited by: johnsap123 on Aug 5, 2011 4:40 PM

Answers (0)