154: begin
155: --
156: l_proc := c_package || 'transfer_asg';
157: --
158: hr_utility.set_location('Entering : ' || l_proc, 10);
159: --
160: hr_utility.trace('********************');
161: hr_utility.trace('assignment_id : ' || to_char(p_assignment_id));
162: hr_utility.trace('assignment_number : ' || p_assignment_number);
156: l_proc := c_package || 'transfer_asg';
157: --
158: hr_utility.set_location('Entering : ' || l_proc, 10);
159: --
160: hr_utility.trace('********************');
161: hr_utility.trace('assignment_id : ' || to_char(p_assignment_id));
162: hr_utility.trace('assignment_number : ' || p_assignment_number);
163: hr_utility.trace('upload_date : ' || to_char(p_upload_date));
164: --
157: --
158: hr_utility.set_location('Entering : ' || l_proc, 10);
159: --
160: hr_utility.trace('********************');
161: hr_utility.trace('assignment_id : ' || to_char(p_assignment_id));
162: hr_utility.trace('assignment_number : ' || p_assignment_number);
163: hr_utility.trace('upload_date : ' || to_char(p_upload_date));
164: --
165: -- Derive commutation allowance information from PAY_ELEMENT_ENTRIES_F.
158: hr_utility.set_location('Entering : ' || l_proc, 10);
159: --
160: hr_utility.trace('********************');
161: hr_utility.trace('assignment_id : ' || to_char(p_assignment_id));
162: hr_utility.trace('assignment_number : ' || p_assignment_number);
163: hr_utility.trace('upload_date : ' || to_char(p_upload_date));
164: --
165: -- Derive commutation allowance information from PAY_ELEMENT_ENTRIES_F.
166: --
159: --
160: hr_utility.trace('********************');
161: hr_utility.trace('assignment_id : ' || to_char(p_assignment_id));
162: hr_utility.trace('assignment_number : ' || p_assignment_number);
163: hr_utility.trace('upload_date : ' || to_char(p_upload_date));
164: --
165: -- Derive commutation allowance information from PAY_ELEMENT_ENTRIES_F.
166: --
167: pay_jp_bee_utility_pkg.get_ee(
203: p_effective_date => p_upload_date), 'N');
204: end if;
205:
206: --
207: hr_utility.trace('non_res_flag : ' || l_non_res_flag);
208: --
209: -- Derive commutation allowance information from element entries.
210: --
211: per_jp_cma_utility_pkg.get_cma_info(
219: --
220: -- If there're multiple traffic tool record, skip processing for current assignment and output log.
221: --
222: if l_cma_rec.multiple_entry_warning then
223: hr_utility.trace('Multiple car. Skip processing');
224: raise multiple_traffic_tool_rec;
225: end if;
226: --
227: if (l_ee_rec.element_entry_id is not null) or (l_record_exist) then
267: --
268: -- Write to output file
269: --
270: if l_ee_rec.element_entry_id is null then
271: hr_utility.trace('EE not exist. Create EE.');
272: --
273: -- If element does not exist, "Insert" mode.
274: -- Also output all entry values to be transfered.
275: --
275: --
276: l_change_type := 'I';
277: l_write_all := true;
278: else
279: hr_utility.trace('EE exists. Compare Start.');
280: --
281: -- Since the element is nonrecurring type, "Correction" mode.
282: -- In this case, only the entry values to be changed are shown in output file.
283: --
296: --
297: /* bug.5438168. commented out.
298: l_index := l_new_value_tbl.first;
299: while l_index is not null loop
300: hr_utility.trace('Set zero' || to_char(l_index));
301: --
302: if l_new_value_tbl(l_index) is null then
303: l_new_value_tbl(l_index) := c_value_if_null_tbl(l_index);
304: end if;
321: commit;
322: end if;
323: end if;
324: --
325: hr_utility.set_location('Leaving : ' || l_proc, 20);
326: exception
327: when multiple_traffic_tool_rec then
328: pay_jp_bee_utility_pkg.log(
329: p_full_name => p_full_name,
333: p_token1 => 'EFFECTIVE_DATE',
334: p_value1 => fnd_date.date_to_chardate(p_effective_date));
335: create_asg_set_amd;
336: --
337: hr_utility.set_location('Leaving : ' || l_proc, 26);
338: --
339: when others then
340: --
341: pay_jp_bee_utility_pkg.log(
345: p_message_name => '',
346: p_token1 => 'ERROR',
347: p_value1 => to_char(sqlcode)||':'||substrb(sqlerrm,1,100));
348: --
349: hr_utility.trace('transfer_asg ass num : ' || p_assignment_number);
350: --
351: hr_utility.trace('transfer_asg erro code : ' || to_char(sqlcode));
352: hr_utility.trace('transfer_asg erro msg : ' || substrb(sqlerrm,1,100));
353: --
347: p_value1 => to_char(sqlcode)||':'||substrb(sqlerrm,1,100));
348: --
349: hr_utility.trace('transfer_asg ass num : ' || p_assignment_number);
350: --
351: hr_utility.trace('transfer_asg erro code : ' || to_char(sqlcode));
352: hr_utility.trace('transfer_asg erro msg : ' || substrb(sqlerrm,1,100));
353: --
354: hr_utility.set_location('Leaving : ' || l_proc, 30);
355: --
348: --
349: hr_utility.trace('transfer_asg ass num : ' || p_assignment_number);
350: --
351: hr_utility.trace('transfer_asg erro code : ' || to_char(sqlcode));
352: hr_utility.trace('transfer_asg erro msg : ' || substrb(sqlerrm,1,100));
353: --
354: hr_utility.set_location('Leaving : ' || l_proc, 30);
355: --
356: end transfer_asg;
350: --
351: hr_utility.trace('transfer_asg erro code : ' || to_char(sqlcode));
352: hr_utility.trace('transfer_asg erro msg : ' || substrb(sqlerrm,1,100));
353: --
354: hr_utility.set_location('Leaving : ' || l_proc, 30);
355: --
356: end transfer_asg;
357: -- ----------------------------------------------------------------------------
358: -- |---------------------< transfer_from_cma_info_to_bee >--------------------|
402: l_upload_date := fnd_date.canonical_to_date(p_upload_date);
403: --
404: l_date_effective_changes := p_date_effective_changes;
405: --
406: hr_utility.set_location('Entering : ' || l_proc, 10);
407: --
408: -- Validate p_time_period_id and p_upload_date
409: --
410: pay_jp_bee_utility_pkg.chk_upload_date(
461: p_batch_id => l_batch_id,
462: p_object_version_number => l_batch_ovn);
463: commit;
464: --
465: hr_utility.trace('batch_id : ' || to_char(l_batch_id));
466: --
467: -- Initialize Global Variables
468: --
469: g_element_type_id := hr_jp_id_pkg.element_type_id(c_cma_ele_name, p_business_group_id);
525: --
526: -- When no batch lines are created, delete batch header and set message as errbuf.
527: --
528: if pay_jp_bee_utility_pkg.g_num_of_outs = 0 then
529: hr_utility.trace('BEE Header deleted');
530: --
531: pay_batch_element_entry_api.delete_batch_header(
532: p_validate => false,
533: p_batch_id => l_batch_id,
548: end if;
549: --
550: delete_session;
551: --
552: hr_utility.trace('retcode : ' || p_retcode);
553: hr_utility.trace('errbuf : ' || p_errbuf);
554: hr_utility.set_location('Leaving : ' || l_proc, 20);
555: end transfer_from_cma_info_to_bee;
556: --
549: --
550: delete_session;
551: --
552: hr_utility.trace('retcode : ' || p_retcode);
553: hr_utility.trace('errbuf : ' || p_errbuf);
554: hr_utility.set_location('Leaving : ' || l_proc, 20);
555: end transfer_from_cma_info_to_bee;
556: --
557: end pay_jp_create_cma_pkg;
550: delete_session;
551: --
552: hr_utility.trace('retcode : ' || p_retcode);
553: hr_utility.trace('errbuf : ' || p_errbuf);
554: hr_utility.set_location('Leaving : ' || l_proc, 20);
555: end transfer_from_cma_info_to_bee;
556: --
557: end pay_jp_create_cma_pkg;