381: --
382: begin
383: --
384: if fnd_api.to_boolean( p_init_msg_list ) then
385: fnd_msg_pub.initialize;
386: end if;
387: --
388: x_return_status := fnd_api.g_ret_sts_success;
389: --
428: end if;
429: --
430: end loop;
431: --
432: if fnd_msg_pub.check_msg_level( fnd_msg_pub.g_msg_lvl_success ) then
433: fnd_message.set_name('CS','CS_SR_MULTIPLE_TASK_TEMP_GRP');
434: fnd_message.set_token('TGT_NAMES', l_task_temp_grp_names);
435: fnd_msg_pub.add_detail(p_message_type => fnd_msg_pub.G_WARNING_MSG);
436: end if;
431: --
432: if fnd_msg_pub.check_msg_level( fnd_msg_pub.g_msg_lvl_success ) then
433: fnd_message.set_name('CS','CS_SR_MULTIPLE_TASK_TEMP_GRP');
434: fnd_message.set_token('TGT_NAMES', l_task_temp_grp_names);
435: fnd_msg_pub.add_detail(p_message_type => fnd_msg_pub.G_WARNING_MSG);
436: end if;
437: elsif l_task_template_group_tbl.count = 1 then
438: l_new_task_group_template_id := l_task_template_group_tbl(0).task_template_group_id;
439: for i in c_task_template_id
452: open c_task_temp_grp_name(l_new_task_group_template_id);
453: fetch c_task_temp_grp_name into l_task_temp_grp_name;
454: close c_task_temp_grp_name;
455: --
456: if fnd_msg_pub.check_msg_level( fnd_msg_pub.g_msg_lvl_success ) then
457: fnd_message.set_name('CS', 'CS_SR_TASK_TEMP_GRP_MISMATCH');
458: fnd_message.set_token('TGT_NAME', l_task_temp_grp_name);
459: fnd_msg_pub.add_detail(p_message_type => fnd_msg_pub.G_WARNING_MSG);
460: end if;
455: --
456: if fnd_msg_pub.check_msg_level( fnd_msg_pub.g_msg_lvl_success ) then
457: fnd_message.set_name('CS', 'CS_SR_TASK_TEMP_GRP_MISMATCH');
458: fnd_message.set_token('TGT_NAME', l_task_temp_grp_name);
459: fnd_msg_pub.add_detail(p_message_type => fnd_msg_pub.G_WARNING_MSG);
460: end if;
461: --
462: end if;
463: end if;
465: end if;
466: --
467: end if;
468:
469: fnd_msg_pub.count_and_get
470: ( p_count => x_msg_count
471: , p_data => x_msg_data
472: );
473:
476: --
477: when fnd_api.g_exc_error then
478: --
479: x_return_status := fnd_api.g_ret_sts_success;
480: if fnd_msg_pub.check_msg_level( fnd_msg_pub.g_msg_lvl_success ) then
481: fnd_message.set_name('CS', 'CS_SR_TASK_TEMP_GRP_API_ERROR');
482: fnd_msg_pub.add_detail(p_message_type => fnd_msg_pub.G_WARNING_MSG);
483: end if;
484: --
478: --
479: x_return_status := fnd_api.g_ret_sts_success;
480: if fnd_msg_pub.check_msg_level( fnd_msg_pub.g_msg_lvl_success ) then
481: fnd_message.set_name('CS', 'CS_SR_TASK_TEMP_GRP_API_ERROR');
482: fnd_msg_pub.add_detail(p_message_type => fnd_msg_pub.G_WARNING_MSG);
483: end if;
484: --
485: fnd_msg_pub.count_and_get
486: ( p_count => x_msg_count
481: fnd_message.set_name('CS', 'CS_SR_TASK_TEMP_GRP_API_ERROR');
482: fnd_msg_pub.add_detail(p_message_type => fnd_msg_pub.G_WARNING_MSG);
483: end if;
484: --
485: fnd_msg_pub.count_and_get
486: ( p_count => x_msg_count
487: , p_data => x_msg_data
488: );
489: when fnd_api.g_exc_unexpected_error then
488: );
489: when fnd_api.g_exc_unexpected_error then
490: --
491: x_return_status := fnd_api.g_ret_sts_success;
492: if fnd_msg_pub.check_msg_level( fnd_msg_pub.g_msg_lvl_success ) then
493: fnd_message.set_name('CS', 'CS_SR_TASK_TEMP_GRP_API_ERROR');
494: fnd_msg_pub.add_detail(p_message_type => fnd_msg_pub.G_WARNING_MSG);
495: end if;
496: --
490: --
491: x_return_status := fnd_api.g_ret_sts_success;
492: if fnd_msg_pub.check_msg_level( fnd_msg_pub.g_msg_lvl_success ) then
493: fnd_message.set_name('CS', 'CS_SR_TASK_TEMP_GRP_API_ERROR');
494: fnd_msg_pub.add_detail(p_message_type => fnd_msg_pub.G_WARNING_MSG);
495: end if;
496: --
497: fnd_msg_pub.count_and_get
498: ( p_count => x_msg_count
493: fnd_message.set_name('CS', 'CS_SR_TASK_TEMP_GRP_API_ERROR');
494: fnd_msg_pub.add_detail(p_message_type => fnd_msg_pub.G_WARNING_MSG);
495: end if;
496: --
497: fnd_msg_pub.count_and_get
498: ( p_count => x_msg_count
499: , p_data => x_msg_data
500: );
501: when others then
508: close c_task_temp_grp_name;
509: end if;
510: --
511: x_return_status := fnd_api.g_ret_sts_success;
512: if fnd_msg_pub.check_msg_level( fnd_msg_pub.g_msg_lvl_success ) then
513: fnd_message.set_name('CS', 'CS_SR_TASK_TEMP_GRP_API_ERROR');
514: fnd_msg_pub.add_detail(p_message_type => fnd_msg_pub.G_WARNING_MSG);
515: end if;
516: --
510: --
511: x_return_status := fnd_api.g_ret_sts_success;
512: if fnd_msg_pub.check_msg_level( fnd_msg_pub.g_msg_lvl_success ) then
513: fnd_message.set_name('CS', 'CS_SR_TASK_TEMP_GRP_API_ERROR');
514: fnd_msg_pub.add_detail(p_message_type => fnd_msg_pub.G_WARNING_MSG);
515: end if;
516: --
517: fnd_msg_pub.count_and_get
518: ( p_count => x_msg_count
513: fnd_message.set_name('CS', 'CS_SR_TASK_TEMP_GRP_API_ERROR');
514: fnd_msg_pub.add_detail(p_message_type => fnd_msg_pub.G_WARNING_MSG);
515: end if;
516: --
517: fnd_msg_pub.count_and_get
518: ( p_count => x_msg_count
519: , p_data => x_msg_data
520: );
521: --
959: x_return_status => x_return_status);
960:
961: EXCEPTION
962: WHEN OTHERS THEN
963: fnd_msg_pub.Count_and_Get
964: (
965: p_count => x_msg_count,
966: p_data => x_msg_data
967: );
972: Exception
973:
974: WHEN fnd_api.g_exc_error THEN
975: x_return_status := 'E';
976: fnd_msg_pub.Count_and_Get
977: (
978: p_count => x_msg_count,
979: p_data => x_msg_data
980: );
980: );
981:
982: WHEN fnd_api.g_exc_unexpected_error THEN
983: x_return_status := 'U';
984: fnd_msg_pub.Count_and_Get
985: (
986: p_count => x_msg_count,
987: p_data => x_msg_data
988: );
1062: x_return_status => x_return_status);
1063:
1064: EXCEPTION
1065: WHEN OTHERS THEN
1066: fnd_msg_pub.Count_and_Get
1067: (
1068: p_count => x_msg_count,
1069: p_data => x_msg_data
1070: );
1099: Exception
1100:
1101: WHEN fnd_api.g_exc_error THEN
1102: x_return_status := 'E';
1103: fnd_msg_pub.Count_and_Get
1104: (
1105: p_count => x_msg_count,
1106: p_data => x_msg_data
1107: );
1107: );
1108:
1109: WHEN fnd_api.g_exc_unexpected_error THEN
1110: x_return_status := 'U';
1111: fnd_msg_pub.Count_and_Get
1112: (
1113: p_count => x_msg_count,
1114: p_data => x_msg_data
1115: );