15: | - Creates FND User
16: |
17: | REFERENCED APIS
18: | This API calls the following APIs
19: | - FND_USER_PKG.CreatePendingUser
20: +======================================================================*/
21: Procedure Create_User(
22: p_user_name IN VARCHAR2,
23: p_password IN VARCHAR2,
44: --and hz_parties by setting the customer_id column in fnd_user table
45:
46:
47: IF (IBE_UTIL.G_DEBUGON = FND_API.G_TRUE) THEN
48: IBE_UTIL.debug('Call FND_USER_PKG.CreatePendingUser API to create a user');
49: END IF;
50:
51: IF p_password is not null THEN
52:
50:
51: IF p_password is not null THEN
52:
53: IF (IBE_UTIL.G_DEBUGON = FND_API.G_TRUE) THEN
54: IBE_UTIL.debug('Before Call to FND_USER_PKG.CreatePendingUser API: p_password is not null');
55: END IF;
56:
57: x_user_id := FND_USER_PKG.createPendingUser (
58: x_user_name =>p_user_name,
53: IF (IBE_UTIL.G_DEBUGON = FND_API.G_TRUE) THEN
54: IBE_UTIL.debug('Before Call to FND_USER_PKG.CreatePendingUser API: p_password is not null');
55: END IF;
56:
57: x_user_id := FND_USER_PKG.createPendingUser (
58: x_user_name =>p_user_name,
59: x_owner => 'CUST',
60: x_unencrypted_password => p_password,
61: x_password_date => p_password_date,
65:
66: ELSE
67: -- OID record exists; create FND record and relink
68: IF (IBE_UTIL.G_DEBUGON = FND_API.G_TRUE) THEN
69: IBE_UTIL.debug('Before Call to FND_USER_PKG.CreatePendingUser API: p_password is null');
70: END IF;
71:
72: x_user_id := FND_USER_PKG.createPendingUser (
73: x_user_name =>p_user_name,
68: IF (IBE_UTIL.G_DEBUGON = FND_API.G_TRUE) THEN
69: IBE_UTIL.debug('Before Call to FND_USER_PKG.CreatePendingUser API: p_password is null');
70: END IF;
71:
72: x_user_id := FND_USER_PKG.createPendingUser (
73: x_user_name =>p_user_name,
74: x_owner => 'CUST',
75: x_email_address => p_email_address
76: );
84: IBE_UTIL.debug('start_date = '||l_start_date||' : end_date = '||l_end_date);
85: END IF;
86:
87: IF (IBE_UTIL.G_DEBUGON = FND_API.G_TRUE) THEN
88: IBE_UTIL.debug('After Call to FND_USER_PKG.CreatePendingUser API userid :'||x_user_id);
89: IBE_UTIL.debug('Before Call to FND_USER_PKG.updateUser API for updating customer_id');
90: END IF;
91:
92:
85: END IF;
86:
87: IF (IBE_UTIL.G_DEBUGON = FND_API.G_TRUE) THEN
88: IBE_UTIL.debug('After Call to FND_USER_PKG.CreatePendingUser API userid :'||x_user_id);
89: IBE_UTIL.debug('Before Call to FND_USER_PKG.updateUser API for updating customer_id');
90: END IF;
91:
92:
93: FND_USER_PKG.updateUser (
89: IBE_UTIL.debug('Before Call to FND_USER_PKG.updateUser API for updating customer_id');
90: END IF;
91:
92:
93: FND_USER_PKG.updateUser (
94: x_user_name => p_user_name,
95: x_owner => 'CUST',
96: x_customer_id => p_customer_id
97: );
103: IBE_UTIL.debug('start_date = '||l_start_date||' : end_date = '||l_end_date);
104: END IF;
105:
106: IF (IBE_UTIL.G_DEBUGON = FND_API.G_TRUE) THEN
107: IBE_UTIL.debug('After Call to FND_USER_PKG.updateUser API for updating customer_id');
108: END IF;
109:
110:
111: IF (IBE_UTIL.G_DEBUGON = FND_API.G_TRUE) THEN
126: | - Updates FND User
127: |
128: | REFERENCED APIS
129: | This API calls the following APIs
130: | - FND_USER_PKG.UpdateUser
131: +======================================================================*/
132: Procedure Update_User(
133: p_user_name IN VARCHAR2,
134: p_password IN VARCHAR2,
154: l_end_date := p_end_date;
155: end if;
156:
157: IF (IBE_UTIL.G_DEBUGON = FND_API.G_TRUE) THEN
158: IBE_UTIL.debug('Call FND_USER_PKG.UpdateUser API to updated a user');
159: END IF;
160:
161: FND_USER_PKG.UpdateUser (
162: x_user_name => p_user_name,
157: IF (IBE_UTIL.G_DEBUGON = FND_API.G_TRUE) THEN
158: IBE_UTIL.debug('Call FND_USER_PKG.UpdateUser API to updated a user');
159: END IF;
160:
161: FND_USER_PKG.UpdateUser (
162: x_user_name => p_user_name,
163: x_owner => 'CUST',
164: x_unencrypted_password => p_password,
165: x_start_date => p_start_date,
245: | - This API is called for validating the username ion Registration
246: |
247: | REFERENCED APIS
248: | This API calls the following APIs
249: | - FND_USER_PKG.TestUserName
250: +======================================================================*/
251:
252:
253: Function TestUserName(p_user_name in varchar2) return pls_integer
259: Begin
260:
261: IF (IBE_UTIL.G_DEBUGON = FND_API.G_TRUE) THEN
262: IBE_UTIL.debug('enter ibe_user_pvt.TestUserName API');
263: IBE_UTIL.debug('calling fnd_user_pkg.TestUserName API');
264: END IF;
265:
266:
267: begin
265:
266:
267: begin
268: l_block :=
269: 'begin :result := fnd_user_pkg.testUsername(:1); end;';
270: execute immediate l_block using out retval, in p_user_name;
271: exception
272: when others then
273: IF (IBE_UTIL.G_DEBUGON = FND_API.G_TRUE) THEN
270: execute immediate l_block using out retval, in p_user_name;
271: exception
272: when others then
273: IF (IBE_UTIL.G_DEBUGON = FND_API.G_TRUE) THEN
274: IBE_UTIL.debug('fnd_user_pkg.TestUserName API returns '|| retval);
275: END IF;
276: raise;
277: end;
278:
281: IBE_UTIL.debug('Parsing IBE_USER_PVT.testUsername ' );
282:
283: DBMS_SQL.PARSE (cur, 'DECLARE user_name_test_status INTEGER; ' ||
284: ' BEGIN ' ||
285: ' user_name_test_status := fnd_user_pkg.testUsername(:username); ' ||
286: ' :status := user_name_test_status; ' ||
287: ' END;', DBMS_SQL.NATIVE);
288:
289:
302: DBMS_SQL.CLOSE_CURSOR (cur);
303:
304: IBE_UTIL.debug('After calling TestUserName : retval =' || retval);
305:
306: -- retval := FND_USER_PKG.TestUserName(p_user_name);
307: */
308:
309: IF (IBE_UTIL.G_DEBUGON = FND_API.G_TRUE) THEN
310: IBE_UTIL.debug('fnd_user_pkg.TestUserName API returns '|| retval);
306: -- retval := FND_USER_PKG.TestUserName(p_user_name);
307: */
308:
309: IF (IBE_UTIL.G_DEBUGON = FND_API.G_TRUE) THEN
310: IBE_UTIL.debug('fnd_user_pkg.TestUserName API returns '|| retval);
311: IBE_UTIL.debug('exit ibe_user_pvt.TestUserName API');
312: END IF;
313:
314: