14: --
15: l_proc varchar2(72) := g_package||'return_api_dml_status';
16: --
17: Begin
18: hr_utility.set_location('Entering:'||l_proc, 5);
19: --
20: Return (nvl(g_api_dml, false));
21: --
22: hr_utility.set_location(' Leaving:'||l_proc, 10);
18: hr_utility.set_location('Entering:'||l_proc, 5);
19: --
20: Return (nvl(g_api_dml, false));
21: --
22: hr_utility.set_location(' Leaving:'||l_proc, 10);
23: End return_api_dml_status;
24: --
25: -- ----------------------------------------------------------------------------
26: -- |---------------------------< constraint_error >---------------------------|
30: --
31: l_proc varchar2(72) := g_package||'constraint_error';
32: --
33: Begin
34: hr_utility.set_location('Entering:'||l_proc, 5);
35: --
36: If (p_constraint_name = 'BEN_POP_UP_MESSAGES_PK') Then
37: hr_utility.set_message(801, 'HR_6153_ALL_PROCEDURE_FAIL');
38: hr_utility.set_message_token('PROCEDURE', l_proc);
33: Begin
34: hr_utility.set_location('Entering:'||l_proc, 5);
35: --
36: If (p_constraint_name = 'BEN_POP_UP_MESSAGES_PK') Then
37: hr_utility.set_message(801, 'HR_6153_ALL_PROCEDURE_FAIL');
38: hr_utility.set_message_token('PROCEDURE', l_proc);
39: hr_utility.set_message_token('STEP','5');
40: hr_utility.raise_error;
41: Else
34: hr_utility.set_location('Entering:'||l_proc, 5);
35: --
36: If (p_constraint_name = 'BEN_POP_UP_MESSAGES_PK') Then
37: hr_utility.set_message(801, 'HR_6153_ALL_PROCEDURE_FAIL');
38: hr_utility.set_message_token('PROCEDURE', l_proc);
39: hr_utility.set_message_token('STEP','5');
40: hr_utility.raise_error;
41: Else
42: hr_utility.set_message(801, 'HR_7877_API_INVALID_CONSTRAINT');
35: --
36: If (p_constraint_name = 'BEN_POP_UP_MESSAGES_PK') Then
37: hr_utility.set_message(801, 'HR_6153_ALL_PROCEDURE_FAIL');
38: hr_utility.set_message_token('PROCEDURE', l_proc);
39: hr_utility.set_message_token('STEP','5');
40: hr_utility.raise_error;
41: Else
42: hr_utility.set_message(801, 'HR_7877_API_INVALID_CONSTRAINT');
43: hr_utility.set_message_token('PROCEDURE', l_proc);
36: If (p_constraint_name = 'BEN_POP_UP_MESSAGES_PK') Then
37: hr_utility.set_message(801, 'HR_6153_ALL_PROCEDURE_FAIL');
38: hr_utility.set_message_token('PROCEDURE', l_proc);
39: hr_utility.set_message_token('STEP','5');
40: hr_utility.raise_error;
41: Else
42: hr_utility.set_message(801, 'HR_7877_API_INVALID_CONSTRAINT');
43: hr_utility.set_message_token('PROCEDURE', l_proc);
44: hr_utility.set_message_token('CONSTRAINT_NAME', p_constraint_name);
38: hr_utility.set_message_token('PROCEDURE', l_proc);
39: hr_utility.set_message_token('STEP','5');
40: hr_utility.raise_error;
41: Else
42: hr_utility.set_message(801, 'HR_7877_API_INVALID_CONSTRAINT');
43: hr_utility.set_message_token('PROCEDURE', l_proc);
44: hr_utility.set_message_token('CONSTRAINT_NAME', p_constraint_name);
45: hr_utility.raise_error;
46: End If;
39: hr_utility.set_message_token('STEP','5');
40: hr_utility.raise_error;
41: Else
42: hr_utility.set_message(801, 'HR_7877_API_INVALID_CONSTRAINT');
43: hr_utility.set_message_token('PROCEDURE', l_proc);
44: hr_utility.set_message_token('CONSTRAINT_NAME', p_constraint_name);
45: hr_utility.raise_error;
46: End If;
47: --
40: hr_utility.raise_error;
41: Else
42: hr_utility.set_message(801, 'HR_7877_API_INVALID_CONSTRAINT');
43: hr_utility.set_message_token('PROCEDURE', l_proc);
44: hr_utility.set_message_token('CONSTRAINT_NAME', p_constraint_name);
45: hr_utility.raise_error;
46: End If;
47: --
48: hr_utility.set_location(' Leaving:'||l_proc, 10);
41: Else
42: hr_utility.set_message(801, 'HR_7877_API_INVALID_CONSTRAINT');
43: hr_utility.set_message_token('PROCEDURE', l_proc);
44: hr_utility.set_message_token('CONSTRAINT_NAME', p_constraint_name);
45: hr_utility.raise_error;
46: End If;
47: --
48: hr_utility.set_location(' Leaving:'||l_proc, 10);
49: End constraint_error;
44: hr_utility.set_message_token('CONSTRAINT_NAME', p_constraint_name);
45: hr_utility.raise_error;
46: End If;
47: --
48: hr_utility.set_location(' Leaving:'||l_proc, 10);
49: End constraint_error;
50: --
51: -- ----------------------------------------------------------------------------
52: -- |-----------------------------< api_updating >-----------------------------|
82: l_proc varchar2(72) := g_package||'api_updating';
83: l_fct_ret boolean;
84: --
85: Begin
86: hr_utility.set_location('Entering:'||l_proc, 5);
87: --
88: If (
89: p_pop_up_messages_id is null and
90: p_object_version_number is null
98: If (
99: p_pop_up_messages_id = g_old_rec.pop_up_messages_id and
100: p_object_version_number = g_old_rec.object_version_number
101: ) Then
102: hr_utility.set_location(l_proc, 10);
103: --
104: -- The g_old_rec is current therefore we must
105: -- set the returning function to true
106: --
115: Close C_Sel1;
116: --
117: -- The primary key is invalid therefore we must error
118: --
119: hr_utility.set_message(801, 'HR_7220_INVALID_PRIMARY_KEY');
120: hr_utility.raise_error;
121: End If;
122: Close C_Sel1;
123: If (p_object_version_number <> g_old_rec.object_version_number) Then
116: --
117: -- The primary key is invalid therefore we must error
118: --
119: hr_utility.set_message(801, 'HR_7220_INVALID_PRIMARY_KEY');
120: hr_utility.raise_error;
121: End If;
122: Close C_Sel1;
123: If (p_object_version_number <> g_old_rec.object_version_number) Then
124: hr_utility.set_message(801, 'HR_7155_OBJECT_INVALID');
120: hr_utility.raise_error;
121: End If;
122: Close C_Sel1;
123: If (p_object_version_number <> g_old_rec.object_version_number) Then
124: hr_utility.set_message(801, 'HR_7155_OBJECT_INVALID');
125: hr_utility.raise_error;
126: End If;
127: hr_utility.set_location(l_proc, 15);
128: l_fct_ret := true;
121: End If;
122: Close C_Sel1;
123: If (p_object_version_number <> g_old_rec.object_version_number) Then
124: hr_utility.set_message(801, 'HR_7155_OBJECT_INVALID');
125: hr_utility.raise_error;
126: End If;
127: hr_utility.set_location(l_proc, 15);
128: l_fct_ret := true;
129: End If;
123: If (p_object_version_number <> g_old_rec.object_version_number) Then
124: hr_utility.set_message(801, 'HR_7155_OBJECT_INVALID');
125: hr_utility.raise_error;
126: End If;
127: hr_utility.set_location(l_proc, 15);
128: l_fct_ret := true;
129: End If;
130: End If;
131: hr_utility.set_location(' Leaving:'||l_proc, 20);
127: hr_utility.set_location(l_proc, 15);
128: l_fct_ret := true;
129: End If;
130: End If;
131: hr_utility.set_location(' Leaving:'||l_proc, 20);
132: Return (l_fct_ret);
133: --
134: End api_updating;
135: --
165: --
166: l_proc varchar2(72) := g_package||'lck';
167: --
168: Begin
169: hr_utility.set_location('Entering:'||l_proc, 5);
170: --
171: -- Add any mandatory argument checking here:
172: -- Example:
173: -- hr_api.mandatory_arg_error
181: Close C_Sel1;
182: --
183: -- The primary key is invalid therefore we must error
184: --
185: hr_utility.set_message(801, 'HR_7220_INVALID_PRIMARY_KEY');
186: hr_utility.raise_error;
187: End If;
188: Close C_Sel1;
189: If (p_object_version_number <> g_old_rec.object_version_number) Then
182: --
183: -- The primary key is invalid therefore we must error
184: --
185: hr_utility.set_message(801, 'HR_7220_INVALID_PRIMARY_KEY');
186: hr_utility.raise_error;
187: End If;
188: Close C_Sel1;
189: If (p_object_version_number <> g_old_rec.object_version_number) Then
190: hr_utility.set_message(801, 'HR_7155_OBJECT_INVALID');
186: hr_utility.raise_error;
187: End If;
188: Close C_Sel1;
189: If (p_object_version_number <> g_old_rec.object_version_number) Then
190: hr_utility.set_message(801, 'HR_7155_OBJECT_INVALID');
191: hr_utility.raise_error;
192: End If;
193: --
194: hr_utility.set_location(' Leaving:'||l_proc, 10);
187: End If;
188: Close C_Sel1;
189: If (p_object_version_number <> g_old_rec.object_version_number) Then
190: hr_utility.set_message(801, 'HR_7155_OBJECT_INVALID');
191: hr_utility.raise_error;
192: End If;
193: --
194: hr_utility.set_location(' Leaving:'||l_proc, 10);
195: --
190: hr_utility.set_message(801, 'HR_7155_OBJECT_INVALID');
191: hr_utility.raise_error;
192: End If;
193: --
194: hr_utility.set_location(' Leaving:'||l_proc, 10);
195: --
196: -- We need to trap the ORA LOCK exception
197: --
198: Exception
200: --
201: -- The object is locked therefore we need to supply a meaningful
202: -- error message.
203: --
204: hr_utility.set_message(801, 'HR_7165_OBJECT_LOCKED');
205: hr_utility.set_message_token('TABLE_NAME', 'ben_pop_up_messages');
206: hr_utility.raise_error;
207: End lck;
208: --
201: -- The object is locked therefore we need to supply a meaningful
202: -- error message.
203: --
204: hr_utility.set_message(801, 'HR_7165_OBJECT_LOCKED');
205: hr_utility.set_message_token('TABLE_NAME', 'ben_pop_up_messages');
206: hr_utility.raise_error;
207: End lck;
208: --
209: -- ----------------------------------------------------------------------------
202: -- error message.
203: --
204: hr_utility.set_message(801, 'HR_7165_OBJECT_LOCKED');
205: hr_utility.set_message_token('TABLE_NAME', 'ben_pop_up_messages');
206: hr_utility.raise_error;
207: End lck;
208: --
209: -- ----------------------------------------------------------------------------
210: -- |-----------------------------< convert_args >-----------------------------|
232: l_proc varchar2(72) := g_package||'convert_args';
233: --
234: Begin
235: --
236: hr_utility.set_location('Entering:'||l_proc, 5);
237: --
238: -- Convert arguments into local l_rec structure.
239: --
240: l_rec.pop_up_messages_id := p_pop_up_messages_id;
253: l_rec.no_formula_flag := p_no_formula_flag;
254: --
255: -- Return the plsql record structure.
256: --
257: hr_utility.set_location(' Leaving:'||l_proc, 10);
258: Return(l_rec);
259: --
260: End convert_args;
261: --