DBA Data[Home] [Help]

APPS.IGW_PROPOSAL_APPROVAL dependencies on FND_API

Line 5: p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE,

1: package body igw_proposal_approval as
2: --$Header: igwprapb.pls 115.21 2002/11/14 18:50:23 vmedikon ship $
3:
4: Procedure start_approval_process (
5: p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE,
6: p_commit IN VARCHAR2 := FND_API.G_FALSE,
7: p_validate_only IN VARCHAR2 := FND_API.G_FALSE,
8: p_proposal_id IN NUMBER,
9: x_return_status OUT NOCOPY VARCHAR2,

Line 6: p_commit IN VARCHAR2 := FND_API.G_FALSE,

2: --$Header: igwprapb.pls 115.21 2002/11/14 18:50:23 vmedikon ship $
3:
4: Procedure start_approval_process (
5: p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE,
6: p_commit IN VARCHAR2 := FND_API.G_FALSE,
7: p_validate_only IN VARCHAR2 := FND_API.G_FALSE,
8: p_proposal_id IN NUMBER,
9: x_return_status OUT NOCOPY VARCHAR2,
10: x_msg_count OUT NOCOPY NUMBER,

Line 7: p_validate_only IN VARCHAR2 := FND_API.G_FALSE,

3:
4: Procedure start_approval_process (
5: p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE,
6: p_commit IN VARCHAR2 := FND_API.G_FALSE,
7: p_validate_only IN VARCHAR2 := FND_API.G_FALSE,
8: p_proposal_id IN NUMBER,
9: x_return_status OUT NOCOPY VARCHAR2,
10: x_msg_count OUT NOCOPY NUMBER,
11: x_msg_data OUT NOCOPY VARCHAR2) is

Line 26: IF p_commit = FND_API.G_TRUE THEN

22: l_message_name VARCHAR2(200);
23:
24: BEGIN
25: -- create savepoint if p_commit is true
26: IF p_commit = FND_API.G_TRUE THEN
27: SAVEPOINT start_approval;
28: END IF;
29:
30: -- initialize message list if p_init_msg_list is true

Line 31: if FND_API.to_boolean(nvl(p_init_msg_list, FND_API.G_FALSE)) then

27: SAVEPOINT start_approval;
28: END IF;
29:
30: -- initialize message list if p_init_msg_list is true
31: if FND_API.to_boolean(nvl(p_init_msg_list, FND_API.G_FALSE)) then
32: fnd_msg_pub.initialize;
33: end if;
34:
35: -- initialize return_status to success

Line 36: x_return_status := fnd_api.g_ret_sts_success;

32: fnd_msg_pub.initialize;
33: end if;
34:
35: -- initialize return_status to success
36: x_return_status := fnd_api.g_ret_sts_success;
37:
38: /* -- Debashis. We don't validate anymore.
39: -- first validate user rights
40:

Line 52: if (NOT FND_API.TO_BOOLEAN (p_validate_only)) then

48: ------------------------------------- value_id conversion ---------------------------------
49:
50: -------------------------------------------- validations -----------------------------------------------------
51: -- dbms_output.put_line('before call to start approval');
52: if (NOT FND_API.TO_BOOLEAN (p_validate_only)) then
53: start_approval (
54: p_proposal_id => p_proposal_id
55: ,p_error_message => l_msg_data
56: ,p_return_status => l_return_status);

Line 73: raise fnd_api.g_exc_error;

69: -- dbms_output.put_line(l_message_name);
70:
71: -- fnd_message.set_name(l_short_name, l_message_name);
72: -- fnd_msg_pub.add;
73: raise fnd_api.g_exc_error;
74: elsif (l_return_status = 'U') then
75: fnd_msg_pub.initialize;
76: fnd_message.parse_encoded(encoded_message => l_msg_data,
77: app_short_name => l_short_name,

Line 84: raise fnd_api.g_exc_unexpected_error;

80: -- dbms_output.put_line(l_message_name);
81:
82: -- fnd_message.set_name('l_short_name', l_message_name);
83: -- fnd_msg_pub.add;
84: raise fnd_api.g_exc_unexpected_error;
85: elsif (l_return_status = 'S') then
86: update igw_proposals_all set proposal_status = 'I' where proposal_id = p_proposal_id;
87: end if;
88: */

Line 92: if fnd_api.to_boolean(p_commit) then

88: */
89:
90: update igw_proposals_all set proposal_status = 'I' where proposal_id = p_proposal_id;
91: -- standard check of p_commit
92: if fnd_api.to_boolean(p_commit) then
93: commit work;
94: end if;
95:
96: -- set x_msg_count and x_msg_data

Line 102: WHEN FND_API.G_EXC_ERROR THEN

98: x_msg_data := 'Proposal Submitted for Approval';
99:
100:
101: EXCEPTION
102: WHEN FND_API.G_EXC_ERROR THEN
103: IF p_commit = FND_API.G_TRUE THEN
104: ROLLBACK TO start_approval;
105: END IF;
106:

Line 103: IF p_commit = FND_API.G_TRUE THEN

99:
100:
101: EXCEPTION
102: WHEN FND_API.G_EXC_ERROR THEN
103: IF p_commit = FND_API.G_TRUE THEN
104: ROLLBACK TO start_approval;
105: END IF;
106:
107: x_return_status := FND_API.G_RET_STS_ERROR;

Line 107: x_return_status := FND_API.G_RET_STS_ERROR;

103: IF p_commit = FND_API.G_TRUE THEN
104: ROLLBACK TO start_approval;
105: END IF;
106:
107: x_return_status := FND_API.G_RET_STS_ERROR;
108:
109: fnd_msg_pub.count_and_get(p_count => x_msg_count,
110: p_data => x_msg_data);
111:

Line 115: IF p_commit = FND_API.G_TRUE THEN

111:
112:
113:
114: WHEN OTHERS THEN
115: IF p_commit = FND_API.G_TRUE THEN
116: ROLLBACK TO start_approval;
117: END IF;
118:
119: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

Line 119: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

115: IF p_commit = FND_API.G_TRUE THEN
116: ROLLBACK TO start_approval;
117: END IF;
118:
119: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
120:
121: fnd_msg_pub.add_exc_msg(p_pkg_name => 'IGW_PROPOSAL_APPROVAL',
122: p_procedure_name => 'START_APPROVAL_PROCESS',
123: p_error_text => SUBSTRB(SQLERRM,1,240));

Line 141: x_return_status:= FND_API.G_RET_STS_SUCCESS;

137: x VARCHAR2(1);
138: y VARCHAR2(1);
139:
140: BEGIN
141: x_return_status:= FND_API.G_RET_STS_SUCCESS;
142:
143: select x into y
144: from igw_prop_user_roles ppr,
145: igw_prop_users ppu

Line 157: x_return_status:= FND_API.G_RET_STS_ERROR;

153:
154: EXCEPTION
155:
156: WHEN NO_DATA_FOUND THEN
157: x_return_status:= FND_API.G_RET_STS_ERROR;
158: fnd_message.set_name('IGW', 'IGW_NO_RIGHTS');
159: fnd_msg_pub.add;
160: raise;
161: WHEN too_many_rows THEN

Line 165: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

161: WHEN too_many_rows THEN
162: NULL;
163:
164: WHEN OTHERS THEN
165: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
166: fnd_msg_pub.add_exc_msg(p_pkg_name => 'IGW_PROPOSAL_APPROVAL',
167: p_procedure_name => 'VALIDATE_LOGGED_USER_RIGHTS',
168: p_error_text => SUBSTRB(SQLERRM,1,240));
169: raise fnd_api.g_exc_unexpected_error;

Line 169: raise fnd_api.g_exc_unexpected_error;

165: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
166: fnd_msg_pub.add_exc_msg(p_pkg_name => 'IGW_PROPOSAL_APPROVAL',
167: p_procedure_name => 'VALIDATE_LOGGED_USER_RIGHTS',
168: p_error_text => SUBSTRB(SQLERRM,1,240));
169: raise fnd_api.g_exc_unexpected_error;
170: END VALIDATE_LOGGED_USER_RIGHTS;
171:
172:
173: ----------- procedure start_approval ------------------------------

Line 227: raise fnd_api.g_exc_error;

223: fnd_message.set_name('IGW','IGW_ROUT_PR_OWNER_CAN_SUBMIT');
224: fnd_msg_pub.add; -- Debashis
225: p_error_message := fnd_message.get_encoded;
226: p_return_status := 'E';
227: raise fnd_api.g_exc_error;
228: -- return;
229:
230: end if;
231: ----------------------------------------------------------

Line 261: raise fnd_api.g_exc_error;

257: fnd_message.set_name('IGW','IGW_ROUT_IPR_CANNOT_SUBMIT');
258: fnd_msg_pub.add; -- Debashis
259: p_error_message := fnd_message.get_encoded;
260: p_return_status := 'E';
261: raise fnd_api.g_exc_error;
262: -- return;
263:
264: elsif l_proposal_status = 'A' then
265:

Line 270: raise fnd_api.g_exc_error;

266: fnd_message.set_name('IGW','IGW_ROUT_APR_CANNOT_SUBMIT');
267: fnd_msg_pub.add; -- Debashis
268: p_error_message := fnd_message.get_encoded;
269: p_return_status := 'E';
270: raise fnd_api.g_exc_error;
271: -- return;
272:
273:
274: elsif ((l_budget_complete = 'N') AND (l_budget_not_applicable = 'N')) then

Line 280: raise fnd_api.g_exc_error;

276: fnd_message.set_name('IGW','IGW_ROUT_BUDGET_INCOMPLETE');
277: fnd_msg_pub.add; -- Debashis
278: p_error_message := fnd_message.get_encoded;
279: p_return_status := 'E';
280: raise fnd_api.g_exc_error;
281: -- return;
282:
283: end if;
284:

Line 293: raise fnd_api.g_exc_error;

289:
290: if l_invalid_flag = 'Y' then
291: p_error_message := l_error_message;
292: p_return_status := 'E';
293: raise fnd_api.g_exc_error;
294: -- return;
295: end if;
296:
297: -- get the routing business rules

Line 334: raise fnd_api.g_exc_error;

330: fnd_message.set_name('IGW','IGW_ROUT_NO_STOPS_FOUND');
331: fnd_msg_pub.add; -- Debashis
332: p_error_message := fnd_message.get_encoded;
333: p_return_status := 'E';
334: raise fnd_api.g_exc_error;
335: -- return;
336: end if;
337:
338: p_return_status := 'S';

Line 351: WHEN FND_API.G_EXC_ERROR THEN

347:
348: commit; */
349:
350: exception
351: WHEN FND_API.G_EXC_ERROR THEN
352: p_return_status := FND_API.G_RET_STS_ERROR;
353: raise fnd_api.g_exc_error;
354:
355: when others then

Line 352: p_return_status := FND_API.G_RET_STS_ERROR;

348: commit; */
349:
350: exception
351: WHEN FND_API.G_EXC_ERROR THEN
352: p_return_status := FND_API.G_RET_STS_ERROR;
353: raise fnd_api.g_exc_error;
354:
355: when others then
356: fnd_msg_pub.add_exc_msg('IGW_PROPOSAL_APPROVAL','START_APPROVAL');

Line 353: raise fnd_api.g_exc_error;

349:
350: exception
351: WHEN FND_API.G_EXC_ERROR THEN
352: p_return_status := FND_API.G_RET_STS_ERROR;
353: raise fnd_api.g_exc_error;
354:
355: when others then
356: fnd_msg_pub.add_exc_msg('IGW_PROPOSAL_APPROVAL','START_APPROVAL');
357:

Line 359: p_encoded => FND_API.G_TRUE);

355: when others then
356: fnd_msg_pub.add_exc_msg('IGW_PROPOSAL_APPROVAL','START_APPROVAL');
357:
358: p_error_message := fnd_msg_pub.get(p_msg_index => FND_MSG_PUB.G_FIRST,
359: p_encoded => FND_API.G_TRUE);
360:
361:
362: p_return_status := 'U';
363: raise;

Line 489: raise fnd_api.g_exc_error;

485: p_error_message := fnd_message.get_encoded;
486:
487: close get_business_rules;
488: p_invalid_flag := 'Y';
489: raise fnd_api.g_exc_error;
490:
491: -- exit;
492:
493:

Line 634: WHEN FND_API.G_EXC_ERROR THEN

630:
631: end loop;
632:
633: exception
634: WHEN FND_API.G_EXC_ERROR THEN
635: raise fnd_api.g_exc_error;
636:
637: when others then
638: fnd_msg_pub.add_exc_msg('IGW_PROPOSAL_APPROVAL','GET_BUSINESS_RULES');

Line 635: raise fnd_api.g_exc_error;

631: end loop;
632:
633: exception
634: WHEN FND_API.G_EXC_ERROR THEN
635: raise fnd_api.g_exc_error;
636:
637: when others then
638: fnd_msg_pub.add_exc_msg('IGW_PROPOSAL_APPROVAL','GET_BUSINESS_RULES');
639: raise;