48: from per_business_groups
49: where business_group_id = p_business_group_id;
50: --
51: Begin
52: hr_utility.set_location('Entering:'||l_proc,10);
53: --
54: hr_api.mandatory_arg_error
55: (p_api_name => l_proc
56: ,p_argument => 'business_group_id'
59: --
60: open csr_chk_bg_id;
61: fetch csr_chk_bg_id into l_business_group_id;
62: --
63: hr_utility.set_location(l_proc,15);
64: if (csr_chk_bg_id%notfound) then
65: close csr_chk_bg_id;
66: fnd_message.set_name('PER','IRC_412661_INV_BG_ID');
67: fnd_message.raise_error;
68: end if;
69: --
70: close csr_chk_bg_id;
71: --
72: hr_utility.set_location(' Leaving:'||l_proc,20);
73: exception
74: when app_exception.application_exception then
75: if hr_multi_message.exception_add
76: (p_associated_column1 => 'IRC_LOCATION_PREFERENCES.BUSINESS_GROUP_ID'
74: when app_exception.application_exception then
75: if hr_multi_message.exception_add
76: (p_associated_column1 => 'IRC_LOCATION_PREFERENCES.BUSINESS_GROUP_ID'
77: ) then
78: hr_utility.set_location(' Leaving:'|| l_proc, 25);
79: raise;
80: end if;
81: hr_utility.set_location(' Leaving:'|| l_proc, 30);
82: End chk_business_group_id;
77: ) then
78: hr_utility.set_location(' Leaving:'|| l_proc, 25);
79: raise;
80: end if;
81: hr_utility.set_location(' Leaving:'|| l_proc, 30);
82: End chk_business_group_id;
83: --
84: -- ----------------------------------------------------------------------------
85: -- |-------------------------< chk_country_code >-----------------------------|
117: from fnd_territories
118: where territory_code = p_country_code;
119: --
120: Begin
121: hr_utility.set_location('Entering:'||l_proc,10);
122: --
123: hr_api.mandatory_arg_error
124: (p_api_name => l_proc
125: ,p_argument => 'country_code'
128: --
129: open csr_chk_country_code;
130: fetch csr_chk_country_code into l_country_code;
131: --
132: hr_utility.set_location(l_proc,15);
133: if (csr_chk_country_code%notfound) then
134: close csr_chk_country_code;
135: fnd_message.set_name('PER','IRC_412662_INV_COUNTRY_CODE');
136: fnd_message.raise_error;
137: end if;
138: --
139: close csr_chk_country_code;
140: --
141: hr_utility.set_location(' Leaving:'||l_proc,20);
142: exception
143: when app_exception.application_exception then
144: if hr_multi_message.exception_add
145: (p_associated_column1 => 'IRC_LOCATION_PREFERENCES.COUNTRY_CODE'
143: when app_exception.application_exception then
144: if hr_multi_message.exception_add
145: (p_associated_column1 => 'IRC_LOCATION_PREFERENCES.COUNTRY_CODE'
146: ) then
147: hr_utility.set_location(' Leaving:'|| l_proc, 25);
148: raise;
149: end if;
150: hr_utility.set_location(' Leaving:'|| l_proc, 30);
151: End chk_country_code;
146: ) then
147: hr_utility.set_location(' Leaving:'|| l_proc, 25);
148: raise;
149: end if;
150: hr_utility.set_location(' Leaving:'|| l_proc, 30);
151: End chk_country_code;
152: --
153: -- ----------------------------------------------------------------------------
154: -- |-------------------------< chk_location_id >------------------------------|
186: from hr_locations_all
187: where location_id = p_location_id;
188: --
189: Begin
190: hr_utility.set_location('Entering:'||l_proc,10);
191: --
192: hr_api.mandatory_arg_error
193: (p_api_name => l_proc
194: ,p_argument => 'location_id'
197: --
198: open csr_chk_loc_id;
199: fetch csr_chk_loc_id into l_location_id;
200: --
201: hr_utility.set_location(l_proc,15);
202: if (csr_chk_loc_id%notfound) then
203: close csr_chk_loc_id;
204: fnd_message.set_name('PER','IRC_412663_INV_LOCATION_ID');
205: fnd_message.raise_error;
206: end if;
207: --
208: close csr_chk_loc_id;
209: --
210: hr_utility.set_location(' Leaving:'||l_proc,20);
211: exception
212: when app_exception.application_exception then
213: if hr_multi_message.exception_add
214: (p_associated_column1 => 'IRC_LOCATION_PREFERENCES.LOCATION_ID'
212: when app_exception.application_exception then
213: if hr_multi_message.exception_add
214: (p_associated_column1 => 'IRC_LOCATION_PREFERENCES.LOCATION_ID'
215: ) then
216: hr_utility.set_location(' Leaving:'|| l_proc, 25);
217: raise;
218: end if;
219: hr_utility.set_location(' Leaving:'|| l_proc, 30);
220: End chk_location_id;
215: ) then
216: hr_utility.set_location(' Leaving:'|| l_proc, 25);
217: raise;
218: end if;
219: hr_utility.set_location(' Leaving:'|| l_proc, 30);
220: End chk_location_id;
221: --
222: -- ----------------------------------------------------------------------------
223: -- |-------------------------< chk_duplicate_loc_pref >-----------------------|
267: and country_code = p_country_code
268: and location_id = p_location_id;
269: --
270: Begin
271: hr_utility.set_location('Entering:'||l_proc,10);
272: --
273: open csr_chk_duplicate_loc_pref;
274: fetch csr_chk_duplicate_loc_pref into l_count;
275: --
272: --
273: open csr_chk_duplicate_loc_pref;
274: fetch csr_chk_duplicate_loc_pref into l_count;
275: --
276: hr_utility.set_location(l_proc,15);
277: if (csr_chk_duplicate_loc_pref%found) then
278: close csr_chk_duplicate_loc_pref;
279: fnd_message.set_name('PER','IRC_412664_DUP_LOC_PREFS');
280: fnd_message.raise_error;
281: end if;
282: --
283: close csr_chk_duplicate_loc_pref;
284: --
285: hr_utility.set_location(' Leaving:'||l_proc,20);
286: exception
287: when app_exception.application_exception then
288: if hr_multi_message.exception_add
289: (p_associated_column1 => 'IRC_LOCATION_PREFERENCES.OBJECT_ID'
288: if hr_multi_message.exception_add
289: (p_associated_column1 => 'IRC_LOCATION_PREFERENCES.OBJECT_ID'
290: ,p_associated_column2 => 'IRC_LOCATION_PREFERENCES.OBJECT_TYPE'
291: ) then
292: hr_utility.set_location(' Leaving:'|| l_proc, 25);
293: raise;
294: end if;
295: hr_utility.set_location(' Leaving:'|| l_proc, 30);
296: End chk_duplicate_loc_pref;
291: ) then
292: hr_utility.set_location(' Leaving:'|| l_proc, 25);
293: raise;
294: end if;
295: hr_utility.set_location(' Leaving:'|| l_proc, 30);
296: End chk_duplicate_loc_pref;
297: --
298: -- ----------------------------------------------------------------------------
299: -- |------------------------------< chk_df >----------------------------------|
329: --
330: l_proc varchar2(72) := g_package || 'chk_df';
331: --
332: begin
333: hr_utility.set_location('Entering:'||l_proc,10);
334: --
335: if ((p_rec.location_pref_id is not null) and (
336: nvl(irc_ilp_shd.g_old_rec.attribute_category, hr_api.g_varchar2) <>
337: nvl(p_rec.attribute_category, hr_api.g_varchar2) or
468: ,p_attribute30_value => p_rec.attribute30
469: );
470: end if;
471: --
472: hr_utility.set_location(' Leaving:'||l_proc,20);
473: end chk_df;
474: --
475: -- ----------------------------------------------------------------------------
476: -- |-----------------------< chk_non_updateable_args >------------------------|
536: --
537: l_proc varchar2(72) := g_package||'insert_validate';
538: --
539: Begin
540: hr_utility.set_location('Entering:'||l_proc, 5);
541: --
542: -- Call all supporting business operations
543: --
544: -- EDIT_HERE: The following call to hr_api.validate_bus_grp_id
561: (p_business_group_id => p_rec.business_group_id
562: ,p_associated_column1 => irc_ilp_shd.g_tab_nam
563: || '.BUSINESS_GROUP_ID');
564: --
565: hr_utility.set_location('Entering:'||l_proc, 10);
566: --
567: --
568: -- After validating the set of important attributes,
569: -- if Multiple Message detection is enabled and at least
572: hr_multi_message.end_validation_set;
573: --
574: -- Validate Dependent Attributes
575: --
576: hr_utility.set_location(l_proc, 15);
577: --
578: irc_ilp_bus.chk_business_group_id
579: (p_business_group_id => p_rec.business_group_id
580: );
578: irc_ilp_bus.chk_business_group_id
579: (p_business_group_id => p_rec.business_group_id
580: );
581: --
582: hr_utility.set_location(l_proc, 20);
583: --
584: irc_ilp_bus.chk_country_code
585: (p_country_code => p_rec.country_code
586: );
584: irc_ilp_bus.chk_country_code
585: (p_country_code => p_rec.country_code
586: );
587: --
588: hr_utility.set_location(l_proc, 25);
589: --
590: irc_ilp_bus.chk_location_id
591: (p_location_id => p_rec.location_id
592: );
590: irc_ilp_bus.chk_location_id
591: (p_location_id => p_rec.location_id
592: );
593: --
594: /*hr_utility.set_location(l_proc, 35);
595: --
596: irc_ilp_bus.chk_duplicate_loc_pref
597: (p_object_id => p_rec.object_id
598: ,p_object_type => p_rec.object_type
600: ,p_country_code => p_rec.country_code
601: ,p_location_id => p_rec.location_id
602: );
603: -- */
604: hr_utility.set_location(l_proc, 40);
605: --
606: --irc_ilp_bus.chk_df(p_rec);
607: --
608: hr_utility.set_location(l_proc, 45);
604: hr_utility.set_location(l_proc, 40);
605: --
606: --irc_ilp_bus.chk_df(p_rec);
607: --
608: hr_utility.set_location(l_proc, 45);
609: --
610: hr_utility.set_location(' Leaving:'||l_proc, 50);
611: End insert_validate;
612: --
606: --irc_ilp_bus.chk_df(p_rec);
607: --
608: hr_utility.set_location(l_proc, 45);
609: --
610: hr_utility.set_location(' Leaving:'||l_proc, 50);
611: End insert_validate;
612: --
613: -- ----------------------------------------------------------------------------
614: -- |---------------------------< update_validate >----------------------------|
620: --
621: l_proc varchar2(72) := g_package||'update_validate';
622: --
623: Begin
624: hr_utility.set_location('Entering:'||l_proc, 5);
625: --
626: -- Call all supporting business operations
627: --
628: -- EDIT_HERE: The following call to hr_api.validate_bus_grp_id
660: --
661: --
662: irc_ilp_bus.chk_df(p_rec);
663: --
664: hr_utility.set_location(' Leaving:'||l_proc, 10);
665: End update_validate;
666: --
667: -- ----------------------------------------------------------------------------
668: -- |---------------------------< delete_validate >----------------------------|
673: --
674: l_proc varchar2(72) := g_package||'delete_validate';
675: --
676: Begin
677: hr_utility.set_location('Entering:'||l_proc, 5);
678: --
679: -- Call all supporting business operations
680: --
681: hr_utility.set_location(' Leaving:'||l_proc, 10);
677: hr_utility.set_location('Entering:'||l_proc, 5);
678: --
679: -- Call all supporting business operations
680: --
681: hr_utility.set_location(' Leaving:'||l_proc, 10);
682: End delete_validate;
683: --
684: end irc_ilp_bus;