1 Package hr_person_internal as
2 /* $Header: peperbsi.pkh 120.0.12010000.1 2008/07/28 05:13:12 appldev ship $ */
3 --
4 -- ----------------------------------------------------------------------------
5 -- |--------------------------< product_installed >---------------------------|
6 -- ----------------------------------------------------------------------------
7 -- {Start Of Comments}
8 --
9 -- Description:
10 --
11 -- Checks whether the specified product is installed or not.
12 -- Returns status and oracle_id also.
13 --
14 -- In Parameters:
15 -- Name Reqd Type Description
16 -- p_application_short_name Yes varchar2 Application short name
17 --
18 -- Out parameters:
19 -- Name Type Description
20 -- p_status varchar2 Set to the status of the
21 -- installation.
22 -- p_yes_no varchar2 Set to Y if the product is
23 -- installed otherwsie N.
24 -- p_oracle_username varchar2 user name.
25 -- Access Status:
26 -- Internal.
27 --
28 -- {End Of Comments}
29 --
30 PROCEDURE product_installed (p_application_short_name IN varchar2
31 ,p_status OUT NOCOPY varchar2
32 ,p_yes_no OUT NOCOPY varchar2
33 ,p_oracle_username OUT NOCOPY varchar2);
34 --
35 -- ----------------------------------------------------------------------------
36 -- |------------------------< weak_predel_validation >------------------------|
37 -- ----------------------------------------------------------------------------
38 --
39 -- {Start Of Comments}
40 --
41 -- Description:
42 --
43 -- Weak pre-delete validation executed when called the delete_person API
44 -- from Delete Person form.
45 --
46 -- In Parameters:
47 -- Name Reqd Type Description
48 -- p_person_id yes number ID of the person.
49 -- p_effective_date yes date session date.
50 --
51 -- Access Status:
52 -- Internal.
53 --
54 -- {End Of Comments}
55 --
56 PROCEDURE weak_predel_validation (p_person_id IN number
57 ,p_effective_date IN date);
58 --
59 -- ----------------------------------------------------------------------------
60 -- |-----------------------< strong_predel_validation >-----------------------|
61 -- ----------------------------------------------------------------------------
62 --
63 -- {Start Of Comments}
64 --
65 -- Description:
66 --
67 -- Strong pre-delete validation executed when called from the Enter Person
68 -- and Applicant Quick Entry forms.
69 --
70 -- In Parameters:
71 -- Name Reqd Type Description
72 -- p_person_id yes number ID of the person.
73 -- p_effective_date yes date session date.
74 --
75 -- Access Status:
76 -- Internal.
77 --
78 -- {End Of Comments}
79 --
80 PROCEDURE strong_predel_validation (p_person_id IN number
81 ,p_effective_date IN date);
82 --
83 -- ----------------------------------------------------------------------------
84 -- |---------------------------< check_contact >------------------------------|
85 -- ----------------------------------------------------------------------------
86 --
87 -- {Start Of Comments}
88 --
89 -- Description:
90 --
91 -- Is this contact a contact for anybody else? If so then do nothing.
92 -- If not then check if this person has ever been an employee or
93 -- applicant. If they have not then check whether they have any extra
94 -- info entered for them (other than default info). If they have not
95 -- then delete this contact also. Otherwise do nothing.
96 --
97 -- In Parameters:
98 -- Name Reqd Type Description
99 -- p_person_id yes number ID of the person.
100 -- p_contact_person_id yes number Contact in this relationship
101 -- - the person who the check
102 -- is performed against.
103 -- p_contact_relationship_id yes number Relationship which is
104 -- currently being considered
105 -- for this contact.
106 -- p_effective_date yes date session date.
107 --
108 -- Access Status:
109 -- Internal.
110 --
111 -- {End Of Comments}
112 --
113 PROCEDURE check_contact(p_person_id IN number
114 ,p_contact_person_id IN number
115 ,p_contact_relationship_id IN number
116 ,p_effective_date IN date) ;
117 --
118 -- ----------------------------------------------------------------------------
119 -- |------------------------< delete_org_manager >----------------------------|
120 -- ----------------------------------------------------------------------------
121 --
122 -- {Start Of Comments}
123 --
124 -- Description:
125 --
126 -- If the person is a manager for organization then the organization
127 -- information manager info will be nullified for those organizations.
128 --
129 -- In Parameters:
130 -- Name Reqd Type Description
131 -- p_person_id yes number ID of the person.
132 -- p_effective_date yes date session date.
133 --
134 -- Out parameters:
135 -- Name Type Description
136 -- p_person_org_manager_warning varchar2 Warning message to indicate
137 -- that the person is manager
138 -- for one or more organizations.
139 --
140 -- Access Status:
141 -- Internal.
142 --
143 -- {End Of Comments}
144 --
145 procedure delete_org_manager(p_person_id in number
146 ,p_effective_date in date
147 ,p_person_org_manager_warning out nocopy varchar2);
148 --
149 -- ----------------------------------------------------------------------------
150 -- |-----------------------< people_default_deletes >-------------------------|
151 -- ----------------------------------------------------------------------------
152 --
153 -- {Start Of Comments}
154 --
155 -- Description:
156 --
157 -- Delete people who only have default information entered for them.
158 --
159 -- In Parameters:
160 -- Name Reqd Type Description
161 -- p_person_id yes number ID of the person.
162 --
163 -- Access Status:
164 -- Internal.
165 --
166 -- {End Of Comments}
167 --
168 PROCEDURE people_default_deletes(p_person_id IN number);
169 --
170 -- ----------------------------------------------------------------------------
171 -- |---------------------< applicant_default_deletes >------------------------|
172 -- ----------------------------------------------------------------------------
173 --
174 -- {Start Of Comments}
175 --
176 -- Description:
177 --
178 -- Delete applicants who only have default information entered for them.
179 --
180 -- In Parameters:
181 -- Name Reqd Type Description
182 -- p_person_id yes number ID of the person.
183 --
184 -- Access Status:
185 -- Internal.
186 --
187 -- {End Of Comments}
188 --
189 PROCEDURE applicant_default_deletes (p_person_id IN number);
190 --
191 -- ----------------------------------------------------------------------------
192 -- |---------------------------< delete_person >------------------------------|
193 -- ----------------------------------------------------------------------------
194 --
195 -- {Start Of Comments}
196 --
197 -- Description:
198 --
199 -- Delete a person completely from the HR database. Deletes from all tables
200 -- referencing this person n HR database.
201 --
202 -- In Parameters:
203 -- Name Reqd Type Description
204 -- p_person_id yes number ID of the person.
205 -- p_effective_date yes date session date.
206 --
207 -- Access Status:
208 -- Internal.
209 --
210 -- {End Of Comments}
211 --
212 PROCEDURE delete_person (p_person_id IN number
213 ,p_effective_date IN date);
214 --
215 end hr_person_internal;