1: PACKAGE BODY PO_NOTIFICATION_CTRL_DRAFT_PVT AS
2: /* $Header: PO_NOTIFICATION_CTRL_DRAFT_PVT.plb 120.2 2005/07/26 16:21 bao noship $ */
3:
4: d_pkg_name CONSTANT varchar2(50) :=
5: PO_LOG.get_package_base('PO_NOTIFICATION_CTRL_DRAFT_PVT');
6:
7: -----------------------------------------------------------------------
8: --Start of Comments
9: --Name: draft_changes_exist
51: l_dft_exists_index_tbl PO_TBL_NUMBER := PO_TBL_NUMBER();
52:
53: BEGIN
54: d_position := 0;
55: IF (PO_LOG.d_proc) THEN
56: PO_LOG.proc_begin(d_module);
57: END IF;
58:
59: l_index_tbl.extend(p_draft_id_tbl.COUNT);
52:
53: BEGIN
54: d_position := 0;
55: IF (PO_LOG.d_proc) THEN
56: PO_LOG.proc_begin(d_module);
57: END IF;
58:
59: l_index_tbl.extend(p_draft_id_tbl.COUNT);
60: l_dft_exists_tbl.extend(p_draft_id_tbl.COUNT);
100: FOR i IN 1..l_dft_exists_index_tbl.COUNT LOOP
101: l_dft_exists_tbl(l_dft_exists_index_tbl(i)) := FND_API.G_TRUE;
102: END LOOP;
103:
104: IF (PO_LOG.d_stmt) THEN
105: PO_LOG.stmt(d_module, d_position, '# of records that have dft changes',
106: l_dft_exists_index_tbl.COUNT);
107: END IF;
108:
101: l_dft_exists_tbl(l_dft_exists_index_tbl(i)) := FND_API.G_TRUE;
102: END LOOP;
103:
104: IF (PO_LOG.d_stmt) THEN
105: PO_LOG.stmt(d_module, d_position, '# of records that have dft changes',
106: l_dft_exists_index_tbl.COUNT);
107: END IF;
108:
109: RETURN l_dft_exists_tbl;
152:
153: l_exists_tbl PO_TBL_VARCHAR1;
154: BEGIN
155: d_position := 0;
156: IF (PO_LOG.d_proc) THEN
157: PO_LOG.proc_begin(d_module);
158: END IF;
159:
160: l_exists_tbl :=
153: l_exists_tbl PO_TBL_VARCHAR1;
154: BEGIN
155: d_position := 0;
156: IF (PO_LOG.d_proc) THEN
157: PO_LOG.proc_begin(d_module);
158: END IF;
159:
160: l_exists_tbl :=
161: draft_changes_exist
162: ( p_draft_id_tbl => PO_TBL_NUMBER(p_draft_id),
163: p_notification_id_tbl => PO_TBL_NUMBER(p_notification_id)
164: );
165:
166: IF (PO_LOG.d_stmt) THEN
167: PO_LOG.stmt(d_module, d_position, 'exists', l_exists_tbl(1));
168: END IF;
169:
170: RETURN l_exists_tbl(1);
163: p_notification_id_tbl => PO_TBL_NUMBER(p_notification_id)
164: );
165:
166: IF (PO_LOG.d_stmt) THEN
167: PO_LOG.stmt(d_module, d_position, 'exists', l_exists_tbl(1));
168: END IF;
169:
170: RETURN l_exists_tbl(1);
171:
209: d_position NUMBER;
210:
211: BEGIN
212: d_position := 0;
213: IF (PO_LOG.d_proc) THEN
214: PO_LOG.proc_begin(d_module);
215: END IF;
216:
217: IF (p_draft_info.notification_ctrl_changed = FND_API.G_FALSE) THEN
210:
211: BEGIN
212: d_position := 0;
213: IF (PO_LOG.d_proc) THEN
214: PO_LOG.proc_begin(d_module);
215: END IF;
216:
217: IF (p_draft_info.notification_ctrl_changed = FND_API.G_FALSE) THEN
218: IF (PO_LOG.d_stmt) THEN
214: PO_LOG.proc_begin(d_module);
215: END IF;
216:
217: IF (p_draft_info.notification_ctrl_changed = FND_API.G_FALSE) THEN
218: IF (PO_LOG.d_stmt) THEN
219: PO_LOG.stmt(d_module, d_position, 'no change-no need to apply');
220: END IF;
221:
222: RETURN;
215: END IF;
216:
217: IF (p_draft_info.notification_ctrl_changed = FND_API.G_FALSE) THEN
218: IF (PO_LOG.d_stmt) THEN
219: PO_LOG.stmt(d_module, d_position, 'no change-no need to apply');
220: END IF;
221:
222: RETURN;
223: END IF;