10: l_key varchar2(200);
11: l_value varchar2(500);
12: l_proc constant varchar2(50) := 'loadWorkflowAttributes';
13: begin
14: hr_utility.set_location('Entering:'|| g_package||'.'||l_proc, 10);
15: l_temp := p_eventData;
16: while ( length(l_temp) <> 0) loop
17: l_key := substr(l_temp, 1, instr(l_temp, ':') - 1);
18: l_temp := substr(l_temp, instr(l_temp, ':') + 1);
24: , aname => l_key
25: , avalue => l_value);
26: exception
27: when others then
28: hr_utility.set_location('Error Message : ' ||sqlerrm,50);
29: end;
30: end loop;
31: hr_utility.set_location('Success - Exiting:'|| g_package||'.'||l_proc, 100);
32: exception
27: when others then
28: hr_utility.set_location('Error Message : ' ||sqlerrm,50);
29: end;
30: end loop;
31: hr_utility.set_location('Success - Exiting:'|| g_package||'.'||l_proc, 100);
32: exception
33: when others then
34: hr_utility.set_location('Error - Exiting:' || g_package||'.'||l_proc, 110);
35: hr_utility.set_location('Error Message : ' || sqlerrm,130);
30: end loop;
31: hr_utility.set_location('Success - Exiting:'|| g_package||'.'||l_proc, 100);
32: exception
33: when others then
34: hr_utility.set_location('Error - Exiting:' || g_package||'.'||l_proc, 110);
35: hr_utility.set_location('Error Message : ' || sqlerrm,130);
36: end loadWorkflowAttributes;
37: --+
38: --+ launchNotificationsWorkflow
31: hr_utility.set_location('Success - Exiting:'|| g_package||'.'||l_proc, 100);
32: exception
33: when others then
34: hr_utility.set_location('Error - Exiting:' || g_package||'.'||l_proc, 110);
35: hr_utility.set_location('Error Message : ' || sqlerrm,130);
36: end loadWorkflowAttributes;
37: --+
38: --+ launchNotificationsWorkflow
39: --+
59: l_itemType varchar2(50);
60: l_itemKey varchar2(50);
61: l_proc constant varchar2(50) := 'launchNotificationsWorkflow';
62: begin
63: hr_utility.set_location('Entering:'|| g_package||'.'||l_proc, 10);
64: l_eventData := p_event.event_data;
65: l_assignmentId := IRC_NOTIFICATION_DATA_PKG.getParamValue
66: ( p_param => 'IRC_ASSIGNMENT_ID'
67: , p_eventData => l_eventData);
64: l_eventData := p_event.event_data;
65: l_assignmentId := IRC_NOTIFICATION_DATA_PKG.getParamValue
66: ( p_param => 'IRC_ASSIGNMENT_ID'
67: , p_eventData => l_eventData);
68: hr_utility.set_location('Assignment Id : ' || l_assignmentId, 20);
69: l_eventName := IRC_NOTIFICATION_DATA_PKG.getParamValue
70: ( p_param => 'IRC_EVENT_NAME'
71: , p_eventData => l_eventData);
72: hr_utility.set_location('Event Name : ' || l_eventName, 30);
68: hr_utility.set_location('Assignment Id : ' || l_assignmentId, 20);
69: l_eventName := IRC_NOTIFICATION_DATA_PKG.getParamValue
70: ( p_param => 'IRC_EVENT_NAME'
71: , p_eventData => l_eventData);
72: hr_utility.set_location('Event Name : ' || l_eventName, 30);
73: l_effectiveDate := to_date( IRC_NOTIFICATION_DATA_PKG.getParamValue
74: ( p_param => 'IRC_EFFECTIVE_DATE'
75: , p_eventData => l_eventData)
76: , 'DD-MM-RRRR');
76: , 'DD-MM-RRRR');
77: if l_effectiveDate is null then
78: l_effectiveDate := sysdate;
79: end if;
80: hr_utility.set_location('Effective Date : ' || l_effectiveDate, 40);
81: l_vacancyId := IRC_NOTIFICATION_DATA_PKG.getParamValue
82: ( p_param => 'IRC_VACANCY_ID'
83: , p_eventData => l_eventData);
84: if l_vacancyId is null then
89: || 'IRC_VACANCY_ID:'
90: || l_vacancyId
91: ||';';
92: end if;
93: hr_utility.set_location('Vacancy Id : ' || l_vacancyId, 50);
94: if l_vacancyId is not null then
95: l_eventData := l_eventData
96: || IRC_NOTIFICATION_DATA_PKG.getVacancyDetails
97: ( p_vacancyId => l_vacancyId
107: l_candidateId := irc_utilities_pkg.GET_RECRUITMENT_PERSON_ID
108: ( p_person_id => l_candidateId
109: , p_effective_date => l_effectiveDate);
110: end if;
111: hr_utility.set_location('Candidate Id : ' || l_candidateId, 60);
112: if l_candidateId is not null then
113: l_eventData := l_eventData
114: || 'IRC_CAND_PER_ID:'
115: || l_candidateId
126: end if;
127: l_managerId := IRC_NOTIFICATION_DATA_PKG.getManagerPersonId
128: ( p_vacancyId => l_vacancyId
129: , p_effectiveDate => l_effectiveDate);
130: hr_utility.set_location('Manager Id : ' || l_managerId, 70);
131: if l_managerId IS NOT null then
132: l_eventData := l_eventData
133: || 'IRC_MGR_PER_ID:'
134: || l_managerId
141: end if;
142: l_recruiterId := IRC_NOTIFICATION_DATA_PKG.getRecruiterPersonId
143: ( p_assignmentId => l_assignmentId
144: , p_effectiveDate => l_effectiveDate);
145: hr_utility.set_location('Recruiter Id : ' || l_recruiterId, 80);
146: if l_recruiterId IS NOT null then
147: l_eventData := l_eventData
148: || 'IRC_REC_PER_ID:'
149: || l_recruiterId
156: end if;
157: l_referrerId := IRC_NOTIFICATION_DATA_PKG.getParamValue
158: ( p_param => 'IRC_REFR_PER_ID'
159: , p_eventData => l_eventData);
160: hr_utility.set_location('Referrer Id : ' || l_referrerId, 90);
161: if l_referrerId IS NOT null then
162: l_eventData := l_eventData
163: || IRC_NOTIFICATION_DATA_PKG.getPersonDetails
164: ( p_personId => l_referrerId
167: end if;
168: l_actionPerformerId := IRC_NOTIFICATION_DATA_PKG.getParamValue
169: ( p_param => 'IRC_ACT_PERF_PER_ID'
170: , p_eventData => l_eventData);
171: hr_utility.set_location('Action Performer Id : ' || l_actionPerformerId, 100);
172: if l_actionPerformerId is not null then
173: l_eventData := l_eventData
174: || IRC_NOTIFICATION_DATA_PKG.getPersonDetails
175: ( p_personId => l_actionPerformerId
230: || IRC_NOTIFICATION_DATA_PKG.getinterviersnameshtml
231: ( p_interviewid => l_interviewId
232: , p_effectivedate => l_effectiveDate);
233: end if;
234: hr_utility.set_location('Populated all data:Create Workflow', 110);
235: hr_utility.set_location('Event Data : '||l_eventData, 120);
236: l_itemType := fnd_profile.value('IRC_NTF_WF_ITEM_TYPE');
237: hr_utility.set_location('Item Type : '||l_itemType, 130);
238: if l_itemType is not NULL then
231: ( p_interviewid => l_interviewId
232: , p_effectivedate => l_effectiveDate);
233: end if;
234: hr_utility.set_location('Populated all data:Create Workflow', 110);
235: hr_utility.set_location('Event Data : '||l_eventData, 120);
236: l_itemType := fnd_profile.value('IRC_NTF_WF_ITEM_TYPE');
237: hr_utility.set_location('Item Type : '||l_itemType, 130);
238: if l_itemType is not NULL then
239: l_itemKey := p_event.event_key;
233: end if;
234: hr_utility.set_location('Populated all data:Create Workflow', 110);
235: hr_utility.set_location('Event Data : '||l_eventData, 120);
236: l_itemType := fnd_profile.value('IRC_NTF_WF_ITEM_TYPE');
237: hr_utility.set_location('Item Type : '||l_itemType, 130);
238: if l_itemType is not NULL then
239: l_itemKey := p_event.event_key;
240: wf_engine.CreateProcess(l_itemType
241: ,l_itemKey
245: , p_itemKey => l_itemKey );
246: wf_engine.startprocess( l_itemType
247: , l_itemKey);
248: else
249: hr_utility.set_location('Workflow Item Type not set', 160);
250: end if;
251: hr_utility.set_location('Success - Exiting:'|| g_package||'.'||l_proc, 180);
252: return 'SUCCESS';
253: exception
247: , l_itemKey);
248: else
249: hr_utility.set_location('Workflow Item Type not set', 160);
250: end if;
251: hr_utility.set_location('Success - Exiting:'|| g_package||'.'||l_proc, 180);
252: return 'SUCCESS';
253: exception
254: when others then
255: hr_utility.set_location('Error - Exiting:'|| g_package||'.'||l_proc, 200);
251: hr_utility.set_location('Success - Exiting:'|| g_package||'.'||l_proc, 180);
252: return 'SUCCESS';
253: exception
254: when others then
255: hr_utility.set_location('Error - Exiting:'|| g_package||'.'||l_proc, 200);
256: hr_utility.set_location('Error Message: ' || sqlerrm, 210);
257: WF_CORE.CONTEXT('IRC_NOTIFICATIONS_WORKFLOW_PKG','launchNotificationsWorkflow',p_event.getEventName( ), p_subscriptionGuid);
258: WF_EVENT.setErrorInfo(p_event, 'ERROR');
259: return 'ERROR';
252: return 'SUCCESS';
253: exception
254: when others then
255: hr_utility.set_location('Error - Exiting:'|| g_package||'.'||l_proc, 200);
256: hr_utility.set_location('Error Message: ' || sqlerrm, 210);
257: WF_CORE.CONTEXT('IRC_NOTIFICATIONS_WORKFLOW_PKG','launchNotificationsWorkflow',p_event.getEventName( ), p_subscriptionGuid);
258: WF_EVENT.setErrorInfo(p_event, 'ERROR');
259: return 'ERROR';
260: end launchNotificationsWorkflow;
270: l_token varchar2(100);
271: l_value varchar2(100):= null;
272: l_proc constant varchar2(50) := 'parseAndReplaceFNDMessage';
273: begin
274: hr_utility.set_location('Entering:'|| g_package||'.'||l_proc, 10);
275: while (l_leftIndex <> 0) loop
276: l_value := null;
277: l_leftIndex := instr(l_returnMessage, '&' || 'IRC');
278: if (l_leftIndex = 0) then
288: , itemkey => p_itemKey
289: , aname => l_token);
290: exception
291: when others then
292: hr_utility.set_location('Error in getting Workflow attribute : ' || sqlerrm, 50);
293: end;
294: l_returnMessage := substr(l_returnMessage, 1, l_leftIndex -1 )
295: || l_value
296: || substr(l_returnMessage, l_rightIndex);
294: l_returnMessage := substr(l_returnMessage, 1, l_leftIndex -1 )
295: || l_value
296: || substr(l_returnMessage, l_rightIndex);
297: end loop;
298: hr_utility.set_location('Success - Exiting:'|| g_package||'.'||l_proc, 100);
299: return l_returnMessage;
300: exception
301: when others then
302: hr_utility.set_location('Error - Exiting:'|| g_package||'.'||l_proc, 120);
298: hr_utility.set_location('Success - Exiting:'|| g_package||'.'||l_proc, 100);
299: return l_returnMessage;
300: exception
301: when others then
302: hr_utility.set_location('Error - Exiting:'|| g_package||'.'||l_proc, 120);
303: hr_utility.set_location('Error Message : ' || sqlerrm, 130);
304: end parseAndReplaceFNDMessage;
305: --+
306: --+ attatchDoc
299: return l_returnMessage;
300: exception
301: when others then
302: hr_utility.set_location('Error - Exiting:'|| g_package||'.'||l_proc, 120);
303: hr_utility.set_location('Error Message : ' || sqlerrm, 130);
304: end parseAndReplaceFNDMessage;
305: --+
306: --+ attatchDoc
307: --+
377: l_doc_type := 'RESUME';
378: else
379: l_doc_type := 'AUTO_RESUME';
380: end if;
381: hr_utility.set_location('Entering attatchDocument:'|| g_package||'.'||l_proc, 10);
382: hr_utility.set_location('attatchDocument:p_personIdIn:'||p_personIdIn, 30);
383: hr_utility.set_location('attatchDocument:p_eventName:'||p_eventName, 40);
384: if p_personIdIn is not null then
385: l_person_id := to_number(p_personIdIn);
378: else
379: l_doc_type := 'AUTO_RESUME';
380: end if;
381: hr_utility.set_location('Entering attatchDocument:'|| g_package||'.'||l_proc, 10);
382: hr_utility.set_location('attatchDocument:p_personIdIn:'||p_personIdIn, 30);
383: hr_utility.set_location('attatchDocument:p_eventName:'||p_eventName, 40);
384: if p_personIdIn is not null then
385: l_person_id := to_number(p_personIdIn);
386: else
379: l_doc_type := 'AUTO_RESUME';
380: end if;
381: hr_utility.set_location('Entering attatchDocument:'|| g_package||'.'||l_proc, 10);
382: hr_utility.set_location('attatchDocument:p_personIdIn:'||p_personIdIn, 30);
383: hr_utility.set_location('attatchDocument:p_eventName:'||p_eventName, 40);
384: if p_personIdIn is not null then
385: l_person_id := to_number(p_personIdIn);
386: else
387: return;
399: return;
400: end if;
401: exception
402: when others then
403: hr_utility.set_location('error:'||sqlerrm, 30);
404: end;
405: end if;
406: open getDocIdList(l_person_id,l_doc_type);
407: fetch getDocIdList bulk collect into l_doc_ids;
411: 'IRC_ATTACHMENT_'||to_char(i),
412: 'plsqlblob:irc_notification_workflow_pkg.attatchDoc/'||l_doc_ids(i));
413: end loop;
414: end if;
415: hr_utility.set_location('Exiting attatchDocument:'|| g_package||'.'||l_proc, 60);
416: exception
417: when others then
418: hr_utility.set_location('Error occurred in :'|| g_package||'.'||l_proc, 70);
419: hr_utility.set_location('Error Message:'|| SQLERRM, 80);
414: end if;
415: hr_utility.set_location('Exiting attatchDocument:'|| g_package||'.'||l_proc, 60);
416: exception
417: when others then
418: hr_utility.set_location('Error occurred in :'|| g_package||'.'||l_proc, 70);
419: hr_utility.set_location('Error Message:'|| SQLERRM, 80);
420: end attachDocument;
421: --+
422: --+ getNextRecipient
415: hr_utility.set_location('Exiting attatchDocument:'|| g_package||'.'||l_proc, 60);
416: exception
417: when others then
418: hr_utility.set_location('Error occurred in :'|| g_package||'.'||l_proc, 70);
419: hr_utility.set_location('Error Message:'|| SQLERRM, 80);
420: end attachDocument;
421: --+
422: --+ getNextRecipient
423: --+
451: l_candidatePersonId varchar2(50);
452: l_person_type varchar2(50);
453: l_ntf_message_type varchar2(50);
454: BEGIN
455: hr_utility.set_location('Entering:'|| g_package||'.'||l_proc, 10);
456: l_ameTransactionType := fnd_profile.value('IRC_NTF_AME_TX_TYPE');
457: l_person_type := null;
458: if l_ameTransactionType is not NULL then
459: hr_utility.set_location('AME Transaction Type : ' || l_ameTransactionType, 20);
455: hr_utility.set_location('Entering:'|| g_package||'.'||l_proc, 10);
456: l_ameTransactionType := fnd_profile.value('IRC_NTF_AME_TX_TYPE');
457: l_person_type := null;
458: if l_ameTransactionType is not NULL then
459: hr_utility.set_location('AME Transaction Type : ' || l_ameTransactionType, 20);
460: begin
461: ame_api2.getNextApprovers2(applicationIdIn => 800
462: , transactionTypeIn => l_ameTransactionType
463: , transactionIdIn => p_itemKey
473: exception
474: when others then
475: raise e_ameException;
476: end;
477: hr_utility.set_location('AME Transaction Complete : ' || l_approvalprocesscompleteynout,30);
478: if l_approvalProcessCompleteYNOut = 'N' then
479: hr_utility.set_location('Recipient : ' || l_nextApprovers(1).name,60);
480:
481: wf_engine.setItemAttrText ( itemtype => p_itemType
475: raise e_ameException;
476: end;
477: hr_utility.set_location('AME Transaction Complete : ' || l_approvalprocesscompleteynout,30);
478: if l_approvalProcessCompleteYNOut = 'N' then
479: hr_utility.set_location('Recipient : ' || l_nextApprovers(1).name,60);
480:
481: wf_engine.setItemAttrText ( itemtype => p_itemType
482: , itemkey => p_itemKey
483: , aname => 'IRC_APPROVER'
499: end if;
500: end if;
501: end loop;
502:
503: hr_utility.set_location('FND Message Name for Subject : ' || l_messageSubjectName,80);
504: hr_utility.set_location('FND Message Name for Body : ' || l_messageBodyName,90);
505: if l_messageSubjectName is null or l_messageBodyName is null then
506: raise e_messageNameIsNull;
507: else
500: end if;
501: end loop;
502:
503: hr_utility.set_location('FND Message Name for Subject : ' || l_messageSubjectName,80);
504: hr_utility.set_location('FND Message Name for Body : ' || l_messageBodyName,90);
505: if l_messageSubjectName is null or l_messageBodyName is null then
506: raise e_messageNameIsNull;
507: else
508: fnd_message.set_name('PER',l_messageSubjectName);
508: fnd_message.set_name('PER',l_messageSubjectName);
509: l_messageSubject := parseAndReplaceFNDMessage( p_itemType => p_itemType
510: , p_itemKey => p_itemKey
511: , p_message => fnd_message.get);
512: hr_utility.set_location('Message Subject sent to Recipient: '||l_messageSubject,120);
513: wf_engine.setItemAttrText ( itemtype => p_itemType
514: , itemkey => p_itemKey
515: , aname => 'IRC_MESSAGE_SUBJECT'
516: , avalue => l_messageSubject);
517: fnd_message.set_name('PER',l_messageBodyName);
518: l_messageBody := parseAndReplaceFNDMessage( p_itemType => p_itemType
519: , p_itemKey => p_itemKey
520: , p_message => fnd_message.get);
521: hr_utility.set_location('Message Body sent to recipient: '||l_messageBody,150);
522: wf_engine.setitemattrtext( itemtype => p_itemType
523: , itemkey => p_itemKey
524: , aname => 'IRC_MESSAGE_BODY'
525: , avalue => l_messageBody);
532: l_notificationId:=wf_notification.send( l_nextApprovers(1).name
533: , l_message_type
534: , l_ntf_message_type
535: );
536: hr_utility.set_location('Notification ID : ' || l_notificationId,180);
537: wf_notification.setAttrText (l_notificationId, '#FROM_ROLE', 'SYSADMIN');
538: wf_notification.setAttrText(l_notificationId, 'SUBJECT', l_messageSubject);
539: wf_notification.setAttrText(l_notificationId, 'TEXT_BODY', l_messageBody);
540: wf_notification.setAttrText(l_notificationId, 'HTML_BODY', l_messageBody);
545: attachDocument(l_notificationId,l_candidatePersonId,l_eventName,p_itemKey);
546: end if;
547: wf_notification.denormalize_notification(l_notificationId);
548: result := 'COMPLETE:IRC_E';
549: hr_utility.set_location('Recipients Exist - Exiting:'|| g_package||'.'||l_proc, 200);
550: end if;
551: else
552: hr_utility.set_location('No more Recipients - Exiting:'|| g_package||'.'||l_proc, 220);
553: result := 'COMPLETE:IRC_NE';
548: result := 'COMPLETE:IRC_E';
549: hr_utility.set_location('Recipients Exist - Exiting:'|| g_package||'.'||l_proc, 200);
550: end if;
551: else
552: hr_utility.set_location('No more Recipients - Exiting:'|| g_package||'.'||l_proc, 220);
553: result := 'COMPLETE:IRC_NE';
554: end if;
555: else
556: hr_utility.set_location('Profile value for AME Transaction Type not set - Exiting :'|| g_package||'.'||l_proc, 240);
552: hr_utility.set_location('No more Recipients - Exiting:'|| g_package||'.'||l_proc, 220);
553: result := 'COMPLETE:IRC_NE';
554: end if;
555: else
556: hr_utility.set_location('Profile value for AME Transaction Type not set - Exiting :'|| g_package||'.'||l_proc, 240);
557: result := 'COMPLETE:IRC_NE';
558: end if;
559: exception
560: when e_ameException then
557: result := 'COMPLETE:IRC_NE';
558: end if;
559: exception
560: when e_ameException then
561: hr_utility.set_location('AME Error - Exiting:'|| g_package||'.'||l_proc, 260);
562: hr_utility.set_location('Error Message:'|| SQLERRM, 270);
563: result := 'COMPLETE:IRC_NE';
564: when e_messageNameIsNull then
565: hr_utility.set_location('Error - Skipping'|| g_package||'.'||l_proc, 300);
558: end if;
559: exception
560: when e_ameException then
561: hr_utility.set_location('AME Error - Exiting:'|| g_package||'.'||l_proc, 260);
562: hr_utility.set_location('Error Message:'|| SQLERRM, 270);
563: result := 'COMPLETE:IRC_NE';
564: when e_messageNameIsNull then
565: hr_utility.set_location('Error - Skipping'|| g_package||'.'||l_proc, 300);
566: hr_utility.set_location('Error Message:'|| 'FND message not defined for this recipient', 310);
561: hr_utility.set_location('AME Error - Exiting:'|| g_package||'.'||l_proc, 260);
562: hr_utility.set_location('Error Message:'|| SQLERRM, 270);
563: result := 'COMPLETE:IRC_NE';
564: when e_messageNameIsNull then
565: hr_utility.set_location('Error - Skipping'|| g_package||'.'||l_proc, 300);
566: hr_utility.set_location('Error Message:'|| 'FND message not defined for this recipient', 310);
567: result := 'COMPLETE:IRC_E';
568: when others then
569: hr_utility.set_location('Error - Skipping:'|| g_package||'.'||l_proc, 350);
562: hr_utility.set_location('Error Message:'|| SQLERRM, 270);
563: result := 'COMPLETE:IRC_NE';
564: when e_messageNameIsNull then
565: hr_utility.set_location('Error - Skipping'|| g_package||'.'||l_proc, 300);
566: hr_utility.set_location('Error Message:'|| 'FND message not defined for this recipient', 310);
567: result := 'COMPLETE:IRC_E';
568: when others then
569: hr_utility.set_location('Error - Skipping:'|| g_package||'.'||l_proc, 350);
570: hr_utility.set_location('Error Message:'|| SQLERRM, 360);
565: hr_utility.set_location('Error - Skipping'|| g_package||'.'||l_proc, 300);
566: hr_utility.set_location('Error Message:'|| 'FND message not defined for this recipient', 310);
567: result := 'COMPLETE:IRC_E';
568: when others then
569: hr_utility.set_location('Error - Skipping:'|| g_package||'.'||l_proc, 350);
570: hr_utility.set_location('Error Message:'|| SQLERRM, 360);
571: result := 'COMPLETE:IRC_E';
572: end getNextRecipient;
573: --+
566: hr_utility.set_location('Error Message:'|| 'FND message not defined for this recipient', 310);
567: result := 'COMPLETE:IRC_E';
568: when others then
569: hr_utility.set_location('Error - Skipping:'|| g_package||'.'||l_proc, 350);
570: hr_utility.set_location('Error Message:'|| SQLERRM, 360);
571: result := 'COMPLETE:IRC_E';
572: end getNextRecipient;
573: --+
574: --+ getWFAttrValue
577: , p_WFAttr in varchar2 ) return varchar2 is
578: l_value varchar2(1000);
579: l_proc constant varchar2(50) := 'getWFAttrValue';
580: begin
581: hr_utility.set_location('Entering:'|| g_package||'.'||l_proc, 10);
582: g_WFItemType := fnd_profile.value('IRC_NTF_WF_ITEM_TYPE');
583: hr_utility.set_location('Workflow Attribute : '|| p_WFAttr, 20);
584: l_value := wf_engine.getitemattrtext( itemtype => g_WFItemType
585: , itemkey => p_itemKey
579: l_proc constant varchar2(50) := 'getWFAttrValue';
580: begin
581: hr_utility.set_location('Entering:'|| g_package||'.'||l_proc, 10);
582: g_WFItemType := fnd_profile.value('IRC_NTF_WF_ITEM_TYPE');
583: hr_utility.set_location('Workflow Attribute : '|| p_WFAttr, 20);
584: l_value := wf_engine.getitemattrtext( itemtype => g_WFItemType
585: , itemkey => p_itemKey
586: , aname => p_WFAttr);
587: hr_utility.set_location('Success - Exiting:'|| g_package||'.'||l_proc, 60);
583: hr_utility.set_location('Workflow Attribute : '|| p_WFAttr, 20);
584: l_value := wf_engine.getitemattrtext( itemtype => g_WFItemType
585: , itemkey => p_itemKey
586: , aname => p_WFAttr);
587: hr_utility.set_location('Success - Exiting:'|| g_package||'.'||l_proc, 60);
588: return l_value;
589: exception
590: when others then
591: hr_utility.set_location('Error - Exiting:'|| g_package||'.'||l_proc, 100);
587: hr_utility.set_location('Success - Exiting:'|| g_package||'.'||l_proc, 60);
588: return l_value;
589: exception
590: when others then
591: hr_utility.set_location('Error - Exiting:'|| g_package||'.'||l_proc, 100);
592: hr_utility.set_location('Error Message : ' || sqlerrm, 110);
593: return null;
594: end getWFAttrValue;
595: --+
588: return l_value;
589: exception
590: when others then
591: hr_utility.set_location('Error - Exiting:'|| g_package||'.'||l_proc, 100);
592: hr_utility.set_location('Error Message : ' || sqlerrm, 110);
593: return null;
594: end getWFAttrValue;
595: --+
596: --+ isValidRecipient
604: and status = 'ACTIVE';
605: l_roleExists number;
606: l_proc constant varchar2(50) := 'isValidRecipient';
607: begin
608: hr_utility.set_location('Entering:'|| g_package||'.'||l_proc, 10);
609: open csrRoleExists(p_recipient);
610: fetch csrRoleExists into l_roleExists;
611: close csrRoleExists;
612: if l_roleExists > 0 then
615: return 'false';
616: end if;
617: exception
618: when others then
619: hr_utility.set_location('Error - Exiting:'|| g_package||'.'||l_proc, 50);
620: hr_utility.set_location('Error Message : ' || sqlerrm, 60);
621: end isValidRecipient;
622:
623: function checkIfIntvwCandidateIncluded ( p_modifiedItemsString varchar2
616: end if;
617: exception
618: when others then
619: hr_utility.set_location('Error - Exiting:'|| g_package||'.'||l_proc, 50);
620: hr_utility.set_location('Error Message : ' || sqlerrm, 60);
621: end isValidRecipient;
622:
623: function checkIfIntvwCandidateIncluded ( p_modifiedItemsString varchar2
624: , p_eventName varchar2)
639: OR instr(c_modifiedItemsString,',STATUS,')>0;
640: l_includeCandidate varchar2(10);
641: l_proc constant varchar2(50) := 'checkIfIntvwCandidateIncluded';
642: begin
643: hr_utility.set_location('Entering:'|| g_package||'.'||l_proc, 10);
644: if p_eventName = 'INTVCRE' then
645: l_includeCandidate := 'true';
646: else
647: open csrCheckModifiedItems(',' || p_modifiedItemsString || ',');
653: end if;
654: return l_includeCandidate;
655: exception
656: when others then
657: hr_utility.set_location('Error - Exiting:'|| g_package||'.'||l_proc, 50);
658: hr_utility.set_location('Error Message : ' || sqlerrm, 60);
659: end checkIfIntvwCandidateIncluded;
660:
661: procedure getDocument (p_documentId in varchar2
654: return l_includeCandidate;
655: exception
656: when others then
657: hr_utility.set_location('Error - Exiting:'|| g_package||'.'||l_proc, 50);
658: hr_utility.set_location('Error Message : ' || sqlerrm, 60);
659: end checkIfIntvwCandidateIncluded;
660:
661: procedure getDocument (p_documentId in varchar2
662: ,p_displayType in varchar2