DBA Data[Home] [Help]

APPS.PA_CONTROL_ITEMS_WORKFLOW dependencies on FND_API

Line 145: x_return_status := FND_API.G_RET_STS_SUCCESS;

141: from dual;
142:
143: x_item_key := To_char(l_item_key);
144:
145: x_return_status := FND_API.G_RET_STS_SUCCESS;
146:
147:
148: --debug_msg ( 'before WF_ENGINE createProcess: ' || p_Process_Name);
149:

Line 166: IF x_return_status = FND_API.g_ret_sts_success then

162: , x_msg_data
163: , x_return_status
164: );
165:
166: IF x_return_status = FND_API.g_ret_sts_success then
167:
168: -- cancle the last running workflow if any
169:
170: OPEN get_last_workflow_info;

Line 238: x_return_status := FND_API.G_RET_STS_ERROR;

234: IF l_err_code <> 0 THEN
235:
236: PA_UTILS.Add_Message( p_app_short_name => 'PA'
237: ,p_msg_name => 'PA_PR_CREATE_WF_FAILED');
238: x_return_status := FND_API.G_RET_STS_ERROR;
239:
240:
241: -- abort the workflow process just launched, there is a problem
242: WF_ENGINE.AbortProcess( p_Item_Type

Line 257: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

253:
254:
255: x_msg_count := 1;
256: x_msg_data := substr(SQLERRM,1,2000);
257: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
258:
259: END start_workflow;
260:
261: /********************************************************************

Line 281: x_return_status := FND_API.G_RET_STS_SUCCESS;

277:
278: BEGIN
279:
280:
281: x_return_status := FND_API.G_RET_STS_SUCCESS;
282:
283: --debug_msg ( 'after client cancel_workflow call' );
284:
285: IF (x_return_status = FND_API.g_ret_sts_success) THEN

Line 285: IF (x_return_status = FND_API.g_ret_sts_success) THEN

281: x_return_status := FND_API.G_RET_STS_SUCCESS;
282:
283: --debug_msg ( 'after client cancel_workflow call' );
284:
285: IF (x_return_status = FND_API.g_ret_sts_success) THEN
286: WF_ENGINE.AbortProcess( p_Item_Type
287: , p_Item_Key
288: );
289:

Line 304: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

300: --debug_msg ( 'Exception in Cancel_Wf ' || substr(SQLERRM,1,2000) );
301:
302: x_msg_count := 1;
303: x_msg_data := substr(SQLERRM,1,2000);
304: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
305:
306: END Cancel_workflow;
307:
308: PROCEDURE change_status_working

Line 360: -- p_encoded => FND_API.G_FALSE));

356:
357: IF l_return_status <> 'S' then
358:
359: --debug_msg_s1('Error: || ' || fnd_msg_pub.get(p_msg_index => 1,
360: -- p_encoded => FND_API.G_FALSE));
361: NULL;
362:
363: END IF;
364:

Line 484: --p_encoded => FND_API.G_FALSE));

480: IF l_return_status <> 'S' then
481:
482: -- #Bug#13683760 changes start.
483: --debug_msg_s1('Error: || ' || fnd_msg_pub.get(p_msg_index => 1,
484: --p_encoded => FND_API.G_FALSE));
485: NULL;
486: l_msg_data := fnd_msg_pub.get(p_msg_index => 1,
487: p_encoded => FND_API.G_FALSE);
488:

Line 487: p_encoded => FND_API.G_FALSE);

483: --debug_msg_s1('Error: || ' || fnd_msg_pub.get(p_msg_index => 1,
484: --p_encoded => FND_API.G_FALSE));
485: NULL;
486: l_msg_data := fnd_msg_pub.get(p_msg_index => 1,
487: p_encoded => FND_API.G_FALSE);
488:
489: wf_engine.SetItemAttrText( itemtype
490: , itemkey
491: , 'ERROR_MSG'

Line 668: -- p_encoded => FND_API.G_FALSE));

664: --debug_msg_s1 ('after approve the ci ' || l_return_status);
665:
666: IF l_return_status <> 'S' then
667: --debug_msg_s1('Error: || ' || fnd_msg_pub.get(p_msg_index => 1,
668: -- p_encoded => FND_API.G_FALSE));
669:
670: -- #Bug#13683760 changes start.
671: l_msg_data := fnd_msg_pub.get(p_msg_index => 1,
672: p_encoded => FND_API.G_FALSE);

Line 672: p_encoded => FND_API.G_FALSE);

668: -- p_encoded => FND_API.G_FALSE));
669:
670: -- #Bug#13683760 changes start.
671: l_msg_data := fnd_msg_pub.get(p_msg_index => 1,
672: p_encoded => FND_API.G_FALSE);
673: wf_engine.SetItemAttrText( itemtype
674: , itemkey
675: , 'ERROR_MSG'
676: , l_msg_data);

Line 1087: if (l_return_status <> FND_API.G_RET_STS_SUCCESS) then

1083: ,x_msg_count => l_msg_count
1084: ,x_msg_data => l_msg_data
1085: );
1086:
1087: if (l_return_status <> FND_API.G_RET_STS_SUCCESS) then
1088: WF_NOTIFICATION.WriteToClob(document, 'Report Content Generation failed');
1089: dbms_lob.writeappend(document, 255, substr(Sqlerrm, 255));
1090: end if;
1091:

Line 1169: x_return_status := FND_API.G_RET_STS_SUCCESS;

1165: WHERE ci_id = c_ci_id;
1166:
1167: BEGIN
1168: x_msg_count := 0;
1169: x_return_status := FND_API.G_RET_STS_SUCCESS;
1170: l_debug_mode := NVL(FND_PROFILE.value('PA_DEBUG_MODE'),'N');
1171:
1172: IF l_debug_mode = 'Y' THEN
1173: pa_debug.set_curr_function( p_function => 'START_NOTIFICATION_WF',

Line 1249: IF (x_return_status <> FND_API.G_RET_STS_SUCCESS) THEN

1245: ,x_msg_data => x_msg_data
1246: );
1247:
1248:
1249: IF (x_return_status <> FND_API.G_RET_STS_SUCCESS) THEN
1250: IF l_debug_mode = 'Y' THEN
1251: pa_debug.g_err_stage:= 'Error calling pa_control_item_workflow.SET_WORKFLOW_ATTRIBUTES';
1252: pa_debug.write('START_NOTIFICATION_WF: ' || l_module_name,pa_debug.g_err_stage,l_debug_level5);
1253:

Line 1289: x_return_status := FND_API.G_RET_STS_ERROR;

1285:
1286: --Log an error message and go to exception section.
1287: PA_UTILS.Add_Message( p_app_short_name => 'PA'
1288: ,p_msg_name => 'PA_PR_CREATE_WF_FAILED');
1289: x_return_status := FND_API.G_RET_STS_ERROR;
1290: Raise Invalid_Arg_Exc_CI;
1291: END IF;
1292:
1293:

Line 1302: x_return_status := FND_API.G_RET_STS_ERROR;

1298: END IF;
1299: EXCEPTION
1300:
1301: WHEN Invalid_Arg_Exc_CI THEN
1302: x_return_status := FND_API.G_RET_STS_ERROR;
1303: l_msg_count := FND_MSG_PUB.count_msg;
1304:
1305: IF get_project_id%ISOPEN THEN
1306: CLOSE get_project_id;

Line 1311: (p_encoded => FND_API.G_TRUE

1307: END IF;
1308:
1309: IF l_msg_count = 1 and x_msg_data IS NULL THEN
1310: PA_INTERFACE_UTILS_PUB.get_messages
1311: (p_encoded => FND_API.G_TRUE
1312: ,p_msg_index => 1
1313: ,p_msg_count => l_msg_count
1314: ,p_msg_data => l_msg_data
1315: ,p_data => l_data

Line 1330: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

1326: RETURN;
1327:
1328: WHEN others THEN
1329:
1330: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1331: x_msg_count := 1;
1332: x_msg_data := SQLERRM;
1333:
1334: IF get_project_id%ISOPEN THEN

Line 1615: x_return_status := FND_API.G_RET_STS_SUCCESS;

1611:
1612: BEGIN
1613:
1614: x_msg_count := 0;
1615: x_return_status := FND_API.G_RET_STS_SUCCESS;
1616: l_debug_mode := NVL(FND_PROFILE.value('PA_DEBUG_MODE'),'N');
1617:
1618: IF l_debug_mode = 'Y' THEN
1619: pa_debug.set_curr_function( p_function => 'set_workflow_attributes',

Line 2128: x_return_status := FND_API.G_RET_STS_ERROR;

2124: END IF;
2125: EXCEPTION
2126:
2127: WHEN Invalid_Arg_Exc_CI THEN
2128: x_return_status := FND_API.G_RET_STS_ERROR;
2129: l_msg_count := FND_MSG_PUB.count_msg;
2130:
2131: IF get_project_info%ISOPEN THEN
2132: CLOSE get_project_info;

Line 2157: (p_encoded => FND_API.G_TRUE

2153: END IF;
2154:
2155: IF l_msg_count = 1 and x_msg_data IS NULL THEN
2156: PA_INTERFACE_UTILS_PUB.get_messages
2157: (p_encoded => FND_API.G_TRUE
2158: ,p_msg_index => 1
2159: ,p_msg_count => l_msg_count
2160: ,p_msg_data => l_msg_data
2161: ,p_data => l_data

Line 2176: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

2172: RETURN;
2173:
2174: WHEN others THEN
2175:
2176: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
2177: x_msg_count := 1;
2178: x_msg_data := SQLERRM;
2179:
2180: IF get_project_info%ISOPEN THEN

Line 2256: l_return_status VARCHAR2(1) :=fnd_api.g_ret_sts_success;

2252: l_num_of_actions number;
2253: l_comment_text varchar2(32767);
2254: l_ci_action_id number;
2255: l_record_version_number number;
2256: l_return_status VARCHAR2(1) :=fnd_api.g_ret_sts_success;
2257: l_msg_count number;
2258: l_msg_data varchar2(2000);
2259: l_user_sign_off VARCHAR2(1):='N';
2260: l_assign_party_id NUMBER; --added for bug# 3877985

Line 2407: p_init_msg_list => fnd_api.g_true,

2403: l_comment_text := ' ';
2404: end if;
2405: PA_CI_ACTIONS_PVT.ADD_CI_COMMENT(
2406: p_api_version => 1.0,
2407: p_init_msg_list => fnd_api.g_true,
2408: p_commit => FND_API.g_false,
2409: p_validate_only => FND_API.g_false,
2410: p_max_msg_count => FND_API.g_miss_num,
2411: p_ci_comment_id => l_ci_comment_id,

Line 2408: p_commit => FND_API.g_false,

2404: end if;
2405: PA_CI_ACTIONS_PVT.ADD_CI_COMMENT(
2406: p_api_version => 1.0,
2407: p_init_msg_list => fnd_api.g_true,
2408: p_commit => FND_API.g_false,
2409: p_validate_only => FND_API.g_false,
2410: p_max_msg_count => FND_API.g_miss_num,
2411: p_ci_comment_id => l_ci_comment_id,
2412: p_ci_id => l_ci_id,

Line 2409: p_validate_only => FND_API.g_false,

2405: PA_CI_ACTIONS_PVT.ADD_CI_COMMENT(
2406: p_api_version => 1.0,
2407: p_init_msg_list => fnd_api.g_true,
2408: p_commit => FND_API.g_false,
2409: p_validate_only => FND_API.g_false,
2410: p_max_msg_count => FND_API.g_miss_num,
2411: p_ci_comment_id => l_ci_comment_id,
2412: p_ci_id => l_ci_id,
2413: p_type_code => 'CLOSURE',

Line 2410: p_max_msg_count => FND_API.g_miss_num,

2406: p_api_version => 1.0,
2407: p_init_msg_list => fnd_api.g_true,
2408: p_commit => FND_API.g_false,
2409: p_validate_only => FND_API.g_false,
2410: p_max_msg_count => FND_API.g_miss_num,
2411: p_ci_comment_id => l_ci_comment_id,
2412: p_ci_id => l_ci_id,
2413: p_type_code => 'CLOSURE',
2414: p_comment_text => l_comment_text,

Line 2428: If (l_return_status = fnd_api.g_ret_sts_success) then

2424: OPEN getRecordVersionNumber;
2425: FETCH getRecordVersionNumber into l_ci_record_version_number;
2426: CLOSE getRecordVersionNumber;
2427:
2428: If (l_return_status = fnd_api.g_ret_sts_success) then
2429:
2430: PA_CONTROL_ITEMS_PVT.UPDATE_NUMBER_OF_ACTIONS (
2431: p_api_version => 1.0,
2432: p_init_msg_list => fnd_api.g_true,

Line 2432: p_init_msg_list => fnd_api.g_true,

2428: If (l_return_status = fnd_api.g_ret_sts_success) then
2429:
2430: PA_CONTROL_ITEMS_PVT.UPDATE_NUMBER_OF_ACTIONS (
2431: p_api_version => 1.0,
2432: p_init_msg_list => fnd_api.g_true,
2433: p_commit => FND_API.g_false,
2434: p_validate_only => FND_API.g_true,
2435: p_max_msg_count => FND_API.g_miss_num,
2436: p_ci_id =>l_CI_ID,

Line 2433: p_commit => FND_API.g_false,

2429:
2430: PA_CONTROL_ITEMS_PVT.UPDATE_NUMBER_OF_ACTIONS (
2431: p_api_version => 1.0,
2432: p_init_msg_list => fnd_api.g_true,
2433: p_commit => FND_API.g_false,
2434: p_validate_only => FND_API.g_true,
2435: p_max_msg_count => FND_API.g_miss_num,
2436: p_ci_id =>l_CI_ID,
2437: p_num_of_actions => -1,

Line 2434: p_validate_only => FND_API.g_true,

2430: PA_CONTROL_ITEMS_PVT.UPDATE_NUMBER_OF_ACTIONS (
2431: p_api_version => 1.0,
2432: p_init_msg_list => fnd_api.g_true,
2433: p_commit => FND_API.g_false,
2434: p_validate_only => FND_API.g_true,
2435: p_max_msg_count => FND_API.g_miss_num,
2436: p_ci_id =>l_CI_ID,
2437: p_num_of_actions => -1,
2438: p_record_version_number =>l_ci_record_version_number,

Line 2435: p_max_msg_count => FND_API.g_miss_num,

2431: p_api_version => 1.0,
2432: p_init_msg_list => fnd_api.g_true,
2433: p_commit => FND_API.g_false,
2434: p_validate_only => FND_API.g_true,
2435: p_max_msg_count => FND_API.g_miss_num,
2436: p_ci_id =>l_CI_ID,
2437: p_num_of_actions => -1,
2438: p_record_version_number =>l_ci_record_version_number,
2439: x_num_of_actions => l_num_of_actions,

Line 2448: if l_return_status = fnd_api.g_ret_sts_success then

2444: p_last_update_login => l_fnd_usr_id --Added for bug# 3877985
2445: );
2446: end if;
2447: -- Commit the changes if requested
2448: if l_return_status = fnd_api.g_ret_sts_success then
2449: commit;
2450: end if;
2451: -- Bug#12859815 start.
2452: START_NOTIFICATION_WF

Line 2462: if(l_return_status <> FND_API.g_ret_sts_success) then

2458: ,x_return_status => l_return_status
2459: ,x_msg_count => l_msg_count
2460: ,x_msg_data => l_msg_data );
2461:
2462: if(l_return_status <> FND_API.g_ret_sts_success) then
2463: raise FND_API.G_EXC_ERROR;
2464: end if;
2465: -- Bug#12859815 end.
2466: resultout := wf_engine.eng_completed||':'||'T';

Line 2463: raise FND_API.G_EXC_ERROR;

2459: ,x_msg_count => l_msg_count
2460: ,x_msg_data => l_msg_data );
2461:
2462: if(l_return_status <> FND_API.g_ret_sts_success) then
2463: raise FND_API.G_EXC_ERROR;
2464: end if;
2465: -- Bug#12859815 end.
2466: resultout := wf_engine.eng_completed||':'||'T';
2467:

Line 2474: EXCEPTION WHEN FND_API.G_EXC_ERROR THEN

2470: -- End Modification for Bug#12839389
2471: commit;
2472:
2473:
2474: EXCEPTION WHEN FND_API.G_EXC_ERROR THEN
2475: ROLLBACK TO CLOSE_CI_ACTION;
2476: resultout := wf_engine.eng_completed||':'||'F';
2477: WHEN OTHERS THEN
2478: ROLLBACK TO CLOSE_CI_ACTION;

Line 2532: l_return_status VARCHAR2(1) :=fnd_api.g_ret_sts_success;

2528: l_num_of_actions number;
2529: l_comment_text varchar2(32767);
2530: l_ci_action_id number;
2531: l_record_version_number number;
2532: l_return_status VARCHAR2(1) :=fnd_api.g_ret_sts_success;
2533: l_msg_count number;
2534: l_msg_data varchar2(2000);
2535: l_assign_party_id NUMBER; --added for bug# 3877985
2536: l_fnd_usr_id NUMBER; --added for bug# 3877985

Line 2621: p_init_msg_list => fnd_api.g_true,

2617: IF is_comment_inserted_cur%NOTFOUND THEN
2618: CLOSE is_comment_inserted_cur;
2619: PA_CI_ACTIONS_PVT.ADD_CI_COMMENT(
2620: p_api_version => 1.0,
2621: p_init_msg_list => fnd_api.g_true,
2622: p_commit => FND_API.g_false,
2623: p_validate_only => FND_API.g_false,
2624: p_max_msg_count => FND_API.g_miss_num,
2625: p_ci_comment_id => l_ci_comment_id,

Line 2622: p_commit => FND_API.g_false,

2618: CLOSE is_comment_inserted_cur;
2619: PA_CI_ACTIONS_PVT.ADD_CI_COMMENT(
2620: p_api_version => 1.0,
2621: p_init_msg_list => fnd_api.g_true,
2622: p_commit => FND_API.g_false,
2623: p_validate_only => FND_API.g_false,
2624: p_max_msg_count => FND_API.g_miss_num,
2625: p_ci_comment_id => l_ci_comment_id,
2626: p_ci_id => l_ci_id,

Line 2623: p_validate_only => FND_API.g_false,

2619: PA_CI_ACTIONS_PVT.ADD_CI_COMMENT(
2620: p_api_version => 1.0,
2621: p_init_msg_list => fnd_api.g_true,
2622: p_commit => FND_API.g_false,
2623: p_validate_only => FND_API.g_false,
2624: p_max_msg_count => FND_API.g_miss_num,
2625: p_ci_comment_id => l_ci_comment_id,
2626: p_ci_id => l_ci_id,
2627: p_type_code => 'UNSOLICITED',

Line 2624: p_max_msg_count => FND_API.g_miss_num,

2620: p_api_version => 1.0,
2621: p_init_msg_list => fnd_api.g_true,
2622: p_commit => FND_API.g_false,
2623: p_validate_only => FND_API.g_false,
2624: p_max_msg_count => FND_API.g_miss_num,
2625: p_ci_comment_id => l_ci_comment_id,
2626: p_ci_id => l_ci_id,
2627: p_type_code => 'UNSOLICITED',
2628: p_comment_text => l_comment_text,

Line 2639: if l_return_status = fnd_api.g_ret_sts_success then

2635: x_msg_data => l_msg_data
2636: );
2637:
2638:
2639: if l_return_status = fnd_api.g_ret_sts_success then
2640: commit;
2641: resultout := wf_engine.eng_completed||':'||'T';
2642: end if;
2643: commit;

Line 2648: EXCEPTION WHEN FND_API.G_EXC_ERROR THEN

2644: ELSE
2645: CLOSE is_comment_inserted_cur;
2646: END IF;
2647:
2648: EXCEPTION WHEN FND_API.G_EXC_ERROR THEN
2649: ROLLBACK TO KEEP_OPEN;
2650: resultout := wf_engine.eng_completed||':'||'F';
2651: WHEN OTHERS THEN
2652: ROLLBACK TO KEEP_OPEN;

Line 2690: x_return_status := FND_API.G_RET_STS_SUCCESS;

2686: and wfi.activity_type_code='NOTICE'
2687: and wfi.activity_status_code='NOTIFIED';
2688:
2689: BEGIN
2690: x_return_status := FND_API.G_RET_STS_SUCCESS;
2691: for nid in get_open_notification(to_char(p_ci_action_id))
2692: loop
2693: WF_NOTIFICATION.CANCEL
2694: ( nid => to_number(nid.notification_id),

Line 2713: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

2709:
2710: WHEN OTHERS THEN
2711: x_msg_count := 1;
2712: x_msg_data := substr(SQLERRM,1,2000);
2713: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
2714: END cancel_notif_and_abort_wf;
2715:
2716:
2717:

Line 2748: x_return_status := FND_API.G_RET_STS_SUCCESS;

2744: l_sign_off_requested VARCHAR2(1);
2745:
2746: BEGIN
2747:
2748: x_return_status := FND_API.G_RET_STS_SUCCESS;
2749:
2750: l_sign_off_requested:= wf_engine.GetItemAttrText
2751: ( itemtype => p_item_type,
2752: itemkey => p_item_key,

Line 2776: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

2772:
2773: WHEN OTHERS THEN
2774: x_msg_count := 1;
2775: x_msg_data := substr(SQLERRM,1,2000);
2776: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
2777:
2778: END close_notification;
2779:
2780: