1 Package hr_ori_bus as
2 /* $Header: hrorirhi.pkh 120.0.12010000.1 2008/07/28 03:36:18 appldev ship $ */
3 --
4 -- ----------------------------------------------------------------------------
5 -- |-------------------------< chk_name >-------------------------------------|
6 -- ----------------------------------------------------------------------------
7 --
8 -- This procedure checks that the organization information being passed
9 -- identifies the record as being a business group, if so, it derives the
10 -- name of the organization and searches for any other business groups
11 -- with the same name.
12 --
13 -- Access Status:
14 -- Internal Development Use Only.
15 --
16 -- {End Of Comments}
17 --
18 PROCEDURE chk_name
19 (p_org_information1 IN hr_organization_information.org_information1%TYPE,
20 p_org_information_context IN hr_organization_information.org_information_context%TYPE,
21 p_organization_id IN number default null,
22 p_org_information2 IN hr_organization_information.org_information2%TYPE
23 );
24 -- ----------------------------------------------------------------------------
25 -- |-------------------------< chk_cost_center_gap >--------------------------|
26 -- ----------------------------------------------------------------------------
27 --
28 -- This procedure checks that the organization information being passed
29 -- in does not result in a gap in existing cost center managers.
30 -- This function returns a boolean.
31 --
32 -- Access Status:
33 -- Internal Development Use Only.
34 --
35 -- {End Of Comments}
36 --
37 FUNCTION chk_cost_center_gap
38 (p_organization_id IN number,
39 p_org_information_context IN varchar2,
40 p_org_information_id IN number,
41 p_start_date IN date,
42 p_end_date IN date) return boolean;
43 --
44 -- ---------------------------------------------------------------------------
45 -- |----------------------< set_security_group_id >--------------------------|
46 -- ---------------------------------------------------------------------------
47 -- {Start Of Comments}
48 --
49 -- Description:
50 -- Sets the security_group_id in CLIENT_INFO for the appropriate business
51 -- group context.
52 --
53 -- Prerequisites:
54 -- The primary key identified by p_org_information_id
55 -- already exists.
56 --
57 -- In Arguments:
58 -- p_org_information_id
59 --
60 --
61 -- Post Success:
62 -- The security_group_id will be set in CLIENT_INFO.
63 --
64 -- Post Failure:
65 -- An error is raised if the value does not exist.
66 --
67 -- Access Status:
68 -- Internal Development Use Only.
69 --
70 -- {End Of Comments}
71 -- ---------------------------------------------------------------------------
72 procedure set_security_group_id
73 (p_org_information_id in number
74 );
75 --
76 --
77 -- ---------------------------------------------------------------------------
78 -- |---------------------< return_legislation_code >-------------------------|
79 -- ---------------------------------------------------------------------------
80 -- {Start Of Comments}
81 --
82 -- Description:
83 -- Return the legislation code for a specific primary key value
84 --
85 -- Prerequisites:
86 -- The primary key identified by p_org_information_id
87 -- already exists.
88 --
89 -- In Arguments:
90 -- p_org_information_id
91 --
92 --
93 -- Post Success:
94 -- The business group's legislation code will be returned.
95 --
96 -- Post Failure:
97 -- An error is raised if the value does not exist.
98 --
99 -- Access Status:
100 -- Internal Development Use Only.
101 --
102 -- {End Of Comments}
103 -- ---------------------------------------------------------------------------
104 FUNCTION return_legislation_code
105 (p_org_information_id in number
106 ) RETURN varchar2;
107 --
108 --
109 -- ----------------------------------------------------------------------------
110 -- |---------------------------< insert_validate >----------------------------|
111 -- ----------------------------------------------------------------------------
112 -- {Start of comments}
113 --
114 -- Description:
115 -- This procedure controls the execution of all insert business rules
116 -- validation.
117 --
118 -- Prerequisites:
119 -- This private procedure is called from ins procedure.
120 --
121 -- In Parameters:
122 -- A Pl/Sql record structure.
123 --
124 -- Post Success:
125 -- Processing continues.
126 --
127 -- Post Failure:
128 -- If a business rules fails the error will not be handled by this procedure
129 -- unless explicity coded.
130 --
131 -- Developer Implementation Notes:
132 -- For insert, your business rules should be executed from this procedure and
133 -- should ideally (unless really necessary) just be straight procedure or
134 -- function calls. Try and avoid using conditional branching logic.
135 --
136 -- Access Status:
137 -- Internal Row Handler Use Only.
138 --
139 -- {End of comments}
140 -- ----------------------------------------------------------------------------
141 Procedure insert_validate
142 (p_effective_date in date
143 ,p_rec in hr_ori_shd.g_rec_type
144 );
145 --
146 -- ----------------------------------------------------------------------------
147 -- |---------------------------< update_validate >----------------------------|
148 -- ----------------------------------------------------------------------------
149 -- {Start Of Comments}
150 --
151 -- Description:
152 -- This procedure controls the execution of all update business rules
153 -- validation.
154 --
155 -- Prerequisites:
156 -- This private procedure is called from upd procedure.
157 --
158 -- In Parameters:
159 -- A Pl/Sql record structure.
160 --
161 -- Post Success:
162 -- Processing continues.
163 --
164 -- Post Failure:
165 -- If a business rules fails the error will not be handled by this procedure
166 -- unless explicity coded.
167 --
168 -- Developer Implementation Notes:
169 -- For update, your business rules should be executed from this procedure and
170 -- should ideally (unless really necessary) just be straight procedure or
171 -- function calls. Try and avoid using conditional branching logic.
172 --
173 -- Access Status:
174 -- Internal Row Handler Use Only.
175 --
176 -- {End Of Comments}
177 -- ----------------------------------------------------------------------------
178 Procedure update_validate
179 (p_effective_date in date
180 ,p_rec in hr_ori_shd.g_rec_type
181 );
182 --
183 -- ----------------------------------------------------------------------------
184 -- |---------------------------< delete_validate >----------------------------|
185 -- ----------------------------------------------------------------------------
186 -- {Start Of Comments}
187 --
188 -- Description:
189 -- This procedure controls the execution of all delete business rules
190 -- validation.
191 --
192 -- Prerequisites:
193 -- This private procedure is called from del procedure.
194 --
195 -- In Parameters:
196 -- A Pl/Sql record structure.
197 --
198 -- Post Success:
199 -- Processing continues.
200 --
201 -- Post Failure:
202 -- If a business rules fails the error will not be handled by this procedure
203 -- unless explicity coded.
204 --
205 -- Developer Implementation Notes:
206 -- For delete, your business rules should be executed from this procedure and
207 -- should ideally (unless really necessary) just be straight procedure or
208 -- function calls. Try and avoid using conditional branching logic.
209 --
210 -- Access Status:
211 -- Internal Row Handler Use Only.
212 --
213 -- {End Of Comments}
214 -- ----------------------------------------------------------------------------
215 Procedure delete_validate
216 (p_rec in hr_ori_shd.g_rec_type
217 );
218 --
219 end hr_ori_bus;