167:
168: wf_engine.SetItemAttrText(Itemtype => ItemType,
169: Itemkey => NEWItemKey,
170: aname => '#FROM_ROLE',
171: avalue => ZPB_WF_NTF.ID_to_FNDUser(authorID));
172:
173: return;
174:
175: exception
207:
208: thisRecipient := v_recipient.value;
209:
210: if c_recipient%ROWCOUNT = 1 then
211: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID);
212: zpb_wf_ntf.SetRole(rolename, relative);
213: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisRecipient);
214: else
215: if zpb_wf_ntf.user_in_role(rolename, thisRecipient) = 'N' then
208: thisRecipient := v_recipient.value;
209:
210: if c_recipient%ROWCOUNT = 1 then
211: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID);
212: zpb_wf_ntf.SetRole(rolename, relative);
213: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisRecipient);
214: else
215: if zpb_wf_ntf.user_in_role(rolename, thisRecipient) = 'N' then
216: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisRecipient);
211: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID);
212: zpb_wf_ntf.SetRole(rolename, relative);
213: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisRecipient);
214: else
215: if zpb_wf_ntf.user_in_role(rolename, thisRecipient) = 'N' then
216: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisRecipient);
217: end if;
218: end if;
219:
217: end if;
218: end if;
219:
220: -- add in shadow if there is one
221: thisUserID := zpb_wf_ntf.fnduser_to_ID(thisRecipient);
222: zpb_wf_ntf.add_Shadow(rolename, thisUserId);
223:
224: end loop;
225:
218: end if;
219:
220: -- add in shadow if there is one
221: thisUserID := zpb_wf_ntf.fnduser_to_ID(thisRecipient);
222: zpb_wf_ntf.add_Shadow(rolename, thisUserId);
223:
224: end loop;
225:
226: -- add in author as recipient if EXCEPTION_TYPE => A
224: end loop;
225:
226: -- add in author as recipient if EXCEPTION_TYPE => A
227: if ExcType = 'A' then
228: thisRecipient := zpb_wf_ntf.ID_to_FNDUser(AuthorID);
229: if zpb_wf_ntf.user_in_role(rolename, thisRecipient) = 'N' then
230: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisRecipient);
231: zpb_wf_ntf.add_Shadow(rolename, AuthorID);
232: end if;
225:
226: -- add in author as recipient if EXCEPTION_TYPE => A
227: if ExcType = 'A' then
228: thisRecipient := zpb_wf_ntf.ID_to_FNDUser(AuthorID);
229: if zpb_wf_ntf.user_in_role(rolename, thisRecipient) = 'N' then
230: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisRecipient);
231: zpb_wf_ntf.add_Shadow(rolename, AuthorID);
232: end if;
233: end if;
227: if ExcType = 'A' then
228: thisRecipient := zpb_wf_ntf.ID_to_FNDUser(AuthorID);
229: if zpb_wf_ntf.user_in_role(rolename, thisRecipient) = 'N' then
230: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisRecipient);
231: zpb_wf_ntf.add_Shadow(rolename, AuthorID);
232: end if;
233: end if;
234:
235: wf_engine.SetItemAttrText(Itemtype => ItemType,
280: aname => 'ACNAME');
281: ownerID := wf_engine.GetItemAttrNumber(Itemtype => ItemType,
282: Itemkey => ItemKey,
283: aname => 'OWNERID');
284: owner := zpb_wf_ntf.ID_to_FNDUser(ownerID);
285:
286: InstanceID := wf_engine.GetItemAttrNumber(Itemtype => ItemType,
287: Itemkey => ItemKey,
288: aname => 'INSTANCEID');
335:
336: elsif ntfTarget = 'OWNER_OF_AC' then
337:
338: -- BUSINESS PROCESS OWNER => OWNER_OF_AC
339: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID);
340: zpb_wf_ntf.SetRole(rolename, relative);
341: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, owner);
342: zpb_wf_ntf.add_Shadow(rolename, ownerID);
343:
336: elsif ntfTarget = 'OWNER_OF_AC' then
337:
338: -- BUSINESS PROCESS OWNER => OWNER_OF_AC
339: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID);
340: zpb_wf_ntf.SetRole(rolename, relative);
341: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, owner);
342: zpb_wf_ntf.add_Shadow(rolename, ownerID);
343:
344: -- add in author as recipient if EXCEPTION_TYPE => A
338: -- BUSINESS PROCESS OWNER => OWNER_OF_AC
339: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID);
340: zpb_wf_ntf.SetRole(rolename, relative);
341: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, owner);
342: zpb_wf_ntf.add_Shadow(rolename, ownerID);
343:
344: -- add in author as recipient if EXCEPTION_TYPE => A
345: if ExcType = 'A' then
346: thisUser := zpb_wf_ntf.ID_to_FNDUser(AuthorID);
342: zpb_wf_ntf.add_Shadow(rolename, ownerID);
343:
344: -- add in author as recipient if EXCEPTION_TYPE => A
345: if ExcType = 'A' then
346: thisUser := zpb_wf_ntf.ID_to_FNDUser(AuthorID);
347: if zpb_wf_ntf.user_in_role(rolename, thisUser) = 'N' then
348: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisUser);
349: zpb_wf_ntf.add_Shadow(rolename, AuthorID);
350: end if;
343:
344: -- add in author as recipient if EXCEPTION_TYPE => A
345: if ExcType = 'A' then
346: thisUser := zpb_wf_ntf.ID_to_FNDUser(AuthorID);
347: if zpb_wf_ntf.user_in_role(rolename, thisUser) = 'N' then
348: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisUser);
349: zpb_wf_ntf.add_Shadow(rolename, AuthorID);
350: end if;
351: end if;
345: if ExcType = 'A' then
346: thisUser := zpb_wf_ntf.ID_to_FNDUser(AuthorID);
347: if zpb_wf_ntf.user_in_role(rolename, thisUser) = 'N' then
348: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisUser);
349: zpb_wf_ntf.add_Shadow(rolename, AuthorID);
350: end if;
351: end if;
352:
353: wf_engine.SetItemAttrText(Itemtype => ItemType,
356: avalue => RoleName);
357:
358: elsif ntfTarget = 'JUST_AUTHOR' then
359: -- Just the Author
360: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID);
361: zpb_wf_ntf.SetRole(rolename, relative);
362: thisUser := zpb_wf_ntf.ID_to_FNDUser(AuthorID);
363: if zpb_wf_ntf.user_in_role(rolename, thisUser) = 'N' then
364: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisUser);
357:
358: elsif ntfTarget = 'JUST_AUTHOR' then
359: -- Just the Author
360: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID);
361: zpb_wf_ntf.SetRole(rolename, relative);
362: thisUser := zpb_wf_ntf.ID_to_FNDUser(AuthorID);
363: if zpb_wf_ntf.user_in_role(rolename, thisUser) = 'N' then
364: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisUser);
365: -- zpb_wf_ntf.add_Shadow(rolename, AuthorID);
358: elsif ntfTarget = 'JUST_AUTHOR' then
359: -- Just the Author
360: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID);
361: zpb_wf_ntf.SetRole(rolename, relative);
362: thisUser := zpb_wf_ntf.ID_to_FNDUser(AuthorID);
363: if zpb_wf_ntf.user_in_role(rolename, thisUser) = 'N' then
364: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisUser);
365: -- zpb_wf_ntf.add_Shadow(rolename, AuthorID);
366: end if;
359: -- Just the Author
360: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID);
361: zpb_wf_ntf.SetRole(rolename, relative);
362: thisUser := zpb_wf_ntf.ID_to_FNDUser(AuthorID);
363: if zpb_wf_ntf.user_in_role(rolename, thisUser) = 'N' then
364: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisUser);
365: -- zpb_wf_ntf.add_Shadow(rolename, AuthorID);
366: end if;
367: wf_engine.SetItemAttrText(Itemtype => ItemType,
361: zpb_wf_ntf.SetRole(rolename, relative);
362: thisUser := zpb_wf_ntf.ID_to_FNDUser(AuthorID);
363: if zpb_wf_ntf.user_in_role(rolename, thisUser) = 'N' then
364: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisUser);
365: -- zpb_wf_ntf.add_Shadow(rolename, AuthorID);
366: end if;
367: wf_engine.SetItemAttrText(Itemtype => ItemType,
368: Itemkey => NEWItemKey,
369: aname => 'EPBPERFORMER',
488:
489: wf_engine.SetItemAttrText(Itemtype => ItemType,
490: Itemkey => ItemKey,
491: aname => '#FROM_ROLE',
492: avalue => ZPB_WF_NTF.ID_to_FNDUser(authorID));
493:
494: select value into ntfType
495: from ZPB_TASK_PARAMETERS
496: where TASK_ID = TaskID and NAME = 'EXPLANATION_REQUIRED_FLAG';
582: thisOwnerID := wf_engine.GetItemAttrNumber(Itemtype => ItemType,
583: Itemkey => ItemKey,
584: aname => 'OWNERID');
585:
586: zpb_wf_ntf.SendExpiredUserMsg(thisOwnerID, taskID, itemType);
587: -- end b 4948928
588:
589: END IF;
590:
778:
779:
780: if instr(UserList, ',') > 0 then
781: -- FND user names list so build Ad Hoc role
782: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, taskID);
783: zpb_wf_ntf.SetRole(rolename, relative);
784: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, UserList);
785: elsif length(UserList) > 0 then
786: rolename := UserList;
779:
780: if instr(UserList, ',') > 0 then
781: -- FND user names list so build Ad Hoc role
782: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, taskID);
783: zpb_wf_ntf.SetRole(rolename, relative);
784: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, UserList);
785: elsif length(UserList) > 0 then
786: rolename := UserList;
787: end if;
924: aname => 'ACNAME');
925: ProcOwnerID := wf_engine.GetItemAttrNumber(Itemtype => ItemType,
926: Itemkey => ParentItemKey,
927: aname => 'OWNERID');
928: ProcOwner := zpb_wf_ntf.ID_to_FNDUser(ProcOwnerID);
929:
930: InstanceID := wf_engine.GetItemAttrNumber(Itemtype => ItemType,
931: Itemkey => ParentItemKey,
932: aname => 'INSTANCEID');
997: aname => 'URLEXPLAIN',
998: avalue => l_newURL);
999:
1000: -- make the Ad Hoc role to hold both the dataowner and shadow
1001: if zpb_wf_ntf.has_Shadow(thisOwnerID) = 'Y' then
1002: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID, thisOwnerID);
1003: select distinct display_name
1004: into NewDispName
1005: from wf_users
998: avalue => l_newURL);
999:
1000: -- make the Ad Hoc role to hold both the dataowner and shadow
1001: if zpb_wf_ntf.has_Shadow(thisOwnerID) = 'Y' then
1002: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID, thisOwnerID);
1003: select distinct display_name
1004: into NewDispName
1005: from wf_users
1006: where name = thisOwner;
1009: FND_MESSAGE.SET_NAME ('ZPB', 'ZPB_NTF_ANDSHADOWS');
1010: l_label := FND_MESSAGE.GET;
1011: NewDispName := NewDispName || l_label;
1012:
1013: zpb_wf_ntf.SetRole(rolename, relative, NewDispName);
1014: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisOwner);
1015: zpb_wf_ntf.add_Shadow(rolename, thisOwnerID);
1016: else
1017: rolename := thisOwner;
1011: NewDispName := NewDispName || l_label;
1012:
1013: zpb_wf_ntf.SetRole(rolename, relative, NewDispName);
1014: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisOwner);
1015: zpb_wf_ntf.add_Shadow(rolename, thisOwnerID);
1016: else
1017: rolename := thisOwner;
1018: end if;
1019:
1027: -- make the Ad Hoc role to hold both the APPROVERS and shadow
1028:
1029: dbms_lock.sleep(1);
1030:
1031: if zpb_wf_ntf.has_Shadow(thisApproverID) = 'Y' then
1032: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID, thisApproverID);
1033: select distinct display_name
1034: into NewDispName
1035: from wf_users
1028:
1029: dbms_lock.sleep(1);
1030:
1031: if zpb_wf_ntf.has_Shadow(thisApproverID) = 'Y' then
1032: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID, thisApproverID);
1033: select distinct display_name
1034: into NewDispName
1035: from wf_users
1036: where name = thisApprover;
1039: FND_MESSAGE.SET_NAME ('ZPB', 'ZPB_NTF_ANDSHADOWS');
1040: l_label := FND_MESSAGE.GET;
1041: NewDispName := NewDispName || l_label;
1042:
1043: zpb_wf_ntf.SetRole(rolename, relative, NewDispName);
1044: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisApprover);
1045: zpb_wf_ntf.add_Shadow(rolename, thisApproverID);
1046: else
1047: rolename := thisApprover;
1041: NewDispName := NewDispName || l_label;
1042:
1043: zpb_wf_ntf.SetRole(rolename, relative, NewDispName);
1044: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisApprover);
1045: zpb_wf_ntf.add_Shadow(rolename, thisApproverID);
1046: else
1047: rolename := thisApprover;
1048: end if;
1049:
1636: from ZPB_TASK_PARAMETERS
1637: where TASK_ID = TaskID and name = 'EXPLANATION_APPROVER';
1638:
1639: if ApproverTYPE = 'AUTHOR_OF_EXCEPTION' then
1640: thisApprover := zpb_wf_ntf.ID_to_fnduser(thisApproverID);
1641: end if;
1642:
1643: -- FOR EACH OWNER start a explanation required process
1644: for v_recipient in c_recipient loop
1668:
1669: -- explanation recipient
1670: -- make the Ad Hoc role to hold both the dataowner and shadow
1671:
1672: thisRecipientID := zpb_wf_ntf.fnduser_to_ID(thisRecipient);
1673:
1674: --=============================================================================
1675: -- b5179198 URL profile should be set for the ntf target user
1676: l_htmlAgent := FND_PROFILE.VALUE_SPECIFIC('APPS_FRAMEWORK_AGENT', thisRecipientID);
1676: l_htmlAgent := FND_PROFILE.VALUE_SPECIFIC('APPS_FRAMEWORK_AGENT', thisRecipientID);
1677: l_newURL := l_htmlAgent || '/OA_HTML/' || l_URLexplain;
1678: --==============================================================================
1679:
1680: if zpb_wf_ntf.has_Shadow(thisRecipientID) = 'Y' then
1681: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID, thisRecipientID);
1682: select distinct display_name
1683: into NewDispName
1684: from wf_users
1677: l_newURL := l_htmlAgent || '/OA_HTML/' || l_URLexplain;
1678: --==============================================================================
1679:
1680: if zpb_wf_ntf.has_Shadow(thisRecipientID) = 'Y' then
1681: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID, thisRecipientID);
1682: select distinct display_name
1683: into NewDispName
1684: from wf_users
1685: where name = thisRecipient;
1688: FND_MESSAGE.SET_NAME ('ZPB', 'ZPB_NTF_ANDSHADOWS');
1689: l_label := FND_MESSAGE.GET;
1690: NewDispName := NewDispName || l_label;
1691:
1692: zpb_wf_ntf.SetRole(rolename, relative, NewDispName);
1693: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisRecipient);
1694: zpb_wf_ntf.add_Shadow(rolename, thisRecipientID);
1695: else
1696: rolename := thisRecipient;
1690: NewDispName := NewDispName || l_label;
1691:
1692: zpb_wf_ntf.SetRole(rolename, relative, NewDispName);
1693: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisRecipient);
1694: zpb_wf_ntf.add_Shadow(rolename, thisRecipientID);
1695: else
1696: rolename := thisRecipient;
1697: end if;
1698:
1705:
1706: -- **********************************************************
1707: -- make the Ad Hoc role to hold both the APPROVERS and shadow
1708:
1709: if zpb_wf_ntf.has_Shadow(thisApproverID) = 'Y' then
1710: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID, thisApproverID);
1711: select distinct display_name
1712: into NewDispName
1713: from wf_users
1706: -- **********************************************************
1707: -- make the Ad Hoc role to hold both the APPROVERS and shadow
1708:
1709: if zpb_wf_ntf.has_Shadow(thisApproverID) = 'Y' then
1710: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID, thisApproverID);
1711: select distinct display_name
1712: into NewDispName
1713: from wf_users
1714: where name = thisApprover;
1717: FND_MESSAGE.SET_NAME ('ZPB', 'ZPB_NTF_ANDSHADOWS');
1718: l_label := FND_MESSAGE.GET;
1719: NewDispName := NewDispName || l_label;
1720:
1721: zpb_wf_ntf.SetRole(rolename, relative, NewDispName);
1722: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisApprover);
1723: zpb_wf_ntf.add_Shadow(rolename, thisApproverID);
1724: else
1725: rolename := thisApprover;
1719: NewDispName := NewDispName || l_label;
1720:
1721: zpb_wf_ntf.SetRole(rolename, relative, NewDispName);
1722: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisApprover);
1723: zpb_wf_ntf.add_Shadow(rolename, thisApproverID);
1724: else
1725: rolename := thisApprover;
1726: end if;
1727:
2269:
2270: -- **********************************************************
2271: -- make the Ad Hoc role to hold both the dataowner and shadow
2272: dbms_lock.sleep(1);
2273: if zpb_wf_ntf.has_Shadow(thisOwnerID) = 'Y' then
2274: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID, thisOwnerID);
2275: select distinct display_name
2276: into NewDispName
2277: from wf_users
2270: -- **********************************************************
2271: -- make the Ad Hoc role to hold both the dataowner and shadow
2272: dbms_lock.sleep(1);
2273: if zpb_wf_ntf.has_Shadow(thisOwnerID) = 'Y' then
2274: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID, thisOwnerID);
2275: select distinct display_name
2276: into NewDispName
2277: from wf_users
2278: where name = thisOwner;
2281: FND_MESSAGE.SET_NAME ('ZPB', 'ZPB_NTF_ANDSHADOWS');
2282: l_label := FND_MESSAGE.GET;
2283: NewDispName := NewDispName || l_label;
2284:
2285: zpb_wf_ntf.SetRole(rolename, relative, NewDispName);
2286: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisOwner);
2287: zpb_wf_ntf.add_Shadow(rolename, thisOwnerID);
2288: else
2289: rolename := thisOwner;
2283: NewDispName := NewDispName || l_label;
2284:
2285: zpb_wf_ntf.SetRole(rolename, relative, NewDispName);
2286: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisOwner);
2287: zpb_wf_ntf.add_Shadow(rolename, thisOwnerID);
2288: else
2289: rolename := thisOwner;
2290: end if;
2291:
2296: avalue => rolename);
2297:
2298: -- **********************************************************
2299: -- make the Ad Hoc role to hold both the APPROVERS and shadow
2300: if zpb_wf_ntf.has_Shadow(thisApproverID) = 'Y' then
2301: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID, thisApproverID);
2302: select distinct display_name
2303: into NewDispName
2304: from wf_users
2297:
2298: -- **********************************************************
2299: -- make the Ad Hoc role to hold both the APPROVERS and shadow
2300: if zpb_wf_ntf.has_Shadow(thisApproverID) = 'Y' then
2301: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID, thisApproverID);
2302: select distinct display_name
2303: into NewDispName
2304: from wf_users
2305: where name = thisApprover;
2308: FND_MESSAGE.SET_NAME ('ZPB', 'ZPB_NTF_ANDSHADOWS');
2309: l_label := FND_MESSAGE.GET;
2310: NewDispName := NewDispName || l_label;
2311:
2312: zpb_wf_ntf.SetRole(rolename, relative, NewDispName);
2313: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisApprover);
2314: zpb_wf_ntf.add_Shadow(rolename, thisApproverID);
2315: else
2316: rolename := thisApprover;
2310: NewDispName := NewDispName || l_label;
2311:
2312: zpb_wf_ntf.SetRole(rolename, relative, NewDispName);
2313: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisApprover);
2314: zpb_wf_ntf.add_Shadow(rolename, thisApproverID);
2315: else
2316: rolename := thisApprover;
2317: end if;
2318:
2433: ProcOwnerID := wf_engine.GetItemAttrNumber(Itemtype => ItemType,
2434: Itemkey => ItemKey,
2435: aname => 'OWNERID');
2436:
2437: zpb_wf_ntf.SendExpiredUserMsg(ProcOwnerID, taskID, itemType);
2438: -- end b 4948928
2439:
2440:
2441: /*
2643: aname => 'ACNAME');
2644: ProcOwnerID := wf_engine.GetItemAttrNumber(Itemtype => ItemType,
2645: Itemkey => ParentItemKey,
2646: aname => 'OWNERID');
2647: ProcOwner := zpb_wf_ntf.ID_to_FNDUser(ProcOwnerID);
2648:
2649: InstanceID := wf_engine.GetItemAttrNumber(Itemtype => ItemType,
2650: Itemkey => ParentItemKey,
2651: aname => 'INSTANCEID');
2701:
2702:
2703: -- **********************************************************
2704: -- make the Ad Hoc role to hold both the dataowner and shadow
2705: if zpb_wf_ntf.has_Shadow(thisOwnerID) = 'Y' then
2706: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID);
2707: select distinct display_name
2708: into NewDispName
2709: from wf_users
2702:
2703: -- **********************************************************
2704: -- make the Ad Hoc role to hold both the dataowner and shadow
2705: if zpb_wf_ntf.has_Shadow(thisOwnerID) = 'Y' then
2706: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID);
2707: select distinct display_name
2708: into NewDispName
2709: from wf_users
2710: where name = thisOwner;
2713: FND_MESSAGE.SET_NAME ('ZPB', 'ZPB_NTF_ANDSHADOWS');
2714: l_label := FND_MESSAGE.GET;
2715: NewDispName := NewDispName || l_label;
2716:
2717: zpb_wf_ntf.SetRole(rolename, relative, NewDispName);
2718: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisOwner);
2719: zpb_wf_ntf.add_Shadow(rolename, thisOwnerID);
2720: else
2721: rolename := thisOwner;
2715: NewDispName := NewDispName || l_label;
2716:
2717: zpb_wf_ntf.SetRole(rolename, relative, NewDispName);
2718: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisOwner);
2719: zpb_wf_ntf.add_Shadow(rolename, thisOwnerID);
2720: else
2721: rolename := thisOwner;
2722: end if;
2723:
2874: from ZPB_TASK_PARAMETERS
2875: where TASK_ID = TaskID and name = 'EXPLANATION_APPROVER';
2876:
2877: if ApproverTYPE = 'AUTHOR_OF_EXCEPTION' then
2878: thisApprover := zpb_wf_ntf.ID_to_fnduser(thisApproverID);
2879: end if;
2880:
2881:
2882: -- create NEWItemKey for FYI workflow
2910: -- explanation recipient
2911: -- make the Ad Hoc role to hold both the dataowner and shadow
2912:
2913:
2914: thisRecipientID := zpb_wf_ntf.fnduser_to_ID(thisRecipient);
2915: if zpb_wf_ntf.has_Shadow(thisRecipientID) = 'Y' then
2916: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID, thisRecipientID);
2917: select distinct display_name
2918: into NewDispName
2911: -- make the Ad Hoc role to hold both the dataowner and shadow
2912:
2913:
2914: thisRecipientID := zpb_wf_ntf.fnduser_to_ID(thisRecipient);
2915: if zpb_wf_ntf.has_Shadow(thisRecipientID) = 'Y' then
2916: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID, thisRecipientID);
2917: select distinct display_name
2918: into NewDispName
2919: from wf_users
2912:
2913:
2914: thisRecipientID := zpb_wf_ntf.fnduser_to_ID(thisRecipient);
2915: if zpb_wf_ntf.has_Shadow(thisRecipientID) = 'Y' then
2916: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID, thisRecipientID);
2917: select distinct display_name
2918: into NewDispName
2919: from wf_users
2920: where name = thisRecipient;
2923: FND_MESSAGE.SET_NAME ('ZPB', 'ZPB_NTF_ANDSHADOWS');
2924: l_label := FND_MESSAGE.GET;
2925: NewDispName := NewDispName || l_label;
2926:
2927: zpb_wf_ntf.SetRole(rolename, relative, NewDispName);
2928: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisRecipient);
2929: zpb_wf_ntf.add_Shadow(rolename, thisRecipientID);
2930: else
2931: rolename := thisRecipient;
2925: NewDispName := NewDispName || l_label;
2926:
2927: zpb_wf_ntf.SetRole(rolename, relative, NewDispName);
2928: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisRecipient);
2929: zpb_wf_ntf.add_Shadow(rolename, thisRecipientID);
2930: else
2931: rolename := thisRecipient;
2932: end if;
2933:
2940:
2941: -- **********************************************************
2942: -- make the Ad Hoc role to hold both the APPROVERS and shadow
2943:
2944: if zpb_wf_ntf.has_Shadow(thisApproverID) = 'Y' then
2945: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID, thisApproverID);
2946: select distinct display_name
2947: into NewDispName
2948: from wf_users
2941: -- **********************************************************
2942: -- make the Ad Hoc role to hold both the APPROVERS and shadow
2943:
2944: if zpb_wf_ntf.has_Shadow(thisApproverID) = 'Y' then
2945: rolename := zpb_wf_ntf.MakeRoleName(InstanceID, TaskID, thisApproverID);
2946: select distinct display_name
2947: into NewDispName
2948: from wf_users
2949: where name = thisApprover;
2952: FND_MESSAGE.SET_NAME ('ZPB', 'ZPB_NTF_ANDSHADOWS');
2953: l_label := FND_MESSAGE.GET;
2954: NewDispName := NewDispName || l_label;
2955:
2956: zpb_wf_ntf.SetRole(rolename, relative, NewDispName);
2957: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisApprover);
2958: zpb_wf_ntf.add_Shadow(rolename, thisApproverID);
2959: else
2960: rolename := thisApprover;
2954: NewDispName := NewDispName || l_label;
2955:
2956: zpb_wf_ntf.SetRole(rolename, relative, NewDispName);
2957: ZPB_UTIL_PVT.AddUsersToAdHocRole(rolename, thisApprover);
2958: zpb_wf_ntf.add_Shadow(rolename, thisApproverID);
2959: else
2960: rolename := thisApprover;
2961: end if;
2962: