Skip to main content
mvr pallala ha fatto una domanda in #Apex
Hi Team,

the below is my code to implement the Items to Approve functionality using Visualforce Page and Apex.

Calss:

Public class actcontoller{

public Schema.SObjectType objType {get;set;}

public List<processinstanceworkitem> process {get; set;}

public actcontoller() {

Process=[select id, actorid ,ProcessInstanceId, processinstance.targetobjectid,processinstance.targetobject.name ,CreatedDate from processinstanceworkitem where actorid = :userinfo.getuserid() LIMIT 5];

( processinstanceworkitem p:process){

objType = P.processinstance.targetobjectid.getSobjectType();

//PrcocessID=p.ID; } } }

VF PAGE:

<apex:page controller="actcontoller">

<apex:PageBlock>

<apex:pageBlockTable value="{!Process}" var="task">

<apex:column headerValue="Action">

<apex:outputLink target="_top" value="p/process/ProcessInstanceWorkitemWizardStageManager?id={!task.Id}">Approve/Reject</apex:outputLink> </apex:column>

<apex:column headerValue="Related To" value="{!task.processinstance.targetobjectid}"/>

<apex:column headerValue="Type" value="{!objType}"/>

<apex:column headerValue="Date Submitted" value="{!task.CreatedDate}"/>

</apex:pageBlockTable> </apex:pageBlock>

</apex:Page>

When i click on approve/reject link i am getting the above error in Title.any one help me to resolve it?

 
1 risposta
0/9000