260: l_person_party_id number;
261:
262: BEGIN
263:
264: x_return_status := fnd_api.g_ret_sts_success;
265: savepoint cr_emp_wf_save;
266:
267: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
268: RAISE fnd_api.g_exc_unexpected_error;
263:
264: x_return_status := fnd_api.g_ret_sts_success;
265: savepoint cr_emp_wf_save;
266:
267: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
268: RAISE fnd_api.g_exc_unexpected_error;
269: END IF;
270:
271: --Initialize the message List if P_INIT_MSG_LIST is set to TRUE
264: x_return_status := fnd_api.g_ret_sts_success;
265: savepoint cr_emp_wf_save;
266:
267: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
268: RAISE fnd_api.g_exc_unexpected_error;
269: END IF;
270:
271: --Initialize the message List if P_INIT_MSG_LIST is set to TRUE
272: if p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list)
268: RAISE fnd_api.g_exc_unexpected_error;
269: END IF;
270:
271: --Initialize the message List if P_INIT_MSG_LIST is set to TRUE
272: if p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list)
273: then
274: fnd_msg_pub.Initialize;
275: end if;
276:
326:
327: end if; /* End of - If the resource is not an EMPLOYEE, PARTY, PARTNER or SUPPLIER_CONTACT */
328: -- end if; /* End of - If the resource is not attached to an fnd user */
329:
330: IF p_commit is not NULL and fnd_api.to_boolean(p_commit) THEN
331: COMMIT WORK;
332: END IF;
333:
334: EXCEPTION when OTHERS then
332: END IF;
333:
334: EXCEPTION when OTHERS then
335: ROLLBACK TO cr_emp_wf_save;
336: x_return_status := fnd_api.g_ret_sts_unexp_error;
337: END create_resource;
338:
339: PROCEDURE update_resource
340: (P_API_VERSION IN NUMBER,
715: END move_wf_user_role;
716:
717: BEGIN
718:
719: x_return_status := fnd_api.g_ret_sts_success;
720: savepoint upd_emp_wf_save;
721:
722: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
723: RAISE fnd_api.g_exc_unexpected_error;
718:
719: x_return_status := fnd_api.g_ret_sts_success;
720: savepoint upd_emp_wf_save;
721:
722: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
723: RAISE fnd_api.g_exc_unexpected_error;
724: END IF;
725:
726: --Initialize the message List if P_INIT_MSG_LIST is set to TRUE
719: x_return_status := fnd_api.g_ret_sts_success;
720: savepoint upd_emp_wf_save;
721:
722: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
723: RAISE fnd_api.g_exc_unexpected_error;
724: END IF;
725:
726: --Initialize the message List if P_INIT_MSG_LIST is set to TRUE
727: if p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list)
723: RAISE fnd_api.g_exc_unexpected_error;
724: END IF;
725:
726: --Initialize the message List if P_INIT_MSG_LIST is set to TRUE
727: if p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list)
728: then
729: fnd_msg_pub.Initialize;
730: end if;
731:
737: ((res_rec.source_email is NULL) AND (p_email_address is NOT NULL)) OR
738: ((res_rec.source_email is NOT NULL) AND (p_email_address is NULL)) OR
739: -- (nvl(res_rec.user_id,-9999) <> nvl(p_user_id,-9999)) OR
740: (res_rec.resource_name <> p_resource_name) OR
741: (nvl(res_rec.end_date_active,fnd_api.g_miss_date) <> nvl(l_end_date_active,fnd_api.g_miss_date)) OR
742: (res_rec.start_date_active <> l_start_date_active) )
743: AND
744: ( (nvl(res_rec.end_date_active,l_sysdate) >= l_sysdate) OR
745: (nvl(l_end_date_active,l_sysdate) >= l_sysdate) )
1029: end if; /* there are some changes and not a future to future updation */
1030:
1031: CLOSE res_cur;
1032:
1033: IF p_commit is not NULL and fnd_api.to_boolean(p_commit) THEN
1034: COMMIT WORK;
1035: END IF;
1036:
1037: EXCEPTION when OTHERS then
1035: END IF;
1036:
1037: EXCEPTION when OTHERS then
1038: ROLLBACK TO upd_emp_wf_save;
1039: x_return_status := fnd_api.g_ret_sts_unexp_error;
1040:
1041: END update_resource;
1042:
1043: PROCEDURE delete_resource
1069: l_list WF_PARAMETER_LIST_T;
1070:
1071: BEGIN
1072:
1073: x_return_status := fnd_api.g_ret_sts_success;
1074: savepoint del_emp_wf_save;
1075:
1076: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1077: RAISE fnd_api.g_exc_unexpected_error;
1072:
1073: x_return_status := fnd_api.g_ret_sts_success;
1074: savepoint del_emp_wf_save;
1075:
1076: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1077: RAISE fnd_api.g_exc_unexpected_error;
1078: END IF;
1079:
1080: --Initialize the message List if P_INIT_MSG_LIST is set to TRUE
1073: x_return_status := fnd_api.g_ret_sts_success;
1074: savepoint del_emp_wf_save;
1075:
1076: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1077: RAISE fnd_api.g_exc_unexpected_error;
1078: END IF;
1079:
1080: --Initialize the message List if P_INIT_MSG_LIST is set to TRUE
1081: if p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list)
1077: RAISE fnd_api.g_exc_unexpected_error;
1078: END IF;
1079:
1080: --Initialize the message List if P_INIT_MSG_LIST is set to TRUE
1081: if p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list)
1082: then
1083: fnd_msg_pub.Initialize;
1084: end if;
1085:
1107: p_expiration_date => l_sysdate-1);
1108:
1109: l_list.DELETE;
1110:
1111: IF p_commit is not NULL and fnd_api.to_boolean(p_commit) THEN
1112: COMMIT WORK;
1113: END IF;
1114:
1115: EXCEPTION when OTHERS then
1113: END IF;
1114:
1115: EXCEPTION when OTHERS then
1116: ROLLBACK TO del_emp_wf_save;
1117: x_return_status := fnd_api.g_ret_sts_unexp_error;
1118: END delete_resource;
1119:
1120: PROCEDURE create_resource_group
1121: (P_API_VERSION IN NUMBER,
1140: l_list WF_PARAMETER_LIST_T;
1141:
1142: BEGIN
1143: SAVEPOINT wf_int_create_resource_group;
1144: x_return_status := fnd_api.g_ret_sts_success;
1145:
1146: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1147: RAISE fnd_api.g_exc_unexpected_error;
1148: END IF;
1142: BEGIN
1143: SAVEPOINT wf_int_create_resource_group;
1144: x_return_status := fnd_api.g_ret_sts_success;
1145:
1146: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1147: RAISE fnd_api.g_exc_unexpected_error;
1148: END IF;
1149: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
1150: fnd_msg_pub.initialize;
1143: SAVEPOINT wf_int_create_resource_group;
1144: x_return_status := fnd_api.g_ret_sts_success;
1145:
1146: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1147: RAISE fnd_api.g_exc_unexpected_error;
1148: END IF;
1149: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
1150: fnd_msg_pub.initialize;
1151: END IF;
1145:
1146: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1147: RAISE fnd_api.g_exc_unexpected_error;
1148: END IF;
1149: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
1150: fnd_msg_pub.initialize;
1151: END IF;
1152:
1153: -- if (l_start_date_active <= l_sysdate AND
1183: p_expiration_date => l_end_date_active);
1184:
1185: END IF;
1186:
1187: IF p_commit is not NULL and fnd_api.to_boolean(p_commit) THEN
1188: COMMIT WORK;
1189: END IF;
1190:
1191: EXCEPTION
1196: -- DBMS_OUTPUT.put_line (' =========== Raised Others in Create Resource Group Pvt ========= ');
1197: -- DBMS_OUTPUT.put_line (SQLCODE || SQLERRM);
1198:
1199: ROLLBACK TO wf_int_create_resource_group;
1200: x_return_status := fnd_api.g_ret_sts_unexp_error;
1201: fnd_msg_pub.count_and_get (p_count => x_msg_count, p_data => x_msg_data);
1202: END;
1203:
1204:
1269: l_list WF_PARAMETER_LIST_T;
1270:
1271: BEGIN
1272: SAVEPOINT wf_int_update_resource_group;
1273: x_return_status := fnd_api.g_ret_sts_success;
1274:
1275: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1276: RAISE fnd_api.g_exc_unexpected_error;
1277: END IF;
1271: BEGIN
1272: SAVEPOINT wf_int_update_resource_group;
1273: x_return_status := fnd_api.g_ret_sts_success;
1274:
1275: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1276: RAISE fnd_api.g_exc_unexpected_error;
1277: END IF;
1278: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
1279: fnd_msg_pub.initialize;
1272: SAVEPOINT wf_int_update_resource_group;
1273: x_return_status := fnd_api.g_ret_sts_success;
1274:
1275: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1276: RAISE fnd_api.g_exc_unexpected_error;
1277: END IF;
1278: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
1279: fnd_msg_pub.initialize;
1280: END IF;
1274:
1275: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1276: RAISE fnd_api.g_exc_unexpected_error;
1277: END IF;
1278: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
1279: fnd_msg_pub.initialize;
1280: END IF;
1281:
1282: /* Role record exists then update if group name, email, start date
1417: IF c_role_exists%ISOPEN THEN
1418: CLOSE c_role_exists;
1419: END IF;
1420:
1421: IF p_commit is not NULL and fnd_api.to_boolean(p_commit) THEN
1422: COMMIT WORK;
1423: END IF;
1424:
1425: EXCEPTION
1438: CLOSE c_role_exists;
1439: END IF;
1440:
1441: ROLLBACK TO wf_int_update_resource_group;
1442: x_return_status := fnd_api.g_ret_sts_unexp_error;
1443: fnd_msg_pub.count_and_get (p_count => x_msg_count, p_data => x_msg_data);
1444: END;
1445:
1446:
1495: l_g_miss_date date := trunc(to_date('31-12-4712','DD-MM-YYYY'));
1496:
1497: BEGIN
1498: SAVEPOINT wf_int_cr_res_grp_mbr;
1499: x_return_status := fnd_api.g_ret_sts_success;
1500:
1501: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1502: RAISE fnd_api.g_exc_unexpected_error;
1503: END IF;
1497: BEGIN
1498: SAVEPOINT wf_int_cr_res_grp_mbr;
1499: x_return_status := fnd_api.g_ret_sts_success;
1500:
1501: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1502: RAISE fnd_api.g_exc_unexpected_error;
1503: END IF;
1504: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
1505: fnd_msg_pub.initialize;
1498: SAVEPOINT wf_int_cr_res_grp_mbr;
1499: x_return_status := fnd_api.g_ret_sts_success;
1500:
1501: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1502: RAISE fnd_api.g_exc_unexpected_error;
1503: END IF;
1504: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
1505: fnd_msg_pub.initialize;
1506: END IF;
1500:
1501: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1502: RAISE fnd_api.g_exc_unexpected_error;
1503: END IF;
1504: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
1505: fnd_msg_pub.initialize;
1506: END IF;
1507:
1508: OPEN c_grp_active(p_group_id);
1555: END IF;
1556:
1557: CLOSE c_grp_active;
1558:
1559: IF p_commit is not NULL and fnd_api.to_boolean(p_commit) THEN
1560: COMMIT WORK;
1561: END IF;
1562:
1563: EXCEPTION
1580: CLOSE c_res_active;
1581: END IF;
1582:
1583: ROLLBACK TO wf_int_cr_res_grp_mbr;
1584: x_return_status := fnd_api.g_ret_sts_unexp_error;
1585: fnd_msg_pub.count_and_get (p_count => x_msg_count, p_data => x_msg_data);
1586: END;
1587:
1588: PROCEDURE delete_resource_group_members
1603: l_orig_system wf_local_roles.orig_system%TYPE;
1604: l_orig_system_id wf_local_roles.orig_system_id%TYPE;
1605: BEGIN
1606: SAVEPOINT wf_int_del_res_grp_mbr;
1607: x_return_status := fnd_api.g_ret_sts_success;
1608:
1609: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1610: RAISE fnd_api.g_exc_unexpected_error;
1611: END IF;
1605: BEGIN
1606: SAVEPOINT wf_int_del_res_grp_mbr;
1607: x_return_status := fnd_api.g_ret_sts_success;
1608:
1609: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1610: RAISE fnd_api.g_exc_unexpected_error;
1611: END IF;
1612: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
1613: fnd_msg_pub.initialize;
1606: SAVEPOINT wf_int_del_res_grp_mbr;
1607: x_return_status := fnd_api.g_ret_sts_success;
1608:
1609: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1610: RAISE fnd_api.g_exc_unexpected_error;
1611: END IF;
1612: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
1613: fnd_msg_pub.initialize;
1614: END IF;
1608:
1609: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1610: RAISE fnd_api.g_exc_unexpected_error;
1611: END IF;
1612: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
1613: fnd_msg_pub.initialize;
1614: END IF;
1615:
1616: jtf_rs_wf_integration_pub.get_wf_role(P_RESOURCE_ID => P_RESOURCE_ID,
1632: p_expiration_date => sysdate-1);
1633: END IF;
1634:
1635:
1636: IF p_commit is not NULL and fnd_api.to_boolean(p_commit) THEN
1637: COMMIT WORK;
1638: END IF;
1639:
1640: EXCEPTION
1645: -- DBMS_OUTPUT.put_line (' =========== Raised Others in Delete Resource Group Member Pvt ========= ');
1646: -- DBMS_OUTPUT.put_line (SQLCODE || SQLERRM);
1647:
1648: ROLLBACK TO wf_int_del_res_grp_mbr;
1649: x_return_status := fnd_api.g_ret_sts_unexp_error;
1650: fnd_msg_pub.count_and_get (p_count => x_msg_count, p_data => x_msg_data);
1651: END;
1652:
1653: PROCEDURE create_resource_team
1673: l_list WF_PARAMETER_LIST_T;
1674:
1675: BEGIN
1676: SAVEPOINT wf_int_create_resource_team;
1677: x_return_status := fnd_api.g_ret_sts_success;
1678:
1679: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name,
1680: g_pkg_name) THEN
1681: RAISE fnd_api.g_exc_unexpected_error;
1675: BEGIN
1676: SAVEPOINT wf_int_create_resource_team;
1677: x_return_status := fnd_api.g_ret_sts_success;
1678:
1679: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name,
1680: g_pkg_name) THEN
1681: RAISE fnd_api.g_exc_unexpected_error;
1682: END IF;
1683: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
1677: x_return_status := fnd_api.g_ret_sts_success;
1678:
1679: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name,
1680: g_pkg_name) THEN
1681: RAISE fnd_api.g_exc_unexpected_error;
1682: END IF;
1683: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
1684: fnd_msg_pub.initialize;
1685: END IF;
1679: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name,
1680: g_pkg_name) THEN
1681: RAISE fnd_api.g_exc_unexpected_error;
1682: END IF;
1683: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
1684: fnd_msg_pub.initialize;
1685: END IF;
1686:
1687: -- if (l_start_date_active <= l_sysdate AND
1715: p_start_date => l_start_date_active,
1716: p_expiration_date => l_end_date_active);
1717: END IF;
1718:
1719: IF p_commit is not NULL and fnd_api.to_boolean(p_commit) THEN
1720: COMMIT WORK;
1721: END IF;
1722:
1723: EXCEPTION
1728: -- DBMS_OUTPUT.put_line (' =========== Raised Others in Create Resource Team Pvt ========= ');
1729: -- DBMS_OUTPUT.put_line (SQLCODE || SQLERRM);
1730:
1731: ROLLBACK TO wf_int_create_resource_team;
1732: x_return_status := fnd_api.g_ret_sts_unexp_error;
1733: fnd_msg_pub.count_and_get (p_count => x_msg_count, p_data => x_msg_data);
1734: END;
1735:
1736: PROCEDURE update_resource_team
1799: l_list WF_PARAMETER_LIST_T;
1800:
1801: BEGIN
1802: SAVEPOINT wf_int_update_resource_team;
1803: x_return_status := fnd_api.g_ret_sts_success;
1804:
1805: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1806: RAISE fnd_api.g_exc_unexpected_error;
1807: END IF;
1801: BEGIN
1802: SAVEPOINT wf_int_update_resource_team;
1803: x_return_status := fnd_api.g_ret_sts_success;
1804:
1805: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1806: RAISE fnd_api.g_exc_unexpected_error;
1807: END IF;
1808: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
1809: fnd_msg_pub.initialize;
1802: SAVEPOINT wf_int_update_resource_team;
1803: x_return_status := fnd_api.g_ret_sts_success;
1804:
1805: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1806: RAISE fnd_api.g_exc_unexpected_error;
1807: END IF;
1808: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
1809: fnd_msg_pub.initialize;
1810: END IF;
1804:
1805: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1806: RAISE fnd_api.g_exc_unexpected_error;
1807: END IF;
1808: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
1809: fnd_msg_pub.initialize;
1810: END IF;
1811:
1812: /* Role record exists then update if team name, email, start date
1940: IF c_role_exists%ISOPEN THEN
1941: CLOSE c_role_exists;
1942: END IF;
1943:
1944: IF p_commit is not NULL and fnd_api.to_boolean(p_commit) THEN
1945: COMMIT WORK;
1946: END IF;
1947:
1948: EXCEPTION
1961: CLOSE c_role_exists;
1962: END IF;
1963:
1964: ROLLBACK TO wf_int_update_resource_team;
1965: x_return_status := fnd_api.g_ret_sts_unexp_error;
1966: fnd_msg_pub.count_and_get (p_count => x_msg_count, p_data => x_msg_data);
1967: END;
1968:
1969: PROCEDURE create_resource_team_members
2027: l_g_miss_date date := trunc(to_date('31-12-4712','DD-MM-YYYY'));
2028:
2029: BEGIN
2030: SAVEPOINT wf_int_cr_res_team_mbr;
2031: x_return_status := fnd_api.g_ret_sts_success;
2032:
2033: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
2034: RAISE fnd_api.g_exc_unexpected_error;
2035: END IF;
2029: BEGIN
2030: SAVEPOINT wf_int_cr_res_team_mbr;
2031: x_return_status := fnd_api.g_ret_sts_success;
2032:
2033: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
2034: RAISE fnd_api.g_exc_unexpected_error;
2035: END IF;
2036: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
2037: fnd_msg_pub.initialize;
2030: SAVEPOINT wf_int_cr_res_team_mbr;
2031: x_return_status := fnd_api.g_ret_sts_success;
2032:
2033: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
2034: RAISE fnd_api.g_exc_unexpected_error;
2035: END IF;
2036: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
2037: fnd_msg_pub.initialize;
2038: END IF;
2032:
2033: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
2034: RAISE fnd_api.g_exc_unexpected_error;
2035: END IF;
2036: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
2037: fnd_msg_pub.initialize;
2038: END IF;
2039:
2040: OPEN c_team_active(p_team_id);
2135: END IF;
2136:
2137: CLOSE c_team_active;
2138:
2139: IF p_commit is not NULL and fnd_api.to_boolean(p_commit) THEN
2140: COMMIT WORK;
2141: END IF;
2142:
2143: EXCEPTION
2164: CLOSE c_res_active;
2165: END IF;
2166:
2167: ROLLBACK TO wf_int_cr_res_team_mbr;
2168: x_return_status := fnd_api.g_ret_sts_unexp_error;
2169: fnd_msg_pub.count_and_get (p_count => x_msg_count, p_data => x_msg_data);
2170: END;
2171:
2172:
2189: l_orig_system wf_local_roles.orig_system%TYPE;
2190: l_orig_system_id wf_local_roles.orig_system_id%TYPE;
2191: BEGIN
2192: SAVEPOINT wf_int_del_res_team_mbr;
2193: x_return_status := fnd_api.g_ret_sts_success;
2194:
2195: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name,
2196: g_pkg_name) THEN
2197: RAISE fnd_api.g_exc_unexpected_error;
2191: BEGIN
2192: SAVEPOINT wf_int_del_res_team_mbr;
2193: x_return_status := fnd_api.g_ret_sts_success;
2194:
2195: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name,
2196: g_pkg_name) THEN
2197: RAISE fnd_api.g_exc_unexpected_error;
2198: END IF;
2199: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
2193: x_return_status := fnd_api.g_ret_sts_success;
2194:
2195: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name,
2196: g_pkg_name) THEN
2197: RAISE fnd_api.g_exc_unexpected_error;
2198: END IF;
2199: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
2200: fnd_msg_pub.initialize;
2201: END IF;
2195: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name,
2196: g_pkg_name) THEN
2197: RAISE fnd_api.g_exc_unexpected_error;
2198: END IF;
2199: IF p_init_msg_list is not NULL and fnd_api.to_boolean(p_init_msg_list) THEN
2200: fnd_msg_pub.initialize;
2201: END IF;
2202:
2203: IF (P_RESOURCE_ID is not null) THEN
2231: p_expiration_date => sysdate-1);
2232: END IF;
2233:
2234:
2235: IF p_commit is not NULL and fnd_api.to_boolean(p_commit) THEN
2236: COMMIT WORK;
2237: END IF;
2238:
2239: EXCEPTION
2244: -- DBMS_OUTPUT.put_line (' =========== Raised Others in Delete Resource Team Member Pvt ========= ');
2245: -- DBMS_OUTPUT.put_line (SQLCODE || SQLERRM);
2246:
2247: ROLLBACK TO wf_int_del_res_team_mbr;
2248: x_return_status := fnd_api.g_ret_sts_unexp_error;
2249: fnd_msg_pub.count_and_get (p_count => x_msg_count, p_data => x_msg_data);
2250: END;
2251:
2252: END jtf_rs_wf_integration_pub;