76: END IF;
77:
78: -- error out if supply source type id is null
79: IF (p_supply_source_type_id is null) THEN
80: fnd_message.set_name('INV', 'INV_NO_SUPPLY_TYPE');
81: fnd_msg_pub.add;
82: RAISE fnd_api.g_exc_error;
83: END IF;
84:
86: IF (p_supply_source_type_id = inv_reservation_global.g_source_type_wip) THEN
87:
88: -- error out if supply source header id is null
89: IF (p_supply_source_header_id is null) THEN
90: fnd_message.set_name('INV','INV_NO_SUPPLY_INFO');
91: fnd_msg_pub.add;
92: RAISE fnd_api.g_exc_error;
93: END IF;
94:
362: p_supply_source_type_id = inv_reservation_global.g_source_type_internal_req) THEN
363:
364: -- error out if supply source header or line id is null
365: IF (p_supply_source_header_id is null or p_supply_source_line_id is null) THEN
366: fnd_message.set_name('INV','INV_NO_SUPPLY_INFO');
367: fnd_msg_pub.add;
368: RAISE fnd_api.g_exc_error;
369: END IF;
370:
370:
371: -- for ASN supply, error if if supply source line detail is null
372: IF (p_supply_source_type_id = inv_reservation_global.g_source_type_asn
373: and p_supply_source_line_detail is null) THEN
374: fnd_message.set_name('INV','INV_NO_SUPPLY_INFO');
375: fnd_msg_pub.add;
376: RAISE fnd_api.g_exc_error;
377: END IF;
378:
514: ELSIF (p_supply_source_type_id = inv_reservation_global.g_source_type_rcv) THEN
515:
516: -- error out if organization_id or item id is null
517: IF (p_organization_id is null or p_item_id is null) THEN
518: fnd_message.set_name('INV', 'INV_NO_ORG_ITEM');
519: fnd_msg_pub.add;
520: RAISE fnd_api.g_exc_error;
521: END IF;
522:
857: END IF;
858:
859: -- error out if demand source type id is null
860: IF (p_demand_source_type_id is null) THEN
861: fnd_message.set_name('INV', 'INV_NO_DEMAND_TYPE');
862: fnd_msg_pub.add;
863: RAISE fnd_api.g_exc_error;
864: END IF;
865:
867: IF (p_demand_source_type_id = inv_reservation_global.g_source_type_wip) THEN
868:
869: -- error out if demand source header id is null
870: IF (p_demand_source_header_id is null) THEN
871: fnd_message.set_name('INV','INV_NO_DEMAND_INFO');
872: fnd_msg_pub.add;
873: RAISE fnd_api.g_exc_error;
874: END IF;
875:
1080: debug_print('demand_source_line_detail: ' || p_demand_source_line_detail);
1081: debug_print('project_id = ' || p_project_id || ' and task_id = ' || p_task_id);
1082: END IF;
1083:
1084: FND_MESSAGE.SET_NAME('INV', 'INV_WDD_NOT_FOUND');
1085: FND_MSG_PUB.ADD;
1086: RAISE fnd_api.g_exc_error;
1087: END;
1088:
1560: EXCEPTION WHEN no_data_found THEN
1561: IF (l_debug = 1) THEN
1562: debug_print('Cannot find the primary unit of measure');
1563: END IF;
1564: FND_MESSAGE.SET_NAME('INV', 'INV_UOM_NOTFOUND');
1565: FND_MSG_PUB.ADD;
1566: RAISE fnd_api.g_exc_error;
1567: END;
1568: END IF;