DBA Data[Home] [Help]

PACKAGE BODY: APPS.IGS_AS_VAL_VE

Source


1 PACKAGE BODY IGS_AS_VAL_VE AS
2 /* $Header: IGSAS37B.pls 115.6 2002/11/28 22:48:31 nsidana ship $ */
3   -------------------------------------------------------------------------------------------
4   --Change History:
5   --Who         When            What
6   --smadathi    27-AUG-2001     Bug No. 1956374 .The function orgp_val_loc_closed removed.Also
7   --                            the reference to igs_as_val_ve.orgp_val_loc_closed is
8   --                            changed to igs_as_val_els.orgp_val_loc_closed
9   -------------------------------------------------------------------------------------------
10   --msrinivi    24-AUG-2001     Bug No. 1956374 .The function genp_val_prsn_id removed
11   -- Validate IGS_AD_LOCATION closed indicator.
12     -- Retrofitted
13   FUNCTION assp_val_ve_lot(
14   p_exam_location_cd  IGS_GR_VENUE_ALL.exam_location_cd%TYPE ,
15   p_message_name OUT NOCOPY VARCHAR2)
16   RETURN BOOLEAN IS
17   	gv_other_detail		VARCHAR2(255);
18   BEGIN	-- assp_val_ve_lot
19   	-- Validate s_loc_type = EXAM_CTR or GRD_CTR
20   DECLARE
21   	CURSOR	c_lot IS
22   	SELECT	'x'
23   	FROM	IGS_AD_LOCATION_TYPE	lot,
24   		IGS_AD_LOCATION	loc
25   	WHERE	lot.location_type	= loc.location_type AND
26   		loc.location_cd		= p_exam_location_cd AND
27   		lot.s_location_type = 'EXAM_CTR' OR
28   		lot.s_location_type = 'GRD_CTR';
29   	v_lot_exists	VARCHAR2(1);
30   BEGIN
31   	-- Set the default message number
32   	 p_message_name := null;
33   	OPEN c_lot;
34   	FETCH c_lot INTO v_lot_exists;
35   	IF (c_lot%NOTFOUND) THEN
36   		CLOSE c_lot;
37   		-- The system IGS_AD_LOCATION type must be specified as EXAM_CTR or GRD_CTR
38   		p_message_name := 'IGS_AS_SYS_LOCTYPE_EXAM_CTR';
39   		RETURN FALSE;
40   	END IF;
41   	CLOSE c_lot;
42   	RETURN TRUE;
43   END;
44   EXCEPTION
45   	WHEN OTHERS THEN
46   	 Fnd_Message.Set_Name('IGS', 'IGS_GE_UNHANDLED_EXP');
47          Fnd_Message.Set_Token('NAME','IGS_AS_VAL_VE.ASSP_VAL_VE_LOT');
48          Igs_Ge_Msg_Stack.Add;
49        App_Exception.Raise_Exception;
50   END assp_val_ve_lot;
51   --
52   -- Retrofitted
53   FUNCTION assp_val_ve_reopen(
54   p_exam_location_cd  IGS_GR_VENUE_ALL.exam_location_cd%TYPE ,
55   p_closed_ind  IGS_GR_VENUE_ALL.closed_ind%TYPE ,
56   p_message_name OUT NOCOPY VARCHAR2)
57   RETURN BOOLEAN IS
58   	gv_other_detail		VARCHAR2(255);
59   BEGIN	-- assp_val_ve_reopen
60   	-- Cannot re-open a IGS_GR_VENUE when the IGS_AD_LOCATION is closed.
61   DECLARE
62   	v_message_name  varchar2(30);
63   BEGIN
64   	-- Set the default message number
65   	 p_message_name := null;
66   	-- If IGS_GR_VENUE is being opened(ie. the p_closed_ind is 'N')
67   	IF (p_closed_ind = 'N')	THEN
68   		IF igs_as_val_els.orgp_val_loc_closed(
69   			p_exam_location_cd,
70   			v_message_name)= FALSE THEN
71   			p_message_name := 'IGS_AS_CANNOT_REOPEN_VENUE';
72   			RETURN FALSE;
73   		END IF;
74   	END IF;
75   	RETURN TRUE;
76   END;
77   EXCEPTION
78   	WHEN OTHERS THEN
79   	 Fnd_Message.Set_Name('IGS', 'IGS_GE_UNHANDLED_EXP');
80          Fnd_Message.Set_Token('NAME','IGS_AS_VAL_VE.ASSP_VAL_VE_REOPEN');
81          Igs_Ge_Msg_Stack.Add;
82        App_Exception.Raise_Exception;
83   END assp_val_ve_reopen;
84   --
85   --
86 
87 END IGS_AS_VAL_VE;