[Home] [Help]
10125: -- Needs to be after FND_GLOBAL.APPS_INITIALIZE because
10126: -- user_id, resp_id, and appl_id may be null because
10127: -- the attributes don't exist or because they are not set
10128: if (l_n_org_id is not null) then
10129: mo_global.set_policy_context(p_access_mode => 'S',
10130: p_org_id => l_n_org_id);
10131: end if;
10132:
10133: -- Set Accounting Flexfield validation context
10140: */
10141: l_current_user_id := TO_NUMBER(FND_PROFILE.VALUE('USER_ID'));
10142: l_current_resp_id := TO_NUMBER(FND_PROFILE.VALUE('RESP_ID'));
10143: l_current_resp_appl_id := TO_NUMBER(FND_PROFILE.VALUE('RESP_APPL_ID'));
10144: l_current_org_id := nvl(mo_global.get_current_org_id, -99);
10145:
10146: /* Bug 4711393 : Should return NOTSET instead of FALSE in test_ctx mode
10147: * so that the actual context can get set via call in
10148: * set_ctx mode. This would avoid incorrect deferred state
10146: /* Bug 4711393 : Should return NOTSET instead of FALSE in test_ctx mode
10147: * so that the actual context can get set via call in
10148: * set_ctx mode. This would avoid incorrect deferred state
10149: */
10150: IF (nvl(mo_global.get_access_mode, 'NULL') <> 'S') THEN
10151: p_s_result := 'NOTSET';
10152: ELSIF l_n_user_id IS NULL
10153: OR l_n_resp_id IS NULL
10154: OR l_n_resp_appl_id IS NULL THEN
10392:
10393:
10394: end;
10395: IF (l_n_org_id IS NOT NULL) THEN
10396: mo_global.set_policy_context(p_access_mode => 'S',
10397: p_org_id => l_n_org_id);
10398: END IF;
10399: END IF;
10400: EXCEPTION
13280: sysdate,
13281: p_employee_id,
13282: sysdate,
13283: p_employee_id,
13284: mo_global.get_current_org_id() );
13285: END IF;
13286:
13287: EXCEPTION
13288: WHEN OTHERS THEN