The following lines contain the word 'select', 'insert', 'update' or 'delete':
* Procedure : Update_Status_Approved
* Purpose : Procedure called from Work Permit Release Approval when the workflow is approved
*********************************************************************/
PROCEDURE Update_Status_Approved
( itemtype in varchar2
, itemkey in varchar2
, actid in number
, funcmode in varchar2
, resultout out NOCOPY varchar2
)IS
l_permit_id number := wf_engine.GetItemAttrNumber( itemtype => itemtype,
itemkey => itemkey, aname => 'PERMIT_ID');
l_work_permit_header_rec.transaction_type := EAM_PROCESS_WO_PUB.G_OPR_UPDATE;
wf_core.context('EAMWPREL','UPDATE_STATUS_APPROVED',
itemtype, itemkey, actid, funcmode);
END Update_Status_Approved;
* Procedure : Update_Status_Rejected
* Purpose : Procedure called from Work Permit Release Approval when the workflow is Rejected
*********************************************************************/
PROCEDURE Update_Status_Rejected
( itemtype in varchar2
, itemkey in varchar2
, actid in number
, funcmode in varchar2
, resultout out NOCOPY varchar2
)IS
l_permit_id number := wf_engine.GetItemAttrNumber( itemtype => itemtype,
itemkey => itemkey, aname => 'PERMIT_ID');
l_work_permit_header_rec.transaction_type := EAM_PROCESS_WO_PUB.G_OPR_UPDATE;
wf_core.context('EAMWPREL','UPDATE_STATUS_REJECTED',
itemtype, itemkey, actid, funcmode);
END Update_Status_Rejected;
* Procedure : Update_AME_With_Response
* Purpose : Procedure called from Permit Release Approval when an approver
responds to a notification
*********************************************************************/
procedure Update_AME_With_Response
( itemtype in varchar2,
itemkey in varchar2,
actid in number,
funcmode in varchar2,
resultout out NOCOPY varchar2
) IS
E_FAILURE EXCEPTION;
SELECT responder,notification_id
into l_approver_name,l_nid
FROM wf_notifications
WHERE group_id=l_gid
AND status = 'CLOSED';
ame_api2.updateApprovalStatus2(applicationIdIn=>426,
transactionTypeIn=>'oracle.apps.eam.permit.release.approval',
transactionIdIn=>l_transaction_id,
approvalStatusIn => l_ame_status,
approverNameIn => l_approver_name);
ame_api2.updateApprovalStatus2(applicationIdIn=>426,
transactionTypeIn=>'oracle.apps.eam.permit.release.approval',
transactionIdIn=>l_transaction_id,
approvalStatusIn => 'FORWARD',
approverNameIn => l_original_approver_name,
forwardeeIn => l_forwardeeIn );
END Update_AME_With_Response;
((p_new_wp_rec.transaction_type=EAM_PROCESS_WO_PUB.G_OPR_UPDATE) AND
((p_old_wp_rec.status_type IN (1,17,7) ) OR (p_old_wp_rec.status_type=6) ) ) )
)THEN
x_approval_required := TRUE;