33: l_wlq_status VARCHAR2(50);
34: BEGIN
35:
36: IF (l_debug_Level <= 2) THEN
37: cln_debug_pub.Add('M4U:----- Entering RAISE_WLQ_EVENT ------- ',2);
38: END IF;
39:
40: -- Parameters received
41: IF (l_Debug_Level <= 1) THEN
38: END IF;
39:
40: -- Parameters received
41: IF (l_Debug_Level <= 1) THEN
42: cln_debug_pub.Add('== PARAMETERS RECEIVED FROM CONCURRENT PROGRAM== ',1);
43: cln_debug_pub.Add('p_wlq_tye - '||p_wlq_type ,1);
44: cln_debug_pub.Add('p_wlq_status - '||p_wlq_status,1);
45: cln_debug_pub.Add('=====================================',1);
46: END IF;
39:
40: -- Parameters received
41: IF (l_Debug_Level <= 1) THEN
42: cln_debug_pub.Add('== PARAMETERS RECEIVED FROM CONCURRENT PROGRAM== ',1);
43: cln_debug_pub.Add('p_wlq_tye - '||p_wlq_type ,1);
44: cln_debug_pub.Add('p_wlq_status - '||p_wlq_status,1);
45: cln_debug_pub.Add('=====================================',1);
46: END IF;
47:
40: -- Parameters received
41: IF (l_Debug_Level <= 1) THEN
42: cln_debug_pub.Add('== PARAMETERS RECEIVED FROM CONCURRENT PROGRAM== ',1);
43: cln_debug_pub.Add('p_wlq_tye - '||p_wlq_type ,1);
44: cln_debug_pub.Add('p_wlq_status - '||p_wlq_status,1);
45: cln_debug_pub.Add('=====================================',1);
46: END IF;
47:
48: IF (p_wlq_type = 'Batch Notification')THEN
41: IF (l_Debug_Level <= 1) THEN
42: cln_debug_pub.Add('== PARAMETERS RECEIVED FROM CONCURRENT PROGRAM== ',1);
43: cln_debug_pub.Add('p_wlq_tye - '||p_wlq_type ,1);
44: cln_debug_pub.Add('p_wlq_status - '||p_wlq_status,1);
45: cln_debug_pub.Add('=====================================',1);
46: END IF;
47:
48: IF (p_wlq_type = 'Batch Notification')THEN
49: l_wlq_type := 'BatchNotification';
59: l_wlq_status := 'UNREAD' ;
60: END IF;
61:
62: IF (l_Debug_Level <= 1) THEN
63: cln_debug_pub.Add('== PARAMETERS DEFAULTED == ',1);
64: cln_debug_pub.Add('l_wlq_tye - '||l_wlq_type ,1);
65: cln_debug_pub.Add('l_wlq_status - '||l_wlq_status,1);
66: cln_debug_pub.Add('=====================================',1);
67: END IF;
60: END IF;
61:
62: IF (l_Debug_Level <= 1) THEN
63: cln_debug_pub.Add('== PARAMETERS DEFAULTED == ',1);
64: cln_debug_pub.Add('l_wlq_tye - '||l_wlq_type ,1);
65: cln_debug_pub.Add('l_wlq_status - '||l_wlq_status,1);
66: cln_debug_pub.Add('=====================================',1);
67: END IF;
68:
61:
62: IF (l_Debug_Level <= 1) THEN
63: cln_debug_pub.Add('== PARAMETERS DEFAULTED == ',1);
64: cln_debug_pub.Add('l_wlq_tye - '||l_wlq_type ,1);
65: cln_debug_pub.Add('l_wlq_status - '||l_wlq_status,1);
66: cln_debug_pub.Add('=====================================',1);
67: END IF;
68:
69: -- obtain a unique event-id
62: IF (l_Debug_Level <= 1) THEN
63: cln_debug_pub.Add('== PARAMETERS DEFAULTED == ',1);
64: cln_debug_pub.Add('l_wlq_tye - '||l_wlq_type ,1);
65: cln_debug_pub.Add('l_wlq_status - '||l_wlq_status,1);
66: cln_debug_pub.Add('=====================================',1);
67: END IF;
68:
69: -- obtain a unique event-id
70: SELECT m4u_wlqid_s.NEXTVAL
96: p_name => 'ECX_TRANSACTION_TYPE',
97: p_value => 'M4U',
98: p_parameterlist => l_event_parameters );
99: IF (l_Debug_Level <= 1) THEN
100: cln_debug_pub.Add('ECX_TRANSACTION_TYPE - M4U',1);
101: END IF;
102:
103: wf_event.AddParameterToList(
104: p_name => 'ECX_TRANSACTION_SUBTYPE',
104: p_name => 'ECX_TRANSACTION_SUBTYPE',
105: p_value => 'WLQ',
106: p_parameterlist => l_event_parameters );
107: IF (l_Debug_Level <= 1) THEN
108: cln_debug_pub.Add('ECX_TRANSACTION_SUBTYPE - GBREGQRY',1);
109: END IF;
110:
111: wf_event.AddParameterToList(
112: p_name => 'ECX_DOCUMENT_ID',
112: p_name => 'ECX_DOCUMENT_ID',
113: p_value => l_event_key,
114: p_parameterlist => l_event_parameters );
115: IF (l_Debug_Level <= 1) THEN
116: cln_debug_pub.Add('ECX_DOCUMENT_ID - '||l_event_key,1);
117: END IF;
118:
119: wf_event.AddParameterToList(
120: p_name => 'ECX_EVENT_KEY',
120: p_name => 'ECX_EVENT_KEY',
121: p_value => l_event_key,
122: p_parameterlist => l_event_parameters );
123: IF (l_Debug_Level <= 1) THEN
124: cln_debug_pub.Add('ECX_EVENT_KEY - '||l_event_key,1);
125: END IF;
126:
127: wf_event.AddParameterToList(
128: p_name => 'M4U_CLN_COLL_TYPE',
128: p_name => 'M4U_CLN_COLL_TYPE',
129: p_value => 'M4U_WLQ',
130: p_parameterlist => l_event_parameters );
131: IF (l_Debug_Level <= 1) THEN
132: cln_debug_pub.Add('M4U_CLN_COLL_TYPE - '||l_event_key,1);
133: END IF;
134:
135:
136: wf_event.AddParameterToList(
137: p_name => 'M4U_DOC_NO',
138: p_value => l_event_key,
139: p_parameterlist => l_event_parameters );
140: IF (l_Debug_Level <= 1) THEN
141: cln_debug_pub.Add('M4U_DOC_NO - '||l_event_key,1);
142: END IF;
143:
144: wf_event.AddParameterToList(
145: p_name => 'M4U_CLN_DOC_TYPE',
145: p_name => 'M4U_CLN_DOC_TYPE',
146: p_value => 'M4U_WLQ',
147: p_parameterlist => l_event_parameters );
148: IF (l_Debug_Level <= 1) THEN
149: cln_debug_pub.Add('M4U_CLN_DOC_TYPE - M4U_WLQ',1);
150: END IF;
151:
152:
153: wf_event.AddParameterToList(
154: p_name => 'ATTRIBUTE1',
155: p_value => m4u_ucc_utils.g_host_gln,
156: p_parameterlist => l_event_parameters );
157: IF (l_Debug_Level <= 1) THEN
158: cln_debug_pub.Add('ATTRIBUTE1 - '||m4u_ucc_utils.g_host_gln,1);
159: END IF;
160:
161:
162: wf_event.AddParameterToList(
163: p_name => 'ATTRIBUTE5',
164: p_value => m4u_ucc_utils.g_supp_gln,
165: p_parameterlist => l_event_parameters );
166: IF (l_Debug_Level <= 1) THEN
167: cln_debug_pub.Add('ATTRIBUTE5 - '||m4u_ucc_utils.g_supp_gln,1);
168: END IF;
169:
170:
171: wf_event.AddParameterToList(
172: p_name => 'ATTRIBUTE12',
173: p_value => l_event_key,
174: p_parameterlist => l_event_parameters );
175: IF (l_Debug_Level <= 1) THEN
176: cln_debug_pub.Add('ATTRIBUTE12 - '||l_event_key,1);
177: END IF;
178:
179:
180: -- set event parameters, end
179:
180: -- set event parameters, end
181:
182: IF (l_Debug_Level <= 1) THEN
183: cln_debug_pub.Add('== Raising Event oracle.apps.m4u.outboundwf.generate == ',1);
184: cln_debug_pub.Add('p_event_key - '||l_event_key ,1);
185: END IF;
186:
187:
180: -- set event parameters, end
181:
182: IF (l_Debug_Level <= 1) THEN
183: cln_debug_pub.Add('== Raising Event oracle.apps.m4u.outboundwf.generate == ',1);
184: cln_debug_pub.Add('p_event_key - '||l_event_key ,1);
185: END IF;
186:
187:
188: -- raise event to trigger outbound wlq generation WF
197: x_errbuf := 'Successful';
198: x_retcode := 0;
199:
200: IF (l_Debug_Level <= 2) THEN
201: cln_debug_pub.Add('M4U:------- Exiting RAISE_WLQ_EVENT - Normal --------- ',2);
202: END IF;
203:
204:
205: -- Exception Handling
209: l_error_msg :=SQLERRM;
210: x_retcode :=2 ;
211: x_errbuf :='Unexpected Error in raise Query-Worklist event - '||l_error_code||' : '||l_error_msg;
212: IF (l_Debug_Level <= 5) THEN
213: cln_debug_pub.Add(x_errbuf,5);
214: END IF;
215: IF (l_Debug_Level <= 2) THEN
216: cln_debug_pub.Add('------- Exiting RAISE_WLQ_EVENT - Exception --------- ',2);
217: END IF;
212: IF (l_Debug_Level <= 5) THEN
213: cln_debug_pub.Add(x_errbuf,5);
214: END IF;
215: IF (l_Debug_Level <= 2) THEN
216: cln_debug_pub.Add('------- Exiting RAISE_WLQ_EVENT - Exception --------- ',2);
217: END IF;
218: END;
219:
220: BEGIN