94: l_proc VARCHAR2(72) := g_package||'update_assignments';
95: --
96: BEGIN
97: --
98: HR_UTILITY.set_location('Entering:'|| l_proc, 10);
99: OPEN csr_situation_details(p_statutory_situation_id);
100: FETCH csr_situation_details INTO lr_sit_dtls.situation_type,
101: lr_sit_dtls.sub_type,
102: lr_sit_dtls.reserve_position,
415: l_object_version_number NUMBER(9);
416: l_actual_start_date DATE;
417: l_proc varchar2(72) := g_package||'create_emp_stat_situation';
418: begin
419: hr_utility.set_location('Entering:'|| l_proc, 10);
420: savepoint create_emp_stat_situation;
421: --
422: -- Validation in addition to Row Handlers
423: --
493: raise hr_api.validate_enabled;
494: END IF;
495: p_emp_stat_situation_id := l_emp_stat_situation_id;
496: p_object_version_number := l_object_version_number;
497: hr_utility.set_location(' Leaving:'||l_proc, 40);
498: EXCEPTION
499: when hr_api.validate_enabled then
500: --
501: -- As the Validate_Enabled exception has been raised
503: --
504: ROLLBACK TO create_emp_stat_situation;
505: p_emp_stat_situation_id := null;
506: p_object_version_number := null;
507: hr_utility.set_location(' Leaving:'||l_proc, 41);
508: When Others THEN
509: Rollback to create_emp_stat_situation;
510: hr_utility.set_location(' Leaving:'||l_proc, 42);
511: fnd_message.raise_error;
506: p_object_version_number := null;
507: hr_utility.set_location(' Leaving:'||l_proc, 41);
508: When Others THEN
509: Rollback to create_emp_stat_situation;
510: hr_utility.set_location(' Leaving:'||l_proc, 42);
511: fnd_message.raise_error;
512: end CREATE_EMP_STAT_SITUATION;
513: procedure UPDATE_EMP_STAT_SITUATION
514: (p_validate IN boolean default false
571: l_sit_approval varchar2(10) ;
572: l_proc varchar2(72) := g_package||'update_emp_stat_situation';
573: l_actual_start_date DATE;
574: begin
575: hr_utility.set_location('Entering:'|| l_proc, 10);
576: l_emp_stat_situation_id := p_emp_stat_situation_id;
577: l_object_version_number := p_object_version_number;
578: l_orig_object_version_number := p_object_version_number;
579: savepoint update_emp_stat_situation;
654: IF p_validate = TRUE THEN
655: raise hr_api.validate_enabled;
656: END IF;
657: p_object_version_number := l_object_version_number;
658: hr_utility.set_location(' Leaving:'||l_proc, 40);
659: EXCEPTION
660: when hr_api.validate_enabled then
661: --
662: -- As the Validate_Enabled exception has been raised
661: --
662: -- As the Validate_Enabled exception has been raised
663: -- we must rollback to the savepoint
664: --
665: hr_utility.set_location(' Leaving:'||l_proc, 41);
666: ROLLBACK TO update_emp_stat_situation;
667: p_object_version_number := l_orig_object_version_number;
668: When Others THEN
669: Rollback to update_emp_stat_situation;
667: p_object_version_number := l_orig_object_version_number;
668: When Others THEN
669: Rollback to update_emp_stat_situation;
670: p_object_version_number := l_orig_object_version_number;
671: hr_utility.set_location(' Leaving:'||l_proc, 42 );
672: fnd_message.raise_error;
673: END UPDATE_EMP_STAT_SITUATION;
674: Procedure DELETE_EMP_STAT_SITUATION
675: ( P_VALIDATE IN BOOLEAN DEFAULT FALSE
676: ,P_EMP_STAT_SITUATION_ID IN NUMBER
677: ,P_OBJECT_VERSION_NUMBER IN NUMBER) IS
678: l_proc varchar2(72) := g_package||'delete_emp_stat_situation';
679: BEGIN
680: hr_utility.set_location('Entering:'|| l_proc, 10);
681: savepoint delete_emp_stat_situation;
682: pqh_psu_del.del(p_emp_stat_situation_id => p_emp_stat_situation_id,
683: p_object_version_number => p_object_version_number);
684: IF p_validate = TRUE THEN
683: p_object_version_number => p_object_version_number);
684: IF p_validate = TRUE THEN
685: raise hr_api.validate_enabled;
686: END IF;
687: hr_utility.set_location(' Leaving:'||l_proc, 40);
688: EXCEPTION
689: when hr_api.validate_enabled then
690: --
691: -- As the Validate_Enabled exception has been raised
690: --
691: -- As the Validate_Enabled exception has been raised
692: -- we must rollback to the savepoint
693: --
694: hr_utility.set_location(' Leaving:'||l_proc, 41);
695: ROLLBACK TO delete_emp_stat_situation;
696: When Others THEN
697: Rollback to delete_emp_stat_situation;
698: hr_utility.set_location(' Leaving:'||l_proc, 42);
694: hr_utility.set_location(' Leaving:'||l_proc, 41);
695: ROLLBACK TO delete_emp_stat_situation;
696: When Others THEN
697: Rollback to delete_emp_stat_situation;
698: hr_utility.set_location(' Leaving:'||l_proc, 42);
699: fnd_message.raise_error;
700: END DELETE_EMP_STAT_SITUATION;
701: --
702: --
719: l_upd_sit_ovn NUMBER(9);
720: l_new_sit_id NUMBER(15);
721: l_new_sit_ovn NUMBER(9);
722: BEGIN
723: hr_utility.set_location('Entering:'|| l_proc, 10);
724: savepoint renew_emp_stat_situation;
725: OPEN csr_current_situation_dtls(p_emp_stat_situation_id);
726: FETCH csr_current_situation_dtls INTO lr_currec;
727: CLOSE csr_current_situation_dtls;
756: ,p_object_version_number => l_new_sit_ovn);
757: IF p_validate = TRUE THEN
758: raise hr_api.validate_enabled;
759: END IF;
760: hr_utility.set_location(' Leaving:'||l_proc, 40);
761: EXCEPTION
762: when hr_api.validate_enabled then
763: --
764: -- As the Validate_Enabled exception has been raised
763: --
764: -- As the Validate_Enabled exception has been raised
765: -- we must rollback to the savepoint
766: --
767: hr_utility.set_location(' Leaving:'||l_proc, 41);
768: ROLLBACK TO renew_emp_stat_situation;
769: When Others THEN
770: Rollback to renew_emp_stat_situation;
771: hr_utility.set_location(' Leaving:'||l_proc, 42);
767: hr_utility.set_location(' Leaving:'||l_proc, 41);
768: ROLLBACK TO renew_emp_stat_situation;
769: When Others THEN
770: Rollback to renew_emp_stat_situation;
771: hr_utility.set_location(' Leaving:'||l_proc, 42);
772: fnd_message.raise_error;
773: end renew_emp_stat_situation;
774: procedure reinstate_emp_stat_situation
775: ( P_VALIDATE IN BOOLEAN DEFAULT FALSE
795: AND person_Id = p_person_id
796: AND p_eff_date BETWEEN provisional_start_date and provisional_end_date;
797: l_next_sit_end_dt DATE;
798: BEGIN
799: hr_utility.set_location('Entering:'|| l_proc, 10);
800: savepoint reinstate_emp_stat_situation;
801: --Modified by deenath. Changed parameters 'IN' and 'IN_N' to 'IA' and 'IA_N' resp.
802: l_reinstate_sit_id:= pqh_fr_stat_sit_util.get_dflt_situation(p_business_group_id => hr_general.get_business_group_id,
803: p_effective_date => p_reinstate_date,
836: ,p_object_version_number => l_new_sit_ovn);
837: IF p_validate = TRUE THEN
838: raise hr_api.validate_enabled;
839: END IF;
840: hr_utility.set_location(' Leaving:'||l_proc, 40);
841: EXCEPTION
842: when hr_api.validate_enabled then
843: --
844: -- As the Validate_Enabled exception has been raised
843: --
844: -- As the Validate_Enabled exception has been raised
845: -- we must rollback to the savepoint
846: --
847: hr_utility.set_location(' Leaving:'||l_proc, 41);
848: ROLLBACK TO reinstate_emp_stat_situation;
849: When Others THEN
850: Rollback to reinstate_emp_stat_situation;
851: hr_utility.set_location(' Leaving:'||l_proc, 42);
847: hr_utility.set_location(' Leaving:'||l_proc, 41);
848: ROLLBACK TO reinstate_emp_stat_situation;
849: When Others THEN
850: Rollback to reinstate_emp_stat_situation;
851: hr_utility.set_location(' Leaving:'||l_proc, 42);
852: fnd_message.raise_error;
853: END REINSTATE_EMP_STAT_SITUATION;
854: --
855: end PQH_FR_EMP_STAT_SITUATION_API;