DBA Data[Home] [Help]

APPS.GME_MAKE_TO_ORDER_PVT dependencies on FND_API

Line 40: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

36: (
37: -- errbuf OUT NOCOPY VARCHAR2
38: -- retcode OUT NOCOPY VARCHAR2
39: p_api_version IN NUMBER := 1.0
40: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
41: ,p_commit IN VARCHAR2 := fnd_api.g_false
42: ,p_so_line_id IN NUMBER
43: ) IS
44:

Line 41: ,p_commit IN VARCHAR2 := fnd_api.g_false

37: -- errbuf OUT NOCOPY VARCHAR2
38: -- retcode OUT NOCOPY VARCHAR2
39: p_api_version IN NUMBER := 1.0
40: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
41: ,p_commit IN VARCHAR2 := fnd_api.g_false
42: ,p_so_line_id IN NUMBER
43: ) IS
44:
45: -- Standard constants to be used to check for call compatibility.

Line 178: x_return_status := FND_API.G_RET_STS_SUCCESS;

174: BEGIN
175: l_so_line_id := p_so_line_id;
176: /*Int variables
177: =========================================*/
178: x_return_status := FND_API.G_RET_STS_SUCCESS;
179:
180: IF (g_debug <= gme_debug.g_log_statement) THEN
181: gme_debug.log_initialize ('OPM_MaketoOrder');
182: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' ENTER API ');

Line 193: IF NOT FND_API.compatible_api_call (

189: SAVEPOINT create_batch_for_so_line_SP;
190:
191: /*Standard call to check for call compatibility.
192: ==============================================*/
193: IF NOT FND_API.compatible_api_call (
194: l_api_version,
195: p_api_version,
196: l_api_name,
197: g_pkg_name)

Line 202: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

198: THEN
199: IF (g_debug <= gme_debug.g_log_statement) THEN
200: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' compatability call failure ');
201: END IF;
202: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
203: END IF;
204:
205: FND_FILE.Put_Line(FND_FILE.LOG, ' compatible OK ');
206: /* Check p_init_msg_list

Line 208: IF FND_API.to_boolean(p_init_msg_list)

204:
205: FND_FILE.Put_Line(FND_FILE.LOG, ' compatible OK ');
206: /* Check p_init_msg_list
207: =========================================*/
208: IF FND_API.to_boolean(p_init_msg_list)
209: THEN
210: FND_MSG_PUB.initialize;
211: END IF;
212:

Line 225: RAISE FND_API.G_EXC_ERROR;

221: END IF;
222: FND_MESSAGE.Set_Name('GMI','Missing');
223: FND_MESSAGE.Set_Token('MISSING', 'so_line_id');
224: FND_MSG_PUB.Add;
225: RAISE FND_API.G_EXC_ERROR;
226: END IF;
227: /* ============ IF this line is already reserved to production supply do not process further =========== */
228: IF (g_debug <= gme_debug.g_log_statement) THEN
229: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' Check for existing reservations against GME PROD supply ');

Line 259: RAISE FND_API.G_EXC_ERROR;

255: CLOSE get_so_line_rec;
256: IF (g_debug <= gme_debug.g_log_statement) THEN
257: gme_debug.put_line(g_pkg_name||'.'||l_api_name||'RETURNING - sales order not found for for line_id '||p_so_line_id);
258: END IF;
259: RAISE FND_API.G_EXC_ERROR;
260: END IF;
261: CLOSE get_so_line_rec;
262:
263: /* ============== Establish Item Characteristics ====================*/

Line 275: RAISE FND_API.G_EXC_ERROR;

271: CLOSE cur_item;
272: IF (g_debug <= gme_debug.g_log_statement) THEN
273: gme_debug.put_line(g_pkg_name||'.'||l_api_name||'Failure to retrieve inventory item ');
274: END IF;
275: RAISE FND_API.G_EXC_ERROR;
276: END IF;
277: CLOSE cur_item;
278:
279: /* ============== Determine whether Make to Order Rule exists ===============*/

Line 304: IF( l_return_status <> FND_API.G_RET_STS_SUCCESS ) THEN

300: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' Rule ID to work with is '||l_mto_assignments_rec.rule_id);
301: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' Rule being honored is '||l_mto_rules_rec.rule_name);
302: END IF;
303:
304: IF( l_return_status <> FND_API.G_RET_STS_SUCCESS ) THEN
305: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' Failure to Get_Rule so terminate processing for line '||p_so_line_id);
306: FND_MESSAGE.Set_Name('GMI','Missing');
307: FND_MESSAGE.Set_Token('MISSING', 'rule_id');
308: FND_MSG_PUB.Add;

Line 309: RAISE FND_API.G_EXC_ERROR;

305: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' Failure to Get_Rule so terminate processing for line '||p_so_line_id);
306: FND_MESSAGE.Set_Name('GMI','Missing');
307: FND_MESSAGE.Set_Token('MISSING', 'rule_id');
308: FND_MSG_PUB.Add;
309: RAISE FND_API.G_EXC_ERROR;
310: END IF;
311:
312: IF (NVL(l_mto_rules_rec.rule_id,0) = 0) THEN
313: gme_debug.put_line(g_pkg_name||'.'||l_api_name||'No MAKE to ORDER rule exists to cover order line '||p_so_line_id);

Line 371: IF x_return_status <> fnd_api.g_ret_sts_success THEN

367: || ' Return status from relieve_reservation is '
368: || x_return_status);
369: END IF;
370:
371: IF x_return_status <> fnd_api.g_ret_sts_success THEN
372: RAISE FND_API.G_EXC_ERROR;
373: END IF;
374: l_count := l_count + 1;
375: END LOOP;

Line 372: RAISE FND_API.G_EXC_ERROR;

368: || x_return_status);
369: END IF;
370:
371: IF x_return_status <> fnd_api.g_ret_sts_success THEN
372: RAISE FND_API.G_EXC_ERROR;
373: END IF;
374: l_count := l_count + 1;
375: END LOOP;
376: END IF;

Line 448: , p_init_msg_lst => fnd_api.g_true

444:
445: inv_quantity_tree_pvt.create_tree
446: (
447: p_api_version_number => 1.0
448: , p_init_msg_lst => fnd_api.g_true
449: , x_return_status => l_return_status
450: , x_msg_count => x_msg_count
451: , x_msg_data => x_msg_data
452: , p_organization_id => l_so_line_rec.ship_from_org_id

Line 473: IF l_return_status = fnd_api.g_ret_sts_error THEN

469: IF (g_debug <= gme_debug.g_log_statement) THEN
470: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' After create tree status returned is '||l_return_status);
471: END IF;
472:
473: IF l_return_status = fnd_api.g_ret_sts_error THEN
474: RAISE fnd_api.g_exc_error;
475: END IF;
476:
477: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 474: RAISE fnd_api.g_exc_error;

470: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' After create tree status returned is '||l_return_status);
471: END IF;
472:
473: IF l_return_status = fnd_api.g_ret_sts_error THEN
474: RAISE fnd_api.g_exc_error;
475: END IF;
476:
477: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
478: RAISE fnd_api.g_exc_unexpected_error;

Line 477: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

473: IF l_return_status = fnd_api.g_ret_sts_error THEN
474: RAISE fnd_api.g_exc_error;
475: END IF;
476:
477: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
478: RAISE fnd_api.g_exc_unexpected_error;
479: END IF;
480:
481: IF (g_debug <= gme_debug.g_log_statement) THEN

Line 478: RAISE fnd_api.g_exc_unexpected_error;

474: RAISE fnd_api.g_exc_error;
475: END IF;
476:
477: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
478: RAISE fnd_api.g_exc_unexpected_error;
479: END IF;
480:
481: IF (g_debug <= gme_debug.g_log_statement) THEN
482: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' Query tree for ATR next ');

Line 486: , p_init_msg_lst => fnd_api.g_true

482: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' Query tree for ATR next ');
483: END IF;
484: inv_quantity_tree_pvt.query_tree(
485: p_api_version_number => 1.0
486: , p_init_msg_lst => fnd_api.g_true
487: , x_return_status => l_return_status
488: , x_msg_count => l_msg_count
489: , x_msg_data => l_msg_data
490: , p_tree_id => l_tree_id

Line 513: IF l_return_status = fnd_api.g_ret_sts_error THEN

509:
510: IF (g_debug <= gme_debug.g_log_statement) THEN
511: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' After Query tree return status is '||l_return_status);
512: END IF;
513: IF l_return_status = fnd_api.g_ret_sts_error THEN
514: RAISE fnd_api.g_exc_error;
515: END IF;
516:
517: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 514: RAISE fnd_api.g_exc_error;

510: IF (g_debug <= gme_debug.g_log_statement) THEN
511: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' After Query tree return status is '||l_return_status);
512: END IF;
513: IF l_return_status = fnd_api.g_ret_sts_error THEN
514: RAISE fnd_api.g_exc_error;
515: END IF;
516:
517: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
518: RAISE fnd_api.g_exc_unexpected_error;

Line 517: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

513: IF l_return_status = fnd_api.g_ret_sts_error THEN
514: RAISE fnd_api.g_exc_error;
515: END IF;
516:
517: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
518: RAISE fnd_api.g_exc_unexpected_error;
519: END IF;
520:
521: IF (g_debug <= gme_debug.g_log_statement) THEN

Line 518: RAISE fnd_api.g_exc_unexpected_error;

514: RAISE fnd_api.g_exc_error;
515: END IF;
516:
517: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
518: RAISE fnd_api.g_exc_unexpected_error;
519: END IF;
520:
521: IF (g_debug <= gme_debug.g_log_statement) THEN
522: gme_debug.put_line('l_atr ' || l_atr);

Line 610: p_init_msg_list => fnd_api.g_true,

606: END IF;
607: GME_API_PUB.create_batch(
608: p_api_version => 2.0,
609: p_validation_level => 100,
610: p_init_msg_list => fnd_api.g_true,
611: p_commit => fnd_api.g_false,
612: x_message_count => l_msg_count,
613: x_message_list => l_msg_data,
614: x_return_status => l_return_status,

Line 611: p_commit => fnd_api.g_false,

607: GME_API_PUB.create_batch(
608: p_api_version => 2.0,
609: p_validation_level => 100,
610: p_init_msg_list => fnd_api.g_true,
611: p_commit => fnd_api.g_false,
612: x_message_count => l_msg_count,
613: x_message_list => l_msg_data,
614: x_return_status => l_return_status,
615: p_org_code => NULL,

Line 627: p_ignore_qty_below_cap => fnd_api.g_true,

623: p_recipe_version => NULL,
624: p_product_no => NULL,
625: p_item_revision => NULL,
626: p_product_id => l_so_line_rec.inventory_item_id,
627: p_ignore_qty_below_cap => fnd_api.g_true,
628: p_use_workday_cal => NULL,
629: p_contiguity_override => NULL,
630: p_use_least_cost_validity_rule => fnd_api.g_false,
631: x_exception_material_tbl => l_exception_material_tbl

Line 630: p_use_least_cost_validity_rule => fnd_api.g_false,

626: p_product_id => l_so_line_rec.inventory_item_id,
627: p_ignore_qty_below_cap => fnd_api.g_true,
628: p_use_workday_cal => NULL,
629: p_contiguity_override => NULL,
630: p_use_least_cost_validity_rule => fnd_api.g_false,
631: x_exception_material_tbl => l_exception_material_tbl
632: );
633:
634: IF (g_debug <= gme_debug.g_log_statement) THEN

Line 640: IF( l_return_status <> FND_API.G_RET_STS_SUCCESS ) THEN

636: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' Message from Create_Batch API is '||l_msg_data );
637: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' Batch No from Create_Batch API is '||
638: l_out_batch_header_rec.batch_no);
639: END IF;
640: IF( l_return_status <> FND_API.G_RET_STS_SUCCESS ) THEN
641: j := to_number(NVL(l_msg_count,0));
642: FOR i in 1..j
643: LOOP
644:

Line 645: l_message := fnd_msg_pub.get(p_encoded => FND_API.G_FALSE);

641: j := to_number(NVL(l_msg_count,0));
642: FOR i in 1..j
643: LOOP
644:
645: l_message := fnd_msg_pub.get(p_encoded => FND_API.G_FALSE);
646: l_message := replace(l_message, chr(0), ' ');
647: gme_debug.put_line(l_message);
648: END LOOP;
649: RAISE fnd_api.g_exc_error;

Line 649: RAISE fnd_api.g_exc_error;

645: l_message := fnd_msg_pub.get(p_encoded => FND_API.G_FALSE);
646: l_message := replace(l_message, chr(0), ' ');
647: gme_debug.put_line(l_message);
648: END LOOP;
649: RAISE fnd_api.g_exc_error;
650: END IF;
651:
652: /* Now retrieve the batch product line - sales order line must reserve to this supply
653: ===================================================================================*/

Line 665: RAISE fnd_api.g_exc_error;

661: CLOSE get_batch_line;
662: IF (g_debug <= gme_debug.g_log_statement) THEN
663: gme_debug.put_line('get_batch_line%NOTFOUND, returning from create_batch_for_order_line');
664: END IF;
665: RAISE fnd_api.g_exc_error;
666: END IF;
667: CLOSE get_batch_line;
668:
669: /* Copy Attachments if the rule says so

Line 722: ,p_init_msg_list => fnd_api.g_false

718:
719: GME_API_PUB.create_pending_product_lot
720: (p_api_version => 2.0
721: ,p_validation_level => gme_common_pvt.g_max_errors
722: ,p_init_msg_list => fnd_api.g_false
723: ,p_commit => fnd_api.g_false
724: ,x_message_count => l_msg_count
725: ,x_message_list => l_msg_data
726: ,x_return_status => l_return_status

Line 723: ,p_commit => fnd_api.g_false

719: GME_API_PUB.create_pending_product_lot
720: (p_api_version => 2.0
721: ,p_validation_level => gme_common_pvt.g_max_errors
722: ,p_init_msg_list => fnd_api.g_false
723: ,p_commit => fnd_api.g_false
724: ,x_message_count => l_msg_count
725: ,x_message_list => l_msg_data
726: ,x_return_status => l_return_status
727: ,p_batch_header_rec => l_out_batch_header_rec

Line 729: ,p_create_lot => fnd_api.g_true

725: ,x_message_list => l_msg_data
726: ,x_return_status => l_return_status
727: ,p_batch_header_rec => l_out_batch_header_rec
728: ,p_org_code => NULL
729: ,p_create_lot => fnd_api.g_true
730: ,p_generate_lot => fnd_api.g_true
731: ,p_material_detail_rec => l_material_detail_rec
732: ,p_pending_product_lots_rec => l_pending_product_lots_rec
733: ,x_pending_product_lots_rec => l_out_pending_product_lots_rec);

Line 730: ,p_generate_lot => fnd_api.g_true

726: ,x_return_status => l_return_status
727: ,p_batch_header_rec => l_out_batch_header_rec
728: ,p_org_code => NULL
729: ,p_create_lot => fnd_api.g_true
730: ,p_generate_lot => fnd_api.g_true
731: ,p_material_detail_rec => l_material_detail_rec
732: ,p_pending_product_lots_rec => l_pending_product_lots_rec
733: ,x_pending_product_lots_rec => l_out_pending_product_lots_rec);
734:

Line 735: IF (l_return_status <> FND_API.G_RET_STS_SUCCESS) THEN

731: ,p_material_detail_rec => l_material_detail_rec
732: ,p_pending_product_lots_rec => l_pending_product_lots_rec
733: ,x_pending_product_lots_rec => l_out_pending_product_lots_rec);
734:
735: IF (l_return_status <> FND_API.G_RET_STS_SUCCESS) THEN
736: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' FAILURE to generate pending lot ');
737: END IF;
738: END IF; -- End of pending lot generation
739:

Line 779: ,p_init_msg_lst => fnd_api.g_false

775: END IF;
776:
777: inv_reservation_pub.create_reservation
778: (p_api_version_number => 1.0
779: ,p_init_msg_lst => fnd_api.g_false
780: ,x_return_status => l_return_status
781: ,x_msg_count => l_msg_count
782: ,x_msg_data => l_msg_data
783: ,p_rsv_rec => l_rsv_rec

Line 786: ,p_partial_reservation_flag => fnd_api.g_true

782: ,x_msg_data => l_msg_data
783: ,p_rsv_rec => l_rsv_rec
784: ,p_serial_number => l_in_serial_num
785: ,x_serial_number => l_out_serial_num
786: ,p_partial_reservation_flag => fnd_api.g_true
787: ,p_validation_flag => fnd_api.g_true
788: ,x_quantity_reserved => l_reserved_qty
789: ,x_reservation_id => l_reservation_id
790: ,p_partial_rsv_exists => TRUE);

Line 787: ,p_validation_flag => fnd_api.g_true

783: ,p_rsv_rec => l_rsv_rec
784: ,p_serial_number => l_in_serial_num
785: ,x_serial_number => l_out_serial_num
786: ,p_partial_reservation_flag => fnd_api.g_true
787: ,p_validation_flag => fnd_api.g_true
788: ,x_quantity_reserved => l_reserved_qty
789: ,x_reservation_id => l_reservation_id
790: ,p_partial_rsv_exists => TRUE);
791:

Line 805: (fnd_api.g_ret_sts_error, fnd_api.g_ret_sts_unexp_error) ) THEN

801: || l_reserved_qty );
802: END IF;
803:
804: IF (l_return_status IN
805: (fnd_api.g_ret_sts_error, fnd_api.g_ret_sts_unexp_error) ) THEN
806: RAISE FND_API.G_EXC_ERROR;
807: END IF;
808:
809: /* Notify the customer sales representative of the batch creation

Line 806: RAISE FND_API.G_EXC_ERROR;

802: END IF;
803:
804: IF (l_return_status IN
805: (fnd_api.g_ret_sts_error, fnd_api.g_ret_sts_unexp_error) ) THEN
806: RAISE FND_API.G_EXC_ERROR;
807: END IF;
808:
809: /* Notify the customer sales representative of the batch creation
810: ===============================================================*/

Line 835: IF l_return_status IN (fnd_api.g_ret_sts_error, fnd_api.g_ret_sts_unexp_error) THEN

831: || ' after calling notify_CSR for create reservation status is '
832: || l_return_status );
833: END IF;
834:
835: IF l_return_status IN (fnd_api.g_ret_sts_error, fnd_api.g_ret_sts_unexp_error) THEN
836: IF g_debug <= gme_debug.g_log_procedure THEN
837: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' Exit after Notifications Failure ');
838: END IF;
839: RAISE FND_API.G_EXC_ERROR;

Line 839: RAISE FND_API.G_EXC_ERROR;

835: IF l_return_status IN (fnd_api.g_ret_sts_error, fnd_api.g_ret_sts_unexp_error) THEN
836: IF g_debug <= gme_debug.g_log_procedure THEN
837: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' Exit after Notifications Failure ');
838: END IF;
839: RAISE FND_API.G_EXC_ERROR;
840: END IF;
841:
842: /* Set the user context back to the original user */
843: IF (l_mto_rules_rec.batch_creation_user <> l_user_id) THEN

Line 867: WHEN FND_API.G_EXC_ERROR THEN

863:
864: /* EXCEPTION HANDLING
865: ====================*/
866: EXCEPTION
867: WHEN FND_API.G_EXC_ERROR THEN
868: -- ROLLBACK TO SAVEPOINT create_batch_for_so_line_SP;
869: gme_debug.put_line('sqlcode : ' ||to_char(sqlcode));
870: gme_debug.put_line('sqlerr : '|| SUBSTRB(SQLERRM, 1, 150));
871: x_return_status := FND_API.G_RET_STS_ERROR;

Line 871: x_return_status := FND_API.G_RET_STS_ERROR;

867: WHEN FND_API.G_EXC_ERROR THEN
868: -- ROLLBACK TO SAVEPOINT create_batch_for_so_line_SP;
869: gme_debug.put_line('sqlcode : ' ||to_char(sqlcode));
870: gme_debug.put_line('sqlerr : '|| SUBSTRB(SQLERRM, 1, 150));
871: x_return_status := FND_API.G_RET_STS_ERROR;
872: -- errbuf := SUBSTRB(SQLERRM, 1, 150);
873: -- retcode := x_return_status;
874:
875: FND_MSG_PUB.Add_Exc_Msg ( g_pkg_name

Line 878: FND_MSG_PUB.Count_AND_GET ( p_encoded => FND_API.G_FALSE

874:
875: FND_MSG_PUB.Add_Exc_Msg ( g_pkg_name
876: , l_api_name
877: );
878: FND_MSG_PUB.Count_AND_GET ( p_encoded => FND_API.G_FALSE
879: , p_count => x_msg_count
880: , p_data => x_msg_data
881: );
882:

Line 883: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

879: , p_count => x_msg_count
880: , p_data => x_msg_data
881: );
882:
883: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
884: -- ROLLBACK TO SAVEPOINT create_batch_for_so_line_SP;
885: gme_debug.put_line('sqlcode : ' ||to_char(sqlcode));
886: gme_debug.put_line('sqlerr : '|| SUBSTRB(SQLERRM, 1, 150));
887:

Line 888: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

884: -- ROLLBACK TO SAVEPOINT create_batch_for_so_line_SP;
885: gme_debug.put_line('sqlcode : ' ||to_char(sqlcode));
886: gme_debug.put_line('sqlerr : '|| SUBSTRB(SQLERRM, 1, 150));
887:
888: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
889: -- errbuf := SUBSTRB(SQLERRM, 1, 150);
890: -- retcode := x_return_status;
891:
892:

Line 896: FND_MSG_PUB.Count_AND_GET ( p_encoded=> FND_API.G_FALSE

892:
893: FND_MSG_PUB.Add_Exc_Msg ( g_pkg_name
894: , l_api_name
895: );
896: FND_MSG_PUB.Count_AND_GET ( p_encoded=> FND_API.G_FALSE
897: , p_count => x_msg_count
898: , p_data => x_msg_data
899: );
900: WHEN OTHERS THEN

Line 909: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

905: FND_MSG_PUB.Add_Exc_Msg ( g_pkg_name
906: , l_api_name
907: );
908:
909: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
910: -- errbuf := SUBSTRB(SQLERRM, 1, 150);
911: -- retcode := x_return_status;
912:
913: /* Get message count and data */

Line 1014: x_return_status := FND_API.G_RET_STS_SUCCESS;

1010: , X_doc_attribute14 => so_attchments_row.DOC_ATTRIBUTE14
1011: , X_doc_attribute15 => so_attchments_row.DOC_ATTRIBUTE15
1012: , X_create_doc => 'Y' --- Default is 'N'
1013: );
1014: x_return_status := FND_API.G_RET_STS_SUCCESS;
1015: END LOOP;
1016:
1017: gme_debug.put_line('Exiting copy_attachments procedure without any errors');
1018: EXCEPTION

Line 1021: x_return_status := FND_API.G_RET_STS_ERROR;

1017: gme_debug.put_line('Exiting copy_attachments procedure without any errors');
1018: EXCEPTION
1019: WHEN OTHERS THEN
1020: GMI_RESERVATION_UTIL.Println('In others exception in copy_attachments');
1021: x_return_status := FND_API.G_RET_STS_ERROR;
1022: END Copy_attachments;
1023:
1024: FUNCTION line_qualifies_for_MTO (
1025: p_line_id IN NUMBER

Line 1106: IF( l_return_status <> FND_API.G_RET_STS_SUCCESS ) or (NVL(l_mto_assignments_rec.rule_id,0) = 0) THEN

1102: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' Rule ID to work with is '||l_mto_assignments_rec.rule_id);
1103: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' Rule being honored is '||l_mto_rules_rec.rule_name);
1104: END IF;
1105:
1106: IF( l_return_status <> FND_API.G_RET_STS_SUCCESS ) or (NVL(l_mto_assignments_rec.rule_id,0) = 0) THEN
1107: Return FALSE;
1108: ELSE
1109: Return TRUE;
1110: END IF;

Line 1166: x_return_status := FND_API.G_RET_STS_SUCCESS;

1162: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' item_type '||p_mto_assignments_rec.item_type);
1163: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' customer_id '||p_mto_assignments_rec.customer_id);
1164: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' site_use_id '||p_mto_assignments_rec.site_use_id);
1165: END IF;
1166: x_return_status := FND_API.G_RET_STS_SUCCESS;
1167: /* get the most suitable rule first */
1168: GMI_reservation_Util.PrintLn('IN check Rule');
1169: Open get_assignment;
1170: Fetch get_assignment

Line 1192: RAISE FND_API.G_EXC_ERROR;

1188: Fetch get_rule into l_mto_rules_rec;
1189: IF(get_rule%NOTFOUND) THEN
1190: CLOSE get_rule;
1191: gme_debug.put_line('Error encountered on rule retrieval for Rule ID '||l_mto_assignments_rec.rule_id);
1192: RAISE FND_API.G_EXC_ERROR;
1193: END IF;
1194: Close get_rule;
1195:
1196: x_mto_rules_rec := l_mto_rules_rec;