DBA Data[Home] [Help]

APPS.FND_USER_RESP_GROUPS_API dependencies on FND_USER

Line 1: package body Fnd_User_Resp_Groups_api as

1: package body Fnd_User_Resp_Groups_api as
2: /* $Header: AFSCURGB.pls 120.16.12020000.4 2013/03/25 19:50:40 fskinner ship $ */
3:
4: C_PKG_NAME CONSTANT VARCHAR2(30) := 'FND_USER_RESP_GROUPS_API';
5: C_LOG_HEAD CONSTANT VARCHAR2(240)

Line 4: C_PKG_NAME CONSTANT VARCHAR2(30) := 'FND_USER_RESP_GROUPS_API';

1: package body Fnd_User_Resp_Groups_api as
2: /* $Header: AFSCURGB.pls 120.16.12020000.4 2013/03/25 19:50:40 fskinner ship $ */
3:
4: C_PKG_NAME CONSTANT VARCHAR2(30) := 'FND_USER_RESP_GROUPS_API';
5: C_LOG_HEAD CONSTANT VARCHAR2(240)
6: := 'fnd.plsql.FND_USER_RESP_GROUPS_API.';
7:
8: -- This is a one level cache used in check_secgrp_enabled.

Line 6: := 'fnd.plsql.FND_USER_RESP_GROUPS_API.';

2: /* $Header: AFSCURGB.pls 120.16.12020000.4 2013/03/25 19:50:40 fskinner ship $ */
3:
4: C_PKG_NAME CONSTANT VARCHAR2(30) := 'FND_USER_RESP_GROUPS_API';
5: C_LOG_HEAD CONSTANT VARCHAR2(240)
6: := 'fnd.plsql.FND_USER_RESP_GROUPS_API.';
7:
8: -- This is a one level cache used in check_secgrp_enabled.
9: G_ENABLED_RESPID NUMBER := null;
10: G_ENABLED_APPID NUMBER := null;

Line 146: return fnd_user_resp_groups_api.Role_Name_from_Resp(

142: x_secgrp_id in number)
143: return varchar2 is
144: begin
145:
146: return fnd_user_resp_groups_api.Role_Name_from_Resp(
147: x_resp_id,
148: x_resp_appl_id,
149: x_secgrp_id);
150:

Line 167: new_role_name := fnd_user_resp_groups_api.Role_Name_from_Resp(

163: new_role_name varchar2(255);
164: begin
165:
166: begin
167: new_role_name := fnd_user_resp_groups_api.Role_Name_from_Resp(
168: x_resp_id => respid,
169: x_resp_appl_id => appid,
170: x_secgrp_id => 0);
171:

Line 210: Generic_Error('FND_USER_RESP_GROUPS_API.ASSIGNMENT_CHECK(E)',

206: exception
207: when no_data_found then
208: result := FALSE;
209: when others then
210: Generic_Error('FND_USER_RESP_GROUPS_API.ASSIGNMENT_CHECK(E)',
211: sqlcode, sqlerrm);
212: end;
213: elsif (direct_flag = 'D') then
214: begin

Line 227: Generic_Error('FND_USER_RESP_GROUPS_API.ASSIGNMENT_CHECK(D)',

223: exception
224: when no_data_found then
225: result := FALSE;
226: when others then
227: Generic_Error('FND_USER_RESP_GROUPS_API.ASSIGNMENT_CHECK(D)',
228: sqlcode, sqlerrm);
229: end;
230: elsif (direct_flag = 'I') then
231: begin

Line 244: Generic_Error('FND_USER_RESP_GROUPS_API.ASSIGNMENT_CHECK(I)',

240: exception
241: when no_data_found then
242: result := FALSE;
243: when others then
244: Generic_Error('FND_USER_RESP_GROUPS_API.ASSIGNMENT_CHECK(I)',
245: sqlcode, sqlerrm);
246: end;
247: end if;
248: return result;

Line 300: from fnd_user

296:
297: begin
298: select user_name
299: into username
300: from fnd_user
301: where user_id = assignment_exists.user_id;
302:
303: rolename := role_name_from_resp(responsibility_id,
304: responsibility_application_id,

Line 321: Generic_Error('FND_USER_RESP_GROUPS_API.ASSIGNMENT_EXISTS',

317: l_direct_flag);
318:
319: exception
320: when others then
321: Generic_Error('FND_USER_RESP_GROUPS_API.ASSIGNMENT_EXISTS',
322: sqlcode, sqlerrm);
323: end Assignment_Exists;
324:
325:

Line 348: /* objects underlying the fnd_user_resp_groups view, but not needed now.*/

344: x_status out nocopy varchar2)
345: is
346: begin
347: /* # Someday this routine could be reimplemented against the database */
348: /* objects underlying the fnd_user_resp_groups view, but not needed now.*/
349: x_status := 'N';
350:
351: select 'Y'
352: into x_status

Line 356: from fnd_user u,

352: into x_status
353: from dual
354: where exists
355: (select null
356: from fnd_user u,
357: fnd_user_resp_groups urg,
358: fnd_responsibility r
359: where u.user_id = p_user_id
360: and sysdate between u.start_date and nvl(u.end_date, sysdate)

Line 357: fnd_user_resp_groups urg,

353: from dual
354: where exists
355: (select null
356: from fnd_user u,
357: fnd_user_resp_groups urg,
358: fnd_responsibility r
359: where u.user_id = p_user_id
360: and sysdate between u.start_date and nvl(u.end_date, sysdate)
361: and urg.user_id = u.user_id

Line 411: from fnd_user

407: begin
408:
409: select user_name
410: into username
411: from fnd_user
412: where user_id = x_user_id;
413:
414: rolename := role_name_from_resp(x_responsibility_id,
415: x_resp_application_id,

Line 494: from fnd_user

490: ':'||responsibility_id;
491:
492: select user_name
493: into username
494: from fnd_user
495: where user_id = Insert_assignment.user_id;
496:
497:
498: select application_short_name

Line 512: 'FND_USER_RESP_GROUPS_API.Insert_Assignment');

508: fnd_message.set_name('FND', 'FND_CANT_INSERT_USER_ROLE');
509: fnd_message.set_token('USERNAME', username);
510: fnd_message.set_token('ROLENAME', rolename);
511: fnd_message.set_token('ROUTINE',
512: 'FND_USER_RESP_GROUPS_API.Insert_Assignment');
513: app_exception.raise_exception;
514: end if;
515:
516:

Line 528: fnd_user_pkg.user_synch(username);

524: /* Should never happen but be safe in case sync wasn't perfect in past */
525: /* # Should we remove this code and just trust the bulk sync? */
526: if( (l_user_orig_system is NULL)
527: and (l_user_orig_system_id is NULL)) then
528: fnd_user_pkg.user_synch(username);
529: wf_directory.GetRoleOrigSysInfo(username,
530: l_user_orig_system,
531: l_user_orig_system_id);
532: end if;

Line 586: wf_event.addparametertolist(p_name => 'FND_USER_ID',

582: Insert_Assignment.responsibility_id,
583: null, null);
584: --we have to raise a differnt event as for USER_INFO_CACHE
585: --the key should be just the user_id
586: wf_event.addparametertolist(p_name => 'FND_USER_ID',
587: p_value => Insert_Assignment.user_id,
588: p_parameterlist => l_parameters);
589:
590: wf_event.addparametertolist(p_name => 'FND_RESPONSIBILITY_ID',

Line 602: wf_event.raise(p_event_name => 'oracle.apps.fnd.user.role.insert',

598: wf_event.addparametertolist(p_name => 'FND_RESPONSIBILITY_APPS_ID',
599: p_value => Insert_Assignment.responsibility_application_id,
600: p_parameterlist => l_parameters);
601:
602: wf_event.raise(p_event_name => 'oracle.apps.fnd.user.role.insert',
603: p_event_key => to_char(Insert_Assignment.user_id)||':'||to_char(Insert_Assignment.responsibility_id)||':'||appsname||':'||to_char(Insert_Assignment.responsibility_application_id),
604: p_event_data => NULL,
605: p_parameters => l_parameters,
606: p_send_date => Sysdate);

Line 610: Generic_Error('FND_USER_RESP_GROUPS_API.INSERT_ASSIGNMENT',

606: p_send_date => Sysdate);
607:
608: exception
609: when others then
610: Generic_Error('FND_USER_RESP_GROUPS_API.INSERT_ASSIGNMENT',
611: sqlcode, sqlerrm);
612: end Insert_Assignment;
613:
614: --

Line 682: from fnd_user

678: ':'||responsibility_id;
679:
680: select user_name
681: into username
682: from fnd_user
683: where user_id = Update_assignment.user_id;
684:
685:
686: select application_short_name

Line 701: 'FND_USER_RESP_GROUPS_API.Update_Assignment');

697: fnd_message.set_name('FND', 'FND_CANT_UPDATE_USER_ROLE');
698: fnd_message.set_token('USERNAME', username);
699: fnd_message.set_token('ROLENAME', rolename);
700: fnd_message.set_token('ROUTINE',
701: 'FND_USER_RESP_GROUPS_API.Update_Assignment');
702: app_exception.raise_exception;
703: end if;
704:
705: /* We can't just assume that the orig system is FND_USR. It could */

Line 716: fnd_user_pkg.user_synch(username);

712: /* Should never happen but be safe in case sync wasn't perfect in past */
713: /* # Should we remove this code and just trust bulk sync?*/
714: if( (l_user_orig_system is NULL)
715: and (l_user_orig_system_id is NULL)) then
716: fnd_user_pkg.user_synch(username);
717: wf_directory.GetRoleOrigSysInfo(username,
718: l_user_orig_system,
719: l_user_orig_system_id);
720: end if;

Line 821: wf_event.addparametertolist(p_name => 'FND_USER_ID',

817: --subscriptions are attcahed to the wf event.
818: --o.k putting our event (but we need to change the b3664848.ldt
819: --and the event-subscription file to attach this event to the
820: --bes control group.
821: wf_event.addparametertolist(p_name => 'FND_USER_ID',
822: p_value => Update_Assignment.user_id,
823: p_parameterlist => l_parameters);
824:
825: wf_event.addparametertolist(p_name => 'FND_RESPONSIBILITY_ID',

Line 837: wf_event.raise(p_event_name => 'oracle.apps.fnd.user.role.update',

833: wf_event.addparametertolist(p_name => 'FND_RESPONSIBILITY_APPS_ID',
834: p_value => Update_Assignment.responsibility_application_id,
835: p_parameterlist => l_parameters);
836:
837: wf_event.raise(p_event_name => 'oracle.apps.fnd.user.role.update',
838: p_event_key => to_char(Update_Assignment.user_id)||':'||to_char(Update_Assignment.responsibility_id)||':'||appsname||':'||to_char(Update_Assignment.responsibility_application_id),
839: p_event_data => NULL,
840: p_parameters => l_parameters,
841: p_send_date => Sysdate);

Line 845: Generic_Error('FND_USER_RESP_GROUPS_API.UPDATE_ASSIGNMENT',

841: p_send_date => Sysdate);
842:
843: exception
844: when others then
845: Generic_Error('FND_USER_RESP_GROUPS_API.UPDATE_ASSIGNMENT',
846: sqlcode, sqlerrm);
847:
848: end Update_Assignment;
849:

Line 873: from fnd_user

869: old_rolename varchar2(4000);
870:
871: begin
872: select user_id into u_id
873: from fnd_user
874: where user_name = X_USER_NAME;
875:
876: select application_id into app_id
877: from fnd_application

Line 900: fnd_user_resp_groups_api.UPLOAD_ASSIGNMENT(

896: -- bug3649874 Modified to use fnd_load_util to get the owner_id
897:
898: l_owner := fnd_load_util.owner_id(X_OWNER);
899:
900: fnd_user_resp_groups_api.UPLOAD_ASSIGNMENT(
901: USER_ID => u_id,
902: RESPONSIBILITY_ID => resp_id,
903: RESPONSIBILITY_APPLICATION_ID => app_id,
904: SECURITY_GROUP_ID => sgroup_id,

Line 1018: if (Fnd_User_Resp_Groups_Api.Assignment_Exists(

1014: else
1015: sgid := security_group_id;
1016: end if;
1017:
1018: if (Fnd_User_Resp_Groups_Api.Assignment_Exists(
1019: Upload_Assignment.user_id,
1020: Upload_Assignment.responsibility_id,
1021: Upload_Assignment.responsibility_application_id,
1022: Upload_Assignment.sgid,

Line 1025: Fnd_User_Resp_Groups_Api.Update_Assignment(

1021: Upload_Assignment.responsibility_application_id,
1022: Upload_Assignment.sgid,
1023: 'D'))
1024: then
1025: Fnd_User_Resp_Groups_Api.Update_Assignment(
1026: Upload_Assignment.user_id,
1027: Upload_Assignment.responsibility_id,
1028: Upload_Assignment.responsibility_application_id,
1029: Upload_Assignment.sgid,

Line 1035: Fnd_User_Resp_Groups_Api.Insert_Assignment(

1031: Upload_Assignment.end_date,
1032: Upload_Assignment.description,
1033: update_who_columns);
1034: else
1035: Fnd_User_Resp_Groups_Api.Insert_Assignment(
1036: Upload_Assignment.user_id,
1037: Upload_Assignment.responsibility_id,
1038: Upload_Assignment.responsibility_application_id,
1039: Upload_Assignment.sgid,

Line 1046: Generic_Error('FND_USER_RESP_GROUPS_API.UPLOAD_ASSIGNMENT',

1042: Upload_Assignment.description);
1043: end if;
1044: exception
1045: when others then
1046: Generic_Error('FND_USER_RESP_GROUPS_API.UPLOAD_ASSIGNMENT',
1047: sqlcode, sqlerrm);
1048: end Upload_Assignment;
1049:
1050: --

Line 1129: role_name := fnd_user_resp_groups_api.role_name_from_resp_name(

1125: into applsname
1126: from fnd_application
1127: where application_id = appid;
1128:
1129: role_name := fnd_user_resp_groups_api.role_name_from_resp_name(
1130: respkey, applsname, secgrpkey);
1131:
1132: exception
1133: when no_data_found then

Line 1430: -- Moves old data from fnd_user_resp_groups table to new workflow tables.

1426: end sync_roles_all_resp_secgrps;
1427:
1428:
1429: --
1430: -- Moves old data from fnd_user_resp_groups table to new workflow tables.
1431: -- This routine is exposed so that it can be called from a one time
1432: -- upgrade script, and it should never need to be run after that.
1433: -- Running it unnecessarily might invalidate work that
1434: -- admins have done to split assignments out into roles

Line 1467: from fnd_user_resp_groups_old furgo,

1463: furgo.creation_date,
1464: furgo.last_updated_by,
1465: furgo.last_update_date,
1466: furgo.last_update_login
1467: from fnd_user_resp_groups_old furgo,
1468: fnd_user fu,
1469: fnd_application app,
1470: fnd_responsibility resp,
1471: fnd_security_groups secgrp

Line 1468: fnd_user fu,

1464: furgo.last_updated_by,
1465: furgo.last_update_date,
1466: furgo.last_update_login
1467: from fnd_user_resp_groups_old furgo,
1468: fnd_user fu,
1469: fnd_application app,
1470: fnd_responsibility resp,
1471: fnd_security_groups secgrp
1472: where furgo.user_id = fu.user_id

Line 1522: fnd_user_resp_groups_api.sync_roles_one_resp_secgrp(

1518: fnd_log.string(FND_LOG.LEVEL_STATEMENT,
1519: c_log_head || l_api_name || '.need_to_create_role',
1520: 'Creating role:'|| rolename);
1521: end if;
1522: fnd_user_resp_groups_api.sync_roles_one_resp_secgrp(
1523: rowrec.responsibility_id,
1524: rowrec.responsibility_application_id,
1525: rowrec.responsibility_key,
1526: rowrec.security_group_id,

Line 1569: fnd_user_pkg.user_synch(rowrec.user_name);

1565: c_log_head || l_api_name || '.orig_notfound',
1566: 'Orig system and id not found. Trying to sync user:'||
1567: rowrec.user_name);
1568: end if;
1569: fnd_user_pkg.user_synch(rowrec.user_name);
1570: wf_directory.GetRoleOrigSysInfo(rowrec.user_name,
1571: l_user_orig_system,
1572: l_user_orig_system_id);
1573: end if;

Line 1712: end Fnd_User_Resp_Groups_Api;

1708:
1709: end sync_roles_all_secgrps_int;
1710:
1711:
1712: end Fnd_User_Resp_Groups_Api;