DBA Data[Home] [Help]

APPS.INV_MAINTAIN_RESERVATION_PUB dependencies on FND_API

Line 113: IF (NVL(p_param_value,FND_API.G_MISS_NUM) = FND_API.G_MISS_NUM) THEN

109: IF (l_debug = 1) THEN
110: mydebug('Checking API ' || p_api_name || ' , ' || p_param_name || ': ' || p_param_value, c_api_name, 9);
111: END IF;
112:
113: IF (NVL(p_param_value,FND_API.G_MISS_NUM) = FND_API.G_MISS_NUM) THEN
114: IF (l_debug = 1) THEN
115: mydebug('In ' || p_api_name ||', '|| p_param_name ||' is required parameter, value is g_miss_num', c_api_name, 9);
116: END IF;
117: FND_MESSAGE.SET_NAME('INV','INV_API_MISSING_PARAM');

Line 121: RAISE FND_API.G_EXC_ERROR;

117: FND_MESSAGE.SET_NAME('INV','INV_API_MISSING_PARAM');
118: FND_MESSAGE.SET_TOKEN('API_NAME',p_api_name);
119: FND_MESSAGE.SET_TOKEN('MISSING_PARAM',p_param_name);
120: FND_MSG_PUB.Add;
121: RAISE FND_API.G_EXC_ERROR;
122: END IF;
123: END Check_Reqd_Param;
124:
125: PROCEDURE Check_Reqd_Param (

Line 144: IF (NVL(p_param_value,FND_API.G_MISS_CHAR) = FND_API.G_MISS_CHAR) THEN

140: IF (l_debug = 1) THEN
141: mydebug('Checking API ' || p_api_name || ' , ' || p_param_name || ': ' || p_param_value, c_api_name, 9);
142: END IF;
143:
144: IF (NVL(p_param_value,FND_API.G_MISS_CHAR) = FND_API.G_MISS_CHAR) THEN
145: IF (l_debug = 1) THEN
146: mydebug('In ' || p_api_name || ', ' || p_param_name || ' is required parameter, value is g_miss_char', c_api_name, 9);
147: END IF;
148:

Line 155: RAISE FND_API.G_EXC_ERROR;

151: FND_MESSAGE.SET_NAME('INV','INV_API_MISSING_PARAM');
152: FND_MESSAGE.SET_TOKEN('API_NAME',p_api_name);
153: FND_MESSAGE.SET_TOKEN('MISSING_PARAM',p_param_name);
154: FND_MSG_PUB.Add;
155: RAISE FND_API.G_EXC_ERROR;
156: END IF;
157: END Check_Reqd_Param;
158:
159: PROCEDURE Check_Reqd_Param (

Line 179: IF (NVL(p_param_value,FND_API.G_MISS_DATE) = FND_API.G_MISS_DATE) THEN

175: mydebug('Checking API ' || p_api_name || ' , ' || p_param_name || ': ' ||
176: TO_CHAR(p_param_value, 'YYYY-MM-DD:DD:SS'), c_api_name, 9);
177: END IF;
178:
179: IF (NVL(p_param_value,FND_API.G_MISS_DATE) = FND_API.G_MISS_DATE) THEN
180: IF (l_debug = 1) THEN
181: mydebug('In ' || p_api_name || ', ' || p_param_name || ' is required parameter, value is g_miss_date',
182: c_api_name, 9);
183: END IF;

Line 189: RAISE FND_API.G_EXC_ERROR;

185: FND_MESSAGE.SET_NAME('INV','INV_API_MISSING_PARAM');
186: FND_MESSAGE.SET_TOKEN('API_NAME',p_api_name);
187: FND_MESSAGE.SET_TOKEN('MISSING_PARAM',p_param_name);
188: FND_MSG_PUB.Add;
189: RAISE FND_API.G_EXC_ERROR;
190: END IF;
191: END Check_Reqd_Param;
192:
193:

Line 261: l_return_status varchar2(1) := fnd_api.g_ret_sts_success;

257: l_from_primary_transaction_qty number;
258: l_msg_index_out number;
259: l_staged_rec_exists varchar2(1) ;
260:
261: l_return_status varchar2(1) := fnd_api.g_ret_sts_success;
262: l_msg_count number;
263: l_msg_data varchar2(1000);
264: l_wip_entity_type_id number;
265: l_wip_job_type varchar2(15);

Line 283: x_return_status := fnd_api.g_ret_sts_success;

279:
280: end if;
281:
282: -- initialize x_return_status variable to success in the begning of api
283: x_return_status := fnd_api.g_ret_sts_success;
284: -- standard call to check for call compatibility
285: if not fnd_api.compatible_api_call(c_api_version_number
286: , p_api_version_number
287: , c_api_name

Line 285: if not fnd_api.compatible_api_call(c_api_version_number

281:
282: -- initialize x_return_status variable to success in the begning of api
283: x_return_status := fnd_api.g_ret_sts_success;
284: -- standard call to check for call compatibility
285: if not fnd_api.compatible_api_call(c_api_version_number
286: , p_api_version_number
287: , c_api_name
288: , g_pkg_name
289: ) then

Line 290: raise fnd_api.g_exc_unexpected_error;

286: , p_api_version_number
287: , c_api_name
288: , g_pkg_name
289: ) then
290: raise fnd_api.g_exc_unexpected_error;
291: end if;
292:
293: -- initialize message list. null value for p_init_msg_lst variable will be treated as 'n'
294: -- codereview.su.05 remove nvl function

Line 295: if fnd_api.to_boolean(p_init_msg_lst) then

291: end if;
292:
293: -- initialize message list. null value for p_init_msg_lst variable will be treated as 'n'
294: -- codereview.su.05 remove nvl function
295: if fnd_api.to_boolean(p_init_msg_lst) then
296: fnd_msg_pub.initialize;
297: end if;
298:
299: if (g_debug= c_debug_enabled) then

Line 336: , p_init_msg_lst => fnd_api.g_false

332: mydebug ('before calling get_wip_entity_type' , c_api_name, 9);
333: end if;
334: inv_reservation_pvt.get_wip_entity_type
335: ( p_api_version_number => 1.0
336: , p_init_msg_lst => fnd_api.g_false
337: , x_return_status => l_return_status
338: , x_msg_count => l_msg_count
339: , x_msg_data => l_msg_data
340: , p_organization_id => p_mtl_maintain_rsv_rec.organization_id

Line 354: if (l_return_status = fnd_api.g_ret_sts_error) then

350: if (g_debug = c_debug_enabled) then
351: mydebug('status return from get_wip_entity = ' || l_return_status, c_api_name, 9);
352: mydebug('l_wip_entity_type = ' || l_wip_entity_type_id, c_api_name, 9);
353: end if;
354: if (l_return_status = fnd_api.g_ret_sts_error) then
355: raise fnd_api.g_exc_error;
356: elsif (l_return_status = fnd_api.g_ret_sts_unexp_error) then
357: raise fnd_api.g_exc_unexpected_error;
358: end if;

Line 355: raise fnd_api.g_exc_error;

351: mydebug('status return from get_wip_entity = ' || l_return_status, c_api_name, 9);
352: mydebug('l_wip_entity_type = ' || l_wip_entity_type_id, c_api_name, 9);
353: end if;
354: if (l_return_status = fnd_api.g_ret_sts_error) then
355: raise fnd_api.g_exc_error;
356: elsif (l_return_status = fnd_api.g_ret_sts_unexp_error) then
357: raise fnd_api.g_exc_unexpected_error;
358: end if;
359: end if;

Line 356: elsif (l_return_status = fnd_api.g_ret_sts_unexp_error) then

352: mydebug('l_wip_entity_type = ' || l_wip_entity_type_id, c_api_name, 9);
353: end if;
354: if (l_return_status = fnd_api.g_ret_sts_error) then
355: raise fnd_api.g_exc_error;
356: elsif (l_return_status = fnd_api.g_ret_sts_unexp_error) then
357: raise fnd_api.g_exc_unexpected_error;
358: end if;
359: end if;
360:

Line 357: raise fnd_api.g_exc_unexpected_error;

353: end if;
354: if (l_return_status = fnd_api.g_ret_sts_error) then
355: raise fnd_api.g_exc_error;
356: elsif (l_return_status = fnd_api.g_ret_sts_unexp_error) then
357: raise fnd_api.g_exc_unexpected_error;
358: end if;
359: end if;
360:
361: if (g_debug = c_debug_enabled) then

Line 518: raise fnd_api.g_exc_error;

514: fnd_message.set_name('inv','inv_api_invalid_param_value');
515: fnd_message.set_token('param_name','action');
516: fnd_message.set_token('param_value',p_mtl_maintain_rsv_rec.action);
517: fnd_msg_pub.add;
518: raise fnd_api.g_exc_error;
519:
520: end if;
521: -- query the reservation records for supply based on sort by criteria passed by user.
522:

Line 528: p_mtl_maintain_rsv_rec.project_id <> fnd_api.g_miss_num) THEN

524: mydebug ('calling query reservation' ,c_api_name,1);
525: end if;
526:
527: IF (p_mtl_maintain_rsv_rec.project_id IS NOT NULL AND
528: p_mtl_maintain_rsv_rec.project_id <> fnd_api.g_miss_num) THEN
529: l_query_input.project_id := p_mtl_maintain_rsv_rec.project_id;
530: END IF;
531:
532: IF (p_mtl_maintain_rsv_rec.task_id IS NOT NULL AND

Line 533: p_mtl_maintain_rsv_rec.task_id<> fnd_api.g_miss_num) THEN

529: l_query_input.project_id := p_mtl_maintain_rsv_rec.project_id;
530: END IF;
531:
532: IF (p_mtl_maintain_rsv_rec.task_id IS NOT NULL AND
533: p_mtl_maintain_rsv_rec.task_id<> fnd_api.g_miss_num) THEN
534: l_query_input.task_id := p_mtl_maintain_rsv_rec.task_id;
535: END IF;
536:
537: inv_reservation_pvt.query_reservation(

Line 556: if x_return_status = fnd_api.g_ret_sts_error then

552: mydebug('totol number of records returned' || l_mtl_reservation_tbl_count, c_api_name,1);
553: end if;
554:
555: -- check if query reservation has raised any errors, if so raise exception
556: if x_return_status = fnd_api.g_ret_sts_error then
557: l_fnd_log_message := 'error while calling query_reservation api :';
558: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
559:
560: if g_debug= c_debug_enabled then

Line 564: raise fnd_api.g_exc_error;

560: if g_debug= c_debug_enabled then
561: mydebug(l_fnd_log_message, c_api_name,9);
562: end if;
563:
564: raise fnd_api.g_exc_error;
565: elsif x_return_status = fnd_api.g_ret_sts_unexp_error then
566: l_fnd_log_message := 'error while calling query_reservation api :';
567: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
568:

Line 565: elsif x_return_status = fnd_api.g_ret_sts_unexp_error then

561: mydebug(l_fnd_log_message, c_api_name,9);
562: end if;
563:
564: raise fnd_api.g_exc_error;
565: elsif x_return_status = fnd_api.g_ret_sts_unexp_error then
566: l_fnd_log_message := 'error while calling query_reservation api :';
567: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
568:
569: if g_debug = c_debug_enabled then

Line 572: raise fnd_api.g_exc_unexpected_error;

568:
569: if g_debug = c_debug_enabled then
570: mydebug(l_fnd_log_message, c_api_name,9);
571: end if;
572: raise fnd_api.g_exc_unexpected_error;
573: end if;
574:
575: -- check if there are any records returned by query_reservation
576: if l_mtl_reservation_tbl_count <= 0 then

Line 660: raise fnd_api.g_exc_error;

656: mydebug ('Staged reservation exists. Error out' ,c_api_name,1);
657: end if;
658: fnd_message.set_name('INV','INV_RSV_REC_IN_STAGING');
659: fnd_msg_pub.add;
660: raise fnd_api.g_exc_error;
661: end if;
662:
663: -- dbms_output.put_line('delete flag is yes');
664: for i in 1..l_mtl_reservation_tbl_count loop

Line 682: l_is_transfer_supply := fnd_api.g_true ;

678: l_to_rsv_rec.supply_source_header_id := l_original_rsv_rec.supply_source_header_id;
679: l_to_rsv_rec.supply_source_line_id := l_original_rsv_rec.supply_source_line_id;
680: --codereview.su.11 assign supply_source_line_detail value too
681: l_to_rsv_rec.supply_source_line_detail := l_original_rsv_rec.supply_source_line_detail;
682: l_is_transfer_supply := fnd_api.g_true ;
683: -- codereview.su.12 comment out else statement. not required
684: /**************************
685: else
686: l_to_rsv_rec.demand_source_type_id := inv_reservation_global.g_source_type_po ;

Line 690: l_is_transfer_supply := fnd_api.g_false;

686: l_to_rsv_rec.demand_source_type_id := inv_reservation_global.g_source_type_po ;
687: l_to_rsv_rec.demand_source_header_id := l_original_rsv_rec.demand_source_header_id;
688: l_to_rsv_rec.demand_source_line_id := l_original_rsv_rec.demand_source_line_id;
689: l_to_rsv_rec.demand_source_delivery := null;
690: l_is_transfer_supply := fnd_api.g_false;
691: ***************************/
692: end if;
693: -- ignoring serial numbers assingment since serial numbers are not changed
694: -- reservation is transfered from one document type to another one.

Line 705: p_init_msg_lst => fnd_api.g_false ,

701: end if;
702:
703: inv_reservation_pvt.transfer_reservation (
704: p_api_version_number => 1.0 ,
705: p_init_msg_lst => fnd_api.g_false ,
706: x_return_status => x_return_status,
707: x_msg_count => x_msg_count,
708: x_msg_data => x_msg_data,
709: --p_is_transfer_supply => l_is_transfer_supply,

Line 714: p_validation_flag => fnd_api.g_true ,

710: p_original_rsv_rec => l_original_rsv_rec ,
711: p_to_rsv_rec => l_to_rsv_rec ,
712: p_original_serial_number => l_original_serial_number,
713: -- p_to_serial_number => l_to_serial_number,
714: p_validation_flag => fnd_api.g_true ,
715: x_reservation_id => l_reservation_id ) ;
716: -- check if transfer reservation has raised any errors, if so raise exception
717: if (g_debug= c_debug_enabled) then
718: mydebug ('After calling transfer: ' || x_return_status ,c_api_name,1);

Line 720: if x_return_status = fnd_api.g_ret_sts_error then

716: -- check if transfer reservation has raised any errors, if so raise exception
717: if (g_debug= c_debug_enabled) then
718: mydebug ('After calling transfer: ' || x_return_status ,c_api_name,1);
719: end if;
720: if x_return_status = fnd_api.g_ret_sts_error then
721: l_fnd_log_message := 'error while calling transfer_reservation api :';
722: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
723: if g_debug= c_debug_enabled then
724: mydebug(l_fnd_log_message, c_api_name,9);

Line 726: raise fnd_api.g_exc_error;

722: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
723: if g_debug= c_debug_enabled then
724: mydebug(l_fnd_log_message, c_api_name,9);
725: end if;
726: raise fnd_api.g_exc_error;
727: elsif x_return_status = fnd_api.g_ret_sts_unexp_error then
728: l_fnd_log_message := 'error while calling transfer_reservation api :';
729: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
730: if g_debug= c_debug_enabled then

Line 727: elsif x_return_status = fnd_api.g_ret_sts_unexp_error then

723: if g_debug= c_debug_enabled then
724: mydebug(l_fnd_log_message, c_api_name,9);
725: end if;
726: raise fnd_api.g_exc_error;
727: elsif x_return_status = fnd_api.g_ret_sts_unexp_error then
728: l_fnd_log_message := 'error while calling transfer_reservation api :';
729: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
730: if g_debug= c_debug_enabled then
731: mydebug(l_fnd_log_message, c_api_name,9);

Line 733: raise fnd_api.g_exc_unexpected_error;

729: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
730: if g_debug= c_debug_enabled then
731: mydebug(l_fnd_log_message, c_api_name,9);
732: end if;
733: raise fnd_api.g_exc_unexpected_error;
734: elsif x_return_status = fnd_api.g_ret_sts_success then
735: l_fnd_log_message := 'calling transfer_reservation api was successful:';
736: -- fnd_log_debug(fnd_log.level_event,c_module_name, l_fnd_log_message );
737: if g_debug= c_debug_enabled then

Line 734: elsif x_return_status = fnd_api.g_ret_sts_success then

730: if g_debug= c_debug_enabled then
731: mydebug(l_fnd_log_message, c_api_name,9);
732: end if;
733: raise fnd_api.g_exc_unexpected_error;
734: elsif x_return_status = fnd_api.g_ret_sts_success then
735: l_fnd_log_message := 'calling transfer_reservation api was successful:';
736: -- fnd_log_debug(fnd_log.level_event,c_module_name, l_fnd_log_message );
737: if g_debug= c_debug_enabled then
738: mydebug(l_fnd_log_message, c_api_name,9);

Line 751: p_init_msg_lst => fnd_api.g_false ,

747: l_original_rsv_rec.reservation_id := l_mtl_reservation_tbl(i).reservation_id ;
748: -- delete reservation record
749: inv_reservation_pvt.delete_reservation(
750: p_api_version_number => 1.0 ,
751: p_init_msg_lst => fnd_api.g_false ,
752: x_return_status => x_return_status,
753: x_msg_count => x_msg_count,
754: x_msg_data => x_msg_data,
755: p_rsv_rec => l_original_rsv_rec ,

Line 757: p_validation_flag => fnd_api.g_true);

753: x_msg_count => x_msg_count,
754: x_msg_data => x_msg_data,
755: p_rsv_rec => l_original_rsv_rec ,
756: p_original_serial_number => l_original_serial_number,
757: p_validation_flag => fnd_api.g_true);
758:
759: if (g_debug= c_debug_enabled) then
760: mydebug ('After calling delete: ' || x_return_status ,c_api_name,1);
761: end if;

Line 763: if x_return_status = fnd_api.g_ret_sts_error then

759: if (g_debug= c_debug_enabled) then
760: mydebug ('After calling delete: ' || x_return_status ,c_api_name,1);
761: end if;
762: -- check if delete reservation has raised any errors, if so raise exception
763: if x_return_status = fnd_api.g_ret_sts_error then
764: l_fnd_log_message := 'error while calling delete_reservation api :';
765: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
766: if g_debug= c_debug_enabled then
767: mydebug(l_fnd_log_message, c_api_name,9);

Line 769: raise fnd_api.g_exc_error;

765: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
766: if g_debug= c_debug_enabled then
767: mydebug(l_fnd_log_message, c_api_name,9);
768: end if;
769: raise fnd_api.g_exc_error;
770: elsif x_return_status = fnd_api.g_ret_sts_unexp_error then
771: l_fnd_log_message := 'error while calling delete_reservation api :';
772: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
773: if g_debug= c_debug_enabled then

Line 770: elsif x_return_status = fnd_api.g_ret_sts_unexp_error then

766: if g_debug= c_debug_enabled then
767: mydebug(l_fnd_log_message, c_api_name,9);
768: end if;
769: raise fnd_api.g_exc_error;
770: elsif x_return_status = fnd_api.g_ret_sts_unexp_error then
771: l_fnd_log_message := 'error while calling delete_reservation api :';
772: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
773: if g_debug= c_debug_enabled then
774: mydebug(l_fnd_log_message, c_api_name,9);

Line 776: raise fnd_api.g_exc_unexpected_error;

772: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
773: if g_debug= c_debug_enabled then
774: mydebug(l_fnd_log_message, c_api_name,9);
775: end if;
776: raise fnd_api.g_exc_unexpected_error;
777: elsif x_return_status = fnd_api.g_ret_sts_success then
778: l_fnd_log_message := 'calling delete_reservation api was successful:';
779: -- fnd_log_debug(fnd_log.level_event,c_module_name, l_fnd_log_message );
780: if g_debug= c_debug_enabled then

Line 777: elsif x_return_status = fnd_api.g_ret_sts_success then

773: if g_debug= c_debug_enabled then
774: mydebug(l_fnd_log_message, c_api_name,9);
775: end if;
776: raise fnd_api.g_exc_unexpected_error;
777: elsif x_return_status = fnd_api.g_ret_sts_success then
778: l_fnd_log_message := 'calling delete_reservation api was successful:';
779: -- fnd_log_debug(fnd_log.level_event,c_module_name, l_fnd_log_message );
780: if g_debug= c_debug_enabled then
781: mydebug(l_fnd_log_message, c_api_name,9);

Line 799: p_mtl_maintain_rsv_rec.expected_quantity_uom = fnd_api.g_miss_char then

795: end if;
796: if nvl(p_mtl_maintain_rsv_rec.expected_quantity,0) > 0 then
797: -- dbms_output.put_line('expected qty is > 0');
798: if p_mtl_maintain_rsv_rec.expected_quantity_uom is null or
799: p_mtl_maintain_rsv_rec.expected_quantity_uom = fnd_api.g_miss_char then
800: -- codereview.su.13. raise error
801: check_reqd_param
802: (
803: p_param_value => p_mtl_maintain_rsv_rec.expected_quantity_uom,

Line 807: raise fnd_api.g_exc_error ;

803: p_param_value => p_mtl_maintain_rsv_rec.expected_quantity_uom,
804: p_param_name => 'p_mtl_maintain_rsv_rec.expected_quantity_uom',
805: p_api_name => c_api_name );
806: -- dbms_output.put_line('raising error as expected qty uom is null');
807: raise fnd_api.g_exc_error ;
808: -- commenting following lines
809: -- it is assumed that expected qty uom is same as primary qty uom
810: -- l_primary_expected_qty := p_mtl_maintain_rsv_rec.expected_quantity ;
811: else -- expected_quantity_uom is not null

Line 814: p_mtl_maintain_rsv_rec.to_primary_uom_code = fnd_api.g_miss_char then

810: -- l_primary_expected_qty := p_mtl_maintain_rsv_rec.expected_quantity ;
811: else -- expected_quantity_uom is not null
812: -- dbms_output.put_line('expected qty uom is not null');
813: if p_mtl_maintain_rsv_rec.to_primary_uom_code is null or
814: p_mtl_maintain_rsv_rec.to_primary_uom_code = fnd_api.g_miss_char then
815: -- in such cases we will take primary uom code of the first record
816: -- and assuming that for all the records primary uom code will be same as
817: -- inventory_item_id and organization_id will be same
818: l_primary_uom_code := l_mtl_reservation_tbl(1).primary_uom_code ;

Line 880: p_mtl_maintain_rsv_rec.from_primary_txn_quantity = fnd_api.g_miss_num then

876: mydebug('from txn uom code: ' ||p_mtl_maintain_rsv_rec.from_transaction_uom_code,c_api_name,9);
877:
878: END IF;
879: if p_mtl_maintain_rsv_rec.from_primary_txn_quantity is null or
880: p_mtl_maintain_rsv_rec.from_primary_txn_quantity = fnd_api.g_miss_num then
881: --codereview.su.16 check if from_transaction_uom_code and from_primary_uom_code
882: -- is not null, if they are then raise error
883:
884: -- from_primary_uom_code column is a required column

Line 932: p_mtl_maintain_rsv_rec.to_primary_txn_quantity = fnd_api.g_miss_num then

928: mydebug('to txn uom code: ' || p_mtl_maintain_rsv_rec.to_transaction_uom_code, c_api_name,9);
929:
930: END IF;
931: if p_mtl_maintain_rsv_rec.to_primary_txn_quantity is null or
932: p_mtl_maintain_rsv_rec.to_primary_txn_quantity = fnd_api.g_miss_num then
933: -- to_primary_uom_code column is a required column
934: check_reqd_param
935: (
936: p_param_value => p_mtl_maintain_rsv_rec.to_primary_uom_code,

Line 1021: l_is_transfer_supply := fnd_api.g_true ;

1017: l_to_rsv_rec.supply_source_header_id:= l_mtl_reservation_tbl(i).supply_source_header_id;
1018: l_to_rsv_rec.supply_source_line_id:= l_mtl_reservation_tbl(i).supply_source_line_id;
1019: l_to_rsv_rec.supply_source_line_detail:= l_mtl_reservation_tbl(i).supply_source_line_detail;
1020:
1021: l_is_transfer_supply := fnd_api.g_true ;
1022: else
1023: l_to_rsv_rec.demand_source_type_id := l_mtl_reservation_tbl(i).demand_source_type_id ;
1024: l_to_rsv_rec.demand_source_header_id:= l_mtl_reservation_tbl(i).demand_source_header_id;
1025: l_to_rsv_rec.demand_source_line_id:= l_mtl_reservation_tbl(i).demand_source_line_id;

Line 1027: l_is_transfer_supply := fnd_api.g_false;

1023: l_to_rsv_rec.demand_source_type_id := l_mtl_reservation_tbl(i).demand_source_type_id ;
1024: l_to_rsv_rec.demand_source_header_id:= l_mtl_reservation_tbl(i).demand_source_header_id;
1025: l_to_rsv_rec.demand_source_line_id:= l_mtl_reservation_tbl(i).demand_source_line_id;
1026: l_to_rsv_rec.demand_source_delivery := null;
1027: l_is_transfer_supply := fnd_api.g_false;
1028: end if;
1029: l_to_rsv_rec.primary_reservation_quantity := Nvl(l_mtl_reservation_tbl(i).primary_reservation_quantity,0)
1030: - l_primary_need_reduced_qty;
1031: IF g_debug= c_debug_enabled then

Line 1038: p_init_msg_lst => fnd_api.g_false,

1034: END IF;
1035: inv_reservation_pvt.update_reservation
1036: (
1037: p_api_version_number => 1.0,
1038: p_init_msg_lst => fnd_api.g_false,
1039: x_return_status => x_return_status,
1040: x_msg_count => x_msg_count,
1041: x_msg_data => x_msg_data ,
1042: p_original_rsv_rec => l_original_rsv_rec,

Line 1046: p_validation_flag => fnd_api.g_true ,

1042: p_original_rsv_rec => l_original_rsv_rec,
1043: p_to_rsv_rec => l_to_rsv_rec,
1044: p_original_serial_number => l_original_serial_number,
1045: p_to_serial_number => l_to_serial_number,
1046: p_validation_flag => fnd_api.g_true ,
1047: p_check_availability => fnd_api.g_false );
1048:
1049: -- check if delete reservation has raised any errors, if so raise exception
1050: if x_return_status = fnd_api.g_ret_sts_error then

Line 1047: p_check_availability => fnd_api.g_false );

1043: p_to_rsv_rec => l_to_rsv_rec,
1044: p_original_serial_number => l_original_serial_number,
1045: p_to_serial_number => l_to_serial_number,
1046: p_validation_flag => fnd_api.g_true ,
1047: p_check_availability => fnd_api.g_false );
1048:
1049: -- check if delete reservation has raised any errors, if so raise exception
1050: if x_return_status = fnd_api.g_ret_sts_error then
1051: l_fnd_log_message := 'error while calling update reservation api 02:';

Line 1050: if x_return_status = fnd_api.g_ret_sts_error then

1046: p_validation_flag => fnd_api.g_true ,
1047: p_check_availability => fnd_api.g_false );
1048:
1049: -- check if delete reservation has raised any errors, if so raise exception
1050: if x_return_status = fnd_api.g_ret_sts_error then
1051: l_fnd_log_message := 'error while calling update reservation api 02:';
1052: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1053: if g_debug= c_debug_enabled then
1054: mydebug(l_fnd_log_message, c_api_name,9);

Line 1056: raise fnd_api.g_exc_error;

1052: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1053: if g_debug= c_debug_enabled then
1054: mydebug(l_fnd_log_message, c_api_name,9);
1055: end if;
1056: raise fnd_api.g_exc_error;
1057: elsif x_return_status = fnd_api.g_ret_sts_unexp_error then
1058: l_fnd_log_message := 'error while calling update reservation api 02:';
1059: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1060: if g_debug= c_debug_enabled then

Line 1057: elsif x_return_status = fnd_api.g_ret_sts_unexp_error then

1053: if g_debug= c_debug_enabled then
1054: mydebug(l_fnd_log_message, c_api_name,9);
1055: end if;
1056: raise fnd_api.g_exc_error;
1057: elsif x_return_status = fnd_api.g_ret_sts_unexp_error then
1058: l_fnd_log_message := 'error while calling update reservation api 02:';
1059: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1060: if g_debug= c_debug_enabled then
1061: mydebug(l_fnd_log_message, c_api_name,9);

Line 1063: raise fnd_api.g_exc_unexpected_error;

1059: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1060: if g_debug= c_debug_enabled then
1061: mydebug(l_fnd_log_message, c_api_name,9);
1062: end if;
1063: raise fnd_api.g_exc_unexpected_error;
1064: elsif x_return_status = fnd_api.g_ret_sts_success then
1065: l_fnd_log_message := 'calling update reservation api was successful -02:';
1066: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1067: if g_debug= c_debug_enabled then

Line 1064: elsif x_return_status = fnd_api.g_ret_sts_success then

1060: if g_debug= c_debug_enabled then
1061: mydebug(l_fnd_log_message, c_api_name,9);
1062: end if;
1063: raise fnd_api.g_exc_unexpected_error;
1064: elsif x_return_status = fnd_api.g_ret_sts_success then
1065: l_fnd_log_message := 'calling update reservation api was successful -02:';
1066: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1067: if g_debug= c_debug_enabled then
1068: mydebug(l_fnd_log_message, c_api_name,9);

Line 1086: p_init_msg_lst => fnd_api.g_false,

1082: -- dbms_output.put_line('calling delete reservation api');
1083: inv_reservation_pvt.delete_reservation
1084: (
1085: p_api_version_number => 1.0,
1086: p_init_msg_lst => fnd_api.g_false,
1087: x_return_status => x_return_status,
1088: x_msg_count => x_msg_count,
1089: x_msg_data => x_msg_data ,
1090: p_rsv_rec => l_original_rsv_rec,

Line 1092: p_validation_flag => fnd_api.g_true );

1088: x_msg_count => x_msg_count,
1089: x_msg_data => x_msg_data ,
1090: p_rsv_rec => l_original_rsv_rec,
1091: p_original_serial_number => l_original_serial_number,
1092: p_validation_flag => fnd_api.g_true );
1093:
1094: -- check if delete reservation has raised any errors, if so raise exception
1095: if x_return_status = fnd_api.g_ret_sts_error then
1096: l_fnd_log_message := 'error while calling delete reservation api 02:';

Line 1095: if x_return_status = fnd_api.g_ret_sts_error then

1091: p_original_serial_number => l_original_serial_number,
1092: p_validation_flag => fnd_api.g_true );
1093:
1094: -- check if delete reservation has raised any errors, if so raise exception
1095: if x_return_status = fnd_api.g_ret_sts_error then
1096: l_fnd_log_message := 'error while calling delete reservation api 02:';
1097: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1098: if g_debug= c_debug_enabled then
1099: mydebug(l_fnd_log_message, c_api_name,9);

Line 1101: raise fnd_api.g_exc_error;

1097: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1098: if g_debug= c_debug_enabled then
1099: mydebug(l_fnd_log_message, c_api_name,9);
1100: end if;
1101: raise fnd_api.g_exc_error;
1102: elsif x_return_status = fnd_api.g_ret_sts_unexp_error then
1103: l_fnd_log_message := 'error while calling delete reservation api 02:';
1104: ---- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1105: if g_debug= c_debug_enabled then

Line 1102: elsif x_return_status = fnd_api.g_ret_sts_unexp_error then

1098: if g_debug= c_debug_enabled then
1099: mydebug(l_fnd_log_message, c_api_name,9);
1100: end if;
1101: raise fnd_api.g_exc_error;
1102: elsif x_return_status = fnd_api.g_ret_sts_unexp_error then
1103: l_fnd_log_message := 'error while calling delete reservation api 02:';
1104: ---- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1105: if g_debug= c_debug_enabled then
1106: mydebug(l_fnd_log_message, c_api_name,9);

Line 1108: raise fnd_api.g_exc_unexpected_error;

1104: ---- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1105: if g_debug= c_debug_enabled then
1106: mydebug(l_fnd_log_message, c_api_name,9);
1107: end if;
1108: raise fnd_api.g_exc_unexpected_error;
1109: elsif x_return_status = fnd_api.g_ret_sts_success then
1110: l_fnd_log_message := 'calling delete reservation api was successful -02:';
1111: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1112: if g_debug= c_debug_enabled then

Line 1109: elsif x_return_status = fnd_api.g_ret_sts_success then

1105: if g_debug= c_debug_enabled then
1106: mydebug(l_fnd_log_message, c_api_name,9);
1107: end if;
1108: raise fnd_api.g_exc_unexpected_error;
1109: elsif x_return_status = fnd_api.g_ret_sts_success then
1110: l_fnd_log_message := 'calling delete reservation api was successful -02:';
1111: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1112: if g_debug= c_debug_enabled then
1113: mydebug(l_fnd_log_message, c_api_name,9);

Line 1142: when fnd_api.g_exc_error then

1138: if g_debug= c_debug_enabled then
1139: mydebug(l_fnd_log_message, c_api_name,9);
1140: end if;
1141: exception
1142: when fnd_api.g_exc_error then
1143: x_return_status := fnd_api.g_ret_sts_error;
1144:
1145: -- get message count and data
1146: fnd_msg_pub.count_and_get

Line 1143: x_return_status := fnd_api.g_ret_sts_error;

1139: mydebug(l_fnd_log_message, c_api_name,9);
1140: end if;
1141: exception
1142: when fnd_api.g_exc_error then
1143: x_return_status := fnd_api.g_ret_sts_error;
1144:
1145: -- get message count and data
1146: fnd_msg_pub.count_and_get
1147: ( p_count => x_msg_count

Line 1185: when fnd_api.g_exc_unexpected_error then

1181: end loop ;
1182: end if;
1183:
1184:
1185: when fnd_api.g_exc_unexpected_error then
1186: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1187:
1188: -- get message count and data
1189: fnd_msg_pub.count_and_get

Line 1186: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1182: end if;
1183:
1184:
1185: when fnd_api.g_exc_unexpected_error then
1186: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1187:
1188: -- get message count and data
1189: fnd_msg_pub.count_and_get
1190: ( p_count => x_msg_count

Line 1228: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1224: end loop ;
1225: end if;
1226:
1227: when others then
1228: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1229:
1230: if fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
1231: then
1232: fnd_msg_pub.add_exc_msg

Line 1458: l_return_status := fnd_api.g_ret_sts_success;

1454: g_version_printed := false ;
1455: end if;
1456:
1457: -- bug 3600118: initialize return status variable
1458: l_return_status := fnd_api.g_ret_sts_success;
1459:
1460: build_res_rec(x_reservation_rec =>l_rsv);
1461:
1462: l_rsv.inventory_item_id := p_inventory_item_id;

Line 1504: , p_init_msg_lst => fnd_api.g_false

1500:
1501: inv_reservation_pvt.create_reservation
1502: (
1503: p_api_version_number => 1.0
1504: , p_init_msg_lst => fnd_api.g_false
1505: , x_return_status => l_return_status
1506: , x_msg_count => x_msg_count
1507: , x_msg_data => x_msg_data
1508: , p_rsv_rec => l_rsv

Line 1511: , p_partial_reservation_flag => fnd_api.g_true

1507: , x_msg_data => x_msg_data
1508: , p_rsv_rec => l_rsv
1509: , p_serial_number => g_dummy_sn_tbl
1510: , x_serial_number => g_dummy_sn_tbl
1511: , p_partial_reservation_flag => fnd_api.g_true
1512: , p_force_reservation_flag => fnd_api.g_false
1513: , p_validation_flag => fnd_api.g_true
1514: --, p_validation_flag => fnd_api.g_false
1515: , x_quantity_reserved => l_qty

Line 1512: , p_force_reservation_flag => fnd_api.g_false

1508: , p_rsv_rec => l_rsv
1509: , p_serial_number => g_dummy_sn_tbl
1510: , x_serial_number => g_dummy_sn_tbl
1511: , p_partial_reservation_flag => fnd_api.g_true
1512: , p_force_reservation_flag => fnd_api.g_false
1513: , p_validation_flag => fnd_api.g_true
1514: --, p_validation_flag => fnd_api.g_false
1515: , x_quantity_reserved => l_qty
1516: , x_secondary_quantity_reserved => l_second_qty

Line 1513: , p_validation_flag => fnd_api.g_true

1509: , p_serial_number => g_dummy_sn_tbl
1510: , x_serial_number => g_dummy_sn_tbl
1511: , p_partial_reservation_flag => fnd_api.g_true
1512: , p_force_reservation_flag => fnd_api.g_false
1513: , p_validation_flag => fnd_api.g_true
1514: --, p_validation_flag => fnd_api.g_false
1515: , x_quantity_reserved => l_qty
1516: , x_secondary_quantity_reserved => l_second_qty
1517: , x_reservation_id => l_rsv_id

Line 1514: --, p_validation_flag => fnd_api.g_false

1510: , x_serial_number => g_dummy_sn_tbl
1511: , p_partial_reservation_flag => fnd_api.g_true
1512: , p_force_reservation_flag => fnd_api.g_false
1513: , p_validation_flag => fnd_api.g_true
1514: --, p_validation_flag => fnd_api.g_false
1515: , x_quantity_reserved => l_qty
1516: , x_secondary_quantity_reserved => l_second_qty
1517: , x_reservation_id => l_rsv_id
1518: );

Line 1527: if x_return_status = fnd_api.g_ret_sts_success then

1523: end if;
1524:
1525: x_return_status := l_return_status;
1526:
1527: if x_return_status = fnd_api.g_ret_sts_success then
1528: l_fnd_log_message := 'calling create_reservation api was successful ';
1529: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1530: if g_debug= c_debug_enabled then
1531: mydebug(l_fnd_log_message, c_api_name,9);

Line 1550: when fnd_api.g_exc_error then

1546: mydebug(l_fnd_log_message, c_api_name,9);
1547: end if;
1548:
1549: exception
1550: when fnd_api.g_exc_error then
1551: x_return_status := fnd_api.g_ret_sts_error;
1552:
1553: -- get message count and data
1554: fnd_msg_pub.count_and_get

Line 1551: x_return_status := fnd_api.g_ret_sts_error;

1547: end if;
1548:
1549: exception
1550: when fnd_api.g_exc_error then
1551: x_return_status := fnd_api.g_ret_sts_error;
1552:
1553: -- get message count and data
1554: fnd_msg_pub.count_and_get
1555: ( p_count => x_msg_count

Line 1593: when fnd_api.g_exc_unexpected_error then

1589: end loop ;
1590: end if;
1591:
1592:
1593: when fnd_api.g_exc_unexpected_error then
1594: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1595:
1596: -- get message count and data
1597: fnd_msg_pub.count_and_get

Line 1594: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1590: end if;
1591:
1592:
1593: when fnd_api.g_exc_unexpected_error then
1594: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1595:
1596: -- get message count and data
1597: fnd_msg_pub.count_and_get
1598: ( p_count => x_msg_count

Line 1636: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1632: end loop ;
1633: end if;
1634:
1635: when others then
1636: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1637:
1638: if fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
1639: then
1640: fnd_msg_pub.add_exc_msg

Line 1734: l_return_status := FND_API.g_ret_sts_success;

1730: G_Version_Printed := FALSE ;
1731: END IF;
1732:
1733: -- Bug 3600118: Initialize return status variable
1734: l_return_status := FND_API.g_ret_sts_success;
1735:
1736: IF p_supply_source_header_id is not null THEN
1737: l_rsv_rec.supply_source_header_id := p_supply_source_header_id; --supply header id
1738: END IF;

Line 1747: RAISE fnd_api.g_exc_unexpected_error;

1743:
1744: IF p_supply_source_type_id IS NULL THEN
1745: FND_MESSAGE.SET_NAME('INV','INV_API_NULL_SOURCE_TYPE_ID');
1746: FND_MSG_PUB.Add;
1747: RAISE fnd_api.g_exc_unexpected_error;
1748: ELSIF p_supply_source_type_id NOT IN
1749: (inv_reservation_global.g_source_type_po,
1750: inv_reservation_global.g_source_type_internal_req,
1751: inv_reservation_global.g_source_type_req) THEN

Line 1754: RAISE fnd_api.g_exc_unexpected_error;

1750: inv_reservation_global.g_source_type_internal_req,
1751: inv_reservation_global.g_source_type_req) THEN
1752: FND_MESSAGE.SET_NAME('INV','INV_API_INVALID_SOURCE_TYPE_ID');
1753: FND_MSG_PUB.Add;
1754: RAISE fnd_api.g_exc_unexpected_error;
1755: END IF;
1756:
1757: IF p_project_id is not null THEN
1758: l_rsv_rec.project_id := p_project_id; -- project id

Line 1770: , p_init_msg_lst => fnd_api.g_false

1766:
1767: inv_reservation_pvt.query_reservation
1768: (
1769: p_api_version_number => 1.0
1770: , p_init_msg_lst => fnd_api.g_false
1771: , x_return_status => l_return_status
1772: , x_msg_count => x_msg_count
1773: , x_msg_data => x_msg_data
1774: , p_query_input => l_rsv_rec

Line 1775: , p_lock_records => fnd_api.g_false

1771: , x_return_status => l_return_status
1772: , x_msg_count => x_msg_count
1773: , x_msg_data => x_msg_data
1774: , p_query_input => l_rsv_rec
1775: , p_lock_records => fnd_api.g_false
1776: , p_sort_by_req_date => inv_reservation_global.g_query_demand_ship_date_asc
1777: , p_cancel_order_mode => inv_reservation_global.g_cancel_order_no
1778: , x_mtl_reservation_tbl => l_rsv_array
1779: , x_mtl_reservation_tbl_count => l_record_count

Line 1790: If x_return_status = fnd_api.g_ret_sts_success THEN

1786: End If;
1787:
1788: x_return_status := l_return_status;
1789:
1790: If x_return_status = fnd_api.g_ret_sts_success THEN
1791: l_Fnd_Log_message := 'Calling query_reservation API was successful ';
1792: -- Fnd_Log_Debug(fnd_log.Level_Error,C_Module_name, l_Fnd_Log_Message );
1793: x_rsv_array := l_rsv_array;
1794: x_record_count := l_record_count;

Line 1819: WHEN fnd_api.g_exc_error THEN

1815:
1816:
1817:
1818: EXCEPTION
1819: WHEN fnd_api.g_exc_error THEN
1820: x_return_status := fnd_api.g_ret_sts_error;
1821: x_record_count := -1;
1822:
1823: -- Get message count and data

Line 1820: x_return_status := fnd_api.g_ret_sts_error;

1816:
1817:
1818: EXCEPTION
1819: WHEN fnd_api.g_exc_error THEN
1820: x_return_status := fnd_api.g_ret_sts_error;
1821: x_record_count := -1;
1822:
1823: -- Get message count and data
1824: fnd_msg_pub.count_and_get

Line 1863: WHEN fnd_api.g_exc_unexpected_error THEN

1859: End Loop ;
1860: End If;
1861:
1862:
1863: WHEN fnd_api.g_exc_unexpected_error THEN
1864: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1865: x_record_count := -1;
1866:
1867: -- Get message count and data

Line 1864: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1860: End If;
1861:
1862:
1863: WHEN fnd_api.g_exc_unexpected_error THEN
1864: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1865: x_record_count := -1;
1866:
1867: -- Get message count and data
1868: fnd_msg_pub.count_and_get

Line 1907: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1903: End Loop ;
1904: End If;
1905:
1906: WHEN OTHERS THEN
1907: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1908: x_record_count := -1;
1909:
1910: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
1911: THEN

Line 2015: If l_return_status = fnd_api.g_ret_sts_success THEN

2011: mydebug(l_Fnd_Log_Message,c_api_name,9);
2012: End If;
2013:
2014:
2015: If l_return_status = fnd_api.g_ret_sts_success THEN
2016: l_Fnd_Log_message := 'Calling QUERY_RES API was successful ';
2017: -- Fnd_Log_Debug(fnd_log.Level_Error,C_Module_name, l_Fnd_Log_Message );
2018: IF G_debug= C_Debug_Enabled THEN
2019: mydebug(l_Fnd_Log_Message, c_api_name,9);

Line 2107: --l_return_status := FND_API.g_ret_sts_success;

2103: G_Version_Printed := FALSE ;
2104: END IF;
2105:
2106: -- Bug 3600118: Initialize return status variable
2107: --l_return_status := FND_API.g_ret_sts_success;
2108: --
2109: -- bug fix 2341308
2110: if p_req_line_id IS NULL then
2111: l_Fnd_Log_message := 'p_req_line_id is NULL :';

Line 2137: If l_return_status = fnd_api.g_ret_sts_success THEN

2133: l_Fnd_Log_Message := 'l_return_status: '|| l_return_status;
2134: mydebug(l_Fnd_Log_Message,c_api_name,9);
2135: End If;
2136:
2137: If l_return_status = fnd_api.g_ret_sts_success THEN
2138: l_Fnd_Log_message := 'Calling QUERY_RES API was successful ';
2139: -- Fnd_Log_Debug(fnd_log.Level_Error,C_Module_name, l_Fnd_Log_Message );
2140: IF G_debug= C_Debug_Enabled THEN
2141: mydebug(l_Fnd_Log_Message, c_api_name,9);

Line 2217: l_return_status := FND_API.g_ret_sts_success;

2213: G_Version_Printed := FALSE ;
2214: END IF;
2215:
2216: -- Bug 3600118: Initialize return status variable
2217: l_return_status := FND_API.g_ret_sts_success;
2218:
2219: -- find the existing reservation
2220: -- REQ or PO id's
2221: l_rsv.supply_source_header_id := p_supply_source_header_id;

Line 2237: , p_init_msg_lst => fnd_api.g_false

2233: --
2234: inv_reservation_pub.update_reservation
2235: (
2236: p_api_version_number => 1.0
2237: , p_init_msg_lst => fnd_api.g_false
2238: , x_return_status => l_return_status
2239: , x_msg_count => x_msg_count
2240: , x_msg_data => x_msg_data
2241: , p_original_rsv_rec => l_rsv

Line 2245: , p_validation_flag => fnd_api.g_true

2241: , p_original_rsv_rec => l_rsv
2242: , p_to_rsv_rec => l_rsv_new
2243: , p_original_serial_number => g_dummy_sn_tbl -- no serial contorl
2244: , p_to_serial_number => g_dummy_sn_tbl -- no serial control
2245: , p_validation_flag => fnd_api.g_true
2246: );
2247:
2248: If g_debug= C_Debug_Enabled Then
2249: l_Fnd_Log_Message := 'l_return_status: '|| l_return_status;

Line 2255: If x_return_status = fnd_api.g_ret_sts_success THEN

2251: End If;
2252:
2253: x_return_status := l_return_status;
2254:
2255: If x_return_status = fnd_api.g_ret_sts_success THEN
2256: l_Fnd_Log_message := 'Calling update_reservation API was successful ';
2257: -- Fnd_Log_Debug(fnd_log.Level_Error,C_Module_name, l_Fnd_Log_Message );
2258: IF G_debug= C_Debug_Enabled THEN
2259: mydebug(l_Fnd_Log_Message, c_api_name,9);

Line 2279: WHEN fnd_api.g_exc_error THEN

2275: END IF;
2276:
2277:
2278: EXCEPTION
2279: WHEN fnd_api.g_exc_error THEN
2280: x_return_status := fnd_api.g_ret_sts_error;
2281:
2282: -- Get message count and data
2283: fnd_msg_pub.count_and_get

Line 2280: x_return_status := fnd_api.g_ret_sts_error;

2276:
2277:
2278: EXCEPTION
2279: WHEN fnd_api.g_exc_error THEN
2280: x_return_status := fnd_api.g_ret_sts_error;
2281:
2282: -- Get message count and data
2283: fnd_msg_pub.count_and_get
2284: ( p_count => x_msg_count

Line 2322: WHEN fnd_api.g_exc_unexpected_error THEN

2318: End Loop ;
2319: End If;
2320:
2321:
2322: WHEN fnd_api.g_exc_unexpected_error THEN
2323: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2324:
2325: -- Get message count and data
2326: fnd_msg_pub.count_and_get

Line 2323: x_return_status := fnd_api.g_ret_sts_unexp_error ;

2319: End If;
2320:
2321:
2322: WHEN fnd_api.g_exc_unexpected_error THEN
2323: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2324:
2325: -- Get message count and data
2326: fnd_msg_pub.count_and_get
2327: ( p_count => x_msg_count

Line 2365: x_return_status := fnd_api.g_ret_sts_unexp_error ;

2361: End Loop ;
2362: End If;
2363:
2364: WHEN OTHERS THEN
2365: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2366:
2367: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
2368: THEN
2369: fnd_msg_pub.add_exc_msg

Line 2473: l_return_status := FND_API.g_ret_sts_success;

2469: G_Version_Printed := FALSE ;
2470: END IF;
2471:
2472: -- Bug 3600118: Initialize return status variable
2473: l_return_status := FND_API.g_ret_sts_success;
2474:
2475: -- print out IN parameter values
2476: IF g_debug= C_Debug_Enabled THEN
2477: l_Fnd_Log_Message := 'p_from_reservation_id:' || p_from_reservation_id;

Line 2559: , p_init_msg_lst => fnd_api.g_false

2555:
2556: inv_reservation_pvt.transfer_reservation
2557: (
2558: p_api_version_number => 1.0
2559: , p_init_msg_lst => fnd_api.g_false
2560: , x_return_status => l_return_status
2561: , x_msg_count => x_msg_count
2562: , x_msg_data => x_msg_data
2563: --, p_is_transfer_supply => fnd_api.g_true

Line 2563: --, p_is_transfer_supply => fnd_api.g_true

2559: , p_init_msg_lst => fnd_api.g_false
2560: , x_return_status => l_return_status
2561: , x_msg_count => x_msg_count
2562: , x_msg_data => x_msg_data
2563: --, p_is_transfer_supply => fnd_api.g_true
2564: , p_original_rsv_rec => l_rsv
2565: , p_to_rsv_rec => l_rsv_new
2566: , p_original_serial_number => g_dummy_sn_tbl -- no serial contorl
2567: -- , p_to_serial_number => g_dummy_sn_tbl -- no serial control

Line 2568: , p_validation_flag => fnd_api.g_true

2564: , p_original_rsv_rec => l_rsv
2565: , p_to_rsv_rec => l_rsv_new
2566: , p_original_serial_number => g_dummy_sn_tbl -- no serial contorl
2567: -- , p_to_serial_number => g_dummy_sn_tbl -- no serial control
2568: , p_validation_flag => fnd_api.g_true
2569: , x_reservation_id => l_new_rsv_id
2570: );
2571:
2572: If g_debug= C_Debug_Enabled Then

Line 2579: If x_return_status = fnd_api.g_ret_sts_success THEN

2575: End If;
2576:
2577: x_return_status := l_return_status;
2578:
2579: If x_return_status = fnd_api.g_ret_sts_success THEN
2580: l_Fnd_Log_message := 'Calling transfer_reservation API was successful ';
2581: -- Fnd_Log_Debug(fnd_log.Level_Error,C_Module_name, l_Fnd_Log_Message );
2582: IF G_debug= C_Debug_Enabled THEN
2583: mydebug(l_Fnd_Log_Message, c_api_name,9);

Line 2602: WHEN fnd_api.g_exc_error THEN

2598: mydebug(l_Fnd_Log_Message, c_api_name,9);
2599: END IF;
2600:
2601: EXCEPTION
2602: WHEN fnd_api.g_exc_error THEN
2603: x_return_status := fnd_api.g_ret_sts_error;
2604:
2605: -- Get message count and data
2606: fnd_msg_pub.count_and_get

Line 2603: x_return_status := fnd_api.g_ret_sts_error;

2599: END IF;
2600:
2601: EXCEPTION
2602: WHEN fnd_api.g_exc_error THEN
2603: x_return_status := fnd_api.g_ret_sts_error;
2604:
2605: -- Get message count and data
2606: fnd_msg_pub.count_and_get
2607: ( p_count => x_msg_count

Line 2644: WHEN fnd_api.g_exc_unexpected_error THEN

2640: END IF;
2641: End Loop ;
2642: End If;
2643:
2644: WHEN fnd_api.g_exc_unexpected_error THEN
2645: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2646:
2647: -- Get message count and data
2648: fnd_msg_pub.count_and_get

Line 2645: x_return_status := fnd_api.g_ret_sts_unexp_error ;

2641: End Loop ;
2642: End If;
2643:
2644: WHEN fnd_api.g_exc_unexpected_error THEN
2645: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2646:
2647: -- Get message count and data
2648: fnd_msg_pub.count_and_get
2649: ( p_count => x_msg_count

Line 2687: x_return_status := fnd_api.g_ret_sts_unexp_error ;

2683: End Loop ;
2684: End If;
2685:
2686: WHEN OTHERS THEN
2687: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2688:
2689: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
2690: THEN
2691: fnd_msg_pub.add_exc_msg

Line 2779: l_return_status := FND_API.g_ret_sts_success;

2775: G_Version_Printed := FALSE ;
2776: END IF;
2777:
2778: -- Bug 3600118: Initialize return status variable
2779: l_return_status := FND_API.g_ret_sts_success;
2780:
2781: -- print out IN parameter values
2782: IF G_debug= C_Debug_Enabled THEN
2783: l_Fnd_Log_Message := 'p_supply_source_header_id: '|| p_supply_source_header_id;

Line 2804: , p_init_msg_lst => fnd_api.g_false

2800: --
2801: inv_reservation_pub.delete_reservation
2802: (
2803: p_api_version_number => 1.0
2804: , p_init_msg_lst => fnd_api.g_false
2805: , x_return_status => l_return_status
2806: , x_msg_count => x_msg_count
2807: , x_msg_data => x_msg_data
2808: , p_rsv_rec => l_rsv

Line 2819: If x_return_status = fnd_api.g_ret_sts_success THEN

2815: End If;
2816:
2817: x_return_status := l_return_status;
2818:
2819: If x_return_status = fnd_api.g_ret_sts_success THEN
2820: l_Fnd_Log_message := 'Calling delete_reservation API was successful ';
2821: -- Fnd_Log_Debug(fnd_log.Level_Error,C_Module_name, l_Fnd_Log_Message );
2822: IF G_debug= C_Debug_Enabled THEN
2823: mydebug(l_Fnd_Log_Message, c_api_name,9);

Line 2841: WHEN fnd_api.g_exc_error THEN

2837: IF G_debug= C_Debug_Enabled THEN
2838: mydebug(l_Fnd_Log_Message, c_api_name,9);
2839: END IF;
2840: EXCEPTION
2841: WHEN fnd_api.g_exc_error THEN
2842: x_return_status := fnd_api.g_ret_sts_error;
2843:
2844: -- Get message count and data
2845: fnd_msg_pub.count_and_get

Line 2842: x_return_status := fnd_api.g_ret_sts_error;

2838: mydebug(l_Fnd_Log_Message, c_api_name,9);
2839: END IF;
2840: EXCEPTION
2841: WHEN fnd_api.g_exc_error THEN
2842: x_return_status := fnd_api.g_ret_sts_error;
2843:
2844: -- Get message count and data
2845: fnd_msg_pub.count_and_get
2846: ( p_count => x_msg_count

Line 2883: WHEN fnd_api.g_exc_unexpected_error THEN

2879: END IF;
2880: End Loop ;
2881: End If;
2882:
2883: WHEN fnd_api.g_exc_unexpected_error THEN
2884: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2885:
2886: -- Get message count and data
2887: fnd_msg_pub.count_and_get

Line 2884: x_return_status := fnd_api.g_ret_sts_unexp_error ;

2880: End Loop ;
2881: End If;
2882:
2883: WHEN fnd_api.g_exc_unexpected_error THEN
2884: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2885:
2886: -- Get message count and data
2887: fnd_msg_pub.count_and_get
2888: ( p_count => x_msg_count

Line 2926: x_return_status := fnd_api.g_ret_sts_unexp_error ;

2922: End Loop ;
2923: End If;
2924:
2925: WHEN OTHERS THEN
2926: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2927:
2928: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
2929: THEN
2930: fnd_msg_pub.add_exc_msg

Line 3165: , p_init_msg_lst IN VARCHAR2 DEFAULT fnd_api.g_false

3161:
3162: PROCEDURE MAINTAIN_RESERVATION
3163: (
3164: p_api_version_number IN NUMBER DEFAULT 1.0
3165: , p_init_msg_lst IN VARCHAR2 DEFAULT fnd_api.g_false
3166: , p_header_id IN NUMBER DEFAULT NULL
3167: , p_line_id IN NUMBER DEFAULT NULL
3168: , p_line_location_id IN NUMBER DEFAULT NULL
3169: , p_distribution_id IN NUMBER DEFAULT NULL

Line 3668: l_return_status := FND_API.g_ret_sts_success;

3664: g_Version_Printed := FALSE ;
3665: END IF;
3666:
3667: -- Bug 3600118: Initialize return status variable
3668: l_return_status := FND_API.g_ret_sts_success;
3669:
3670: l_secondary_uom_code := null ; -- Fix for 8673423
3671:
3672: -- print out all the IN paramter values

Line 3697: RAISE fnd_api.g_exc_unexpected_error;

3693: IF g_debug = C_Debug_Enabled THEN
3694: l_Fnd_Log_Message := 'Null action code';
3695: mydebug(l_Fnd_Log_Message, c_api_name,9);
3696: END IF;
3697: RAISE fnd_api.g_exc_unexpected_error;
3698: END IF;
3699:
3700: IF upper(p_action) = 'APPROVE_REQ_SUPPLY' THEN
3701: --replace with FOR Loops

Line 3901: If x_return_status = fnd_api.g_ret_sts_success THEN

3897: END IF;
3898:
3899: x_return_status := l_return_status;
3900:
3901: If x_return_status = fnd_api.g_ret_sts_success THEN
3902: l_Fnd_Log_message := 'Calling CREATE_RES API was successful ';
3903: -- Fnd_Log_Debug(fnd_log.Level_Error,C_Module_name, l_Fnd_Log_Message );
3904: IF G_debug= C_Debug_Enabled THEN
3905: mydebug(l_Fnd_Log_Message, c_api_name,9);

Line 4251: , p_init_msg_lst => fnd_api.g_false

4247:
4248: reduce_reservation
4249: (
4250: p_api_version_number => 1.0
4251: , p_init_msg_lst => fnd_api.g_false
4252: , x_return_status => l_return_status
4253: , x_msg_count => x_msg_count
4254: , x_msg_data => x_msg_data
4255: , p_mtl_maintain_rsv_rec => l_mtl_maint_rsv_rec

Line 4263: IF l_return_status = fnd_api.g_ret_sts_error THEN

4259: IF g_debug= C_Debug_Enabled THEN
4260: mydebug ('Return Status after calling reduce reservations: '|| l_return_status, c_api_name,9);
4261: END IF;
4262:
4263: IF l_return_status = fnd_api.g_ret_sts_error THEN
4264:
4265: IF g_debug= C_Debug_Enabled THEN
4266: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
4267: END IF;

Line 4268: RAISE fnd_api.g_exc_error;

4264:
4265: IF g_debug= C_Debug_Enabled THEN
4266: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
4267: END IF;
4268: RAISE fnd_api.g_exc_error;
4269:
4270: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
4271:
4272: IF g_debug= C_Debug_Enabled THEN

Line 4270: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

4266: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
4267: END IF;
4268: RAISE fnd_api.g_exc_error;
4269:
4270: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
4271:
4272: IF g_debug= C_Debug_Enabled THEN
4273: mydebug('Rasing Unexpected error'|| l_return_status, c_api_name,9);
4274: END IF;

Line 4275: RAISE fnd_api.g_exc_unexpected_error;

4271:
4272: IF g_debug= C_Debug_Enabled THEN
4273: mydebug('Rasing Unexpected error'|| l_return_status, c_api_name,9);
4274: END IF;
4275: RAISE fnd_api.g_exc_unexpected_error;
4276:
4277: END IF;
4278: /***** Call reduce reservations instead of delete reservations
4279: DELETE_RES

Line 4377: , p_init_msg_lst => fnd_api.g_false

4373:
4374: reduce_reservation
4375: (
4376: p_api_version_number => 1.0
4377: , p_init_msg_lst => fnd_api.g_false
4378: , x_return_status => l_return_status
4379: , x_msg_count => x_msg_count
4380: , x_msg_data => x_msg_data
4381: , p_mtl_maintain_rsv_rec => l_mtl_maint_rsv_rec

Line 4390: IF l_return_status = fnd_api.g_ret_sts_error THEN

4386: IF g_debug= C_Debug_Enabled THEN
4387: mydebug ('Return Status after calling reduce reservations: '|| l_return_status, c_api_name,9);
4388: END IF;
4389:
4390: IF l_return_status = fnd_api.g_ret_sts_error THEN
4391:
4392: IF g_debug= C_Debug_Enabled THEN
4393: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
4394: END IF;

Line 4395: RAISE fnd_api.g_exc_error;

4391:
4392: IF g_debug= C_Debug_Enabled THEN
4393: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
4394: END IF;
4395: RAISE fnd_api.g_exc_error;
4396:
4397: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
4398:
4399: IF g_debug= C_Debug_Enabled THEN

Line 4397: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

4393: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
4394: END IF;
4395: RAISE fnd_api.g_exc_error;
4396:
4397: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
4398:
4399: IF g_debug= C_Debug_Enabled THEN
4400: mydebug('Rasing Unexpected error'|| l_return_status, c_api_name,9);
4401: END IF;

Line 4402: RAISE fnd_api.g_exc_unexpected_error;

4398:
4399: IF g_debug= C_Debug_Enabled THEN
4400: mydebug('Rasing Unexpected error'|| l_return_status, c_api_name,9);
4401: END IF;
4402: RAISE fnd_api.g_exc_unexpected_error;
4403:
4404: END IF;
4405:
4406: END IF;

Line 4430: RAISE fnd_api.g_exc_error;

4426:
4427: IF (p_transaction_id IS NULL) THEN
4428: FND_MESSAGE.SET_NAME('INV','INV_INVALID_TRANSACTION_ID');
4429: FND_MSG_PUB.ADD;
4430: RAISE fnd_api.g_exc_error;
4431: END IF;
4432:
4433: OPEN get_source_doc_code(p_transaction_id);
4434: FETCH get_source_doc_code INTO get_source_doc_code_rec;

Line 4450: RAISE fnd_api.g_exc_error;

4446: IF (get_source_doc_code_rec.organization_id IS NULL) THEN
4447: IF g_debug= C_Debug_Enabled THEN
4448: mydebug('Could not find the organization for the transaction id:' || p_transaction_id, c_api_name,9);
4449: END IF;
4450: RAISE fnd_api.g_exc_error;
4451: END IF;
4452:
4453: IF (inv_install.adv_inv_installed(get_source_doc_code_rec.organization_id)) THEN
4454: -- wms org

Line 5623: , p_init_msg_lst => fnd_api.g_false

5619:
5620: reduce_reservation
5621: (
5622: p_api_version_number => 1.0
5623: , p_init_msg_lst => fnd_api.g_false
5624: , x_return_status => l_return_status
5625: , x_msg_count => x_msg_count
5626: , x_msg_data => x_msg_data
5627: , p_mtl_maintain_rsv_rec => l_mtl_maint_rsv_rec

Line 5635: IF l_return_status = fnd_api.g_ret_sts_error THEN

5631: IF g_debug= C_Debug_Enabled THEN
5632: mydebug ('Return Status after calling reduce reservations: '|| l_return_status, c_api_name,9);
5633: END IF;
5634:
5635: IF l_return_status = fnd_api.g_ret_sts_error THEN
5636:
5637: IF g_debug= C_Debug_Enabled THEN
5638: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
5639: END IF;

Line 5640: RAISE fnd_api.g_exc_error;

5636:
5637: IF g_debug= C_Debug_Enabled THEN
5638: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
5639: END IF;
5640: RAISE fnd_api.g_exc_error;
5641:
5642: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5643:
5644: IF g_debug= C_Debug_Enabled THEN

Line 5642: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

5638: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
5639: END IF;
5640: RAISE fnd_api.g_exc_error;
5641:
5642: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5643:
5644: IF g_debug= C_Debug_Enabled THEN
5645: mydebug('Rasing Unexpected error'|| l_return_status, c_api_name,9);
5646: END IF;

Line 5647: RAISE fnd_api.g_exc_unexpected_error;

5643:
5644: IF g_debug= C_Debug_Enabled THEN
5645: mydebug('Rasing Unexpected error'|| l_return_status, c_api_name,9);
5646: END IF;
5647: RAISE fnd_api.g_exc_unexpected_error;
5648:
5649: END IF;
5650: END IF;
5651: END IF;

Line 5735: , p_Init_Msg_Lst => fnd_api.g_false

5731:
5732: reduce_reservation
5733: (
5734: p_API_Version_Number => 1.0
5735: , p_Init_Msg_Lst => fnd_api.g_false
5736: , x_Return_Status => l_return_status
5737: , x_Msg_Count => x_msg_count
5738: , x_Msg_Data => x_msg_data
5739: , p_Mtl_Maintain_Rsv_rec=> l_mtl_maint_rsv_rec

Line 5748: IF l_return_status = fnd_api.g_ret_sts_error THEN

5744: IF g_debug= C_Debug_Enabled THEN
5745: mydebug ('Return Status after calling reduce reservations: '|| l_return_status, c_api_name,9);
5746: END IF;
5747:
5748: IF l_return_status = fnd_api.g_ret_sts_error THEN
5749:
5750: IF g_debug= C_Debug_Enabled THEN
5751: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
5752: END IF;

Line 5753: RAISE fnd_api.g_exc_error;

5749:
5750: IF g_debug= C_Debug_Enabled THEN
5751: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
5752: END IF;
5753: RAISE fnd_api.g_exc_error;
5754:
5755: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5756:
5757: IF g_debug= C_Debug_Enabled THEN

Line 5755: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

5751: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
5752: END IF;
5753: RAISE fnd_api.g_exc_error;
5754:
5755: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5756:
5757: IF g_debug= C_Debug_Enabled THEN
5758: mydebug('Rasing Unexpected error'|| l_return_status, c_api_name,9);
5759: END IF;

Line 5760: RAISE fnd_api.g_exc_unexpected_error;

5756:
5757: IF g_debug= C_Debug_Enabled THEN
5758: mydebug('Rasing Unexpected error'|| l_return_status, c_api_name,9);
5759: END IF;
5760: RAISE fnd_api.g_exc_unexpected_error;
5761:
5762: END IF;
5763:
5764: END IF;

Line 5884: , p_init_msg_lst => fnd_api.g_false

5880:
5881: reduce_reservation
5882: (
5883: p_api_version_number => 1.0
5884: , p_init_msg_lst => fnd_api.g_false
5885: , x_return_status => l_return_status
5886: , x_msg_count => x_msg_count
5887: , x_msg_data => x_msg_data
5888: , p_mtl_maintain_rsv_rec => l_mtl_maint_rsv_rec

Line 5896: IF l_return_status = fnd_api.g_ret_sts_error THEN

5892: IF g_debug= C_Debug_Enabled THEN
5893: mydebug ('Return Status after calling reduce reservations: '|| l_return_status, c_api_name,9);
5894: END IF;
5895:
5896: IF l_return_status = fnd_api.g_ret_sts_error THEN
5897:
5898: IF g_debug= C_Debug_Enabled THEN
5899: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
5900: END IF;

Line 5901: RAISE fnd_api.g_exc_error;

5897:
5898: IF g_debug= C_Debug_Enabled THEN
5899: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
5900: END IF;
5901: RAISE fnd_api.g_exc_error;
5902:
5903: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5904:
5905: IF g_debug= C_Debug_Enabled THEN

Line 5903: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

5899: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
5900: END IF;
5901: RAISE fnd_api.g_exc_error;
5902:
5903: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5904:
5905: IF g_debug= C_Debug_Enabled THEN
5906: mydebug('Rasing Unexpected error'|| l_return_status, c_api_name,9);
5907: END IF;

Line 5908: RAISE fnd_api.g_exc_unexpected_error;

5904:
5905: IF g_debug= C_Debug_Enabled THEN
5906: mydebug('Rasing Unexpected error'|| l_return_status, c_api_name,9);
5907: END IF;
5908: RAISE fnd_api.g_exc_unexpected_error;
5909:
5910: END IF;
5911: END LOOP; --get_distr
5912:

Line 5961: , p_init_msg_lst => fnd_api.g_false

5957:
5958: reduce_reservation
5959: (
5960: p_api_version_number => 1.0
5961: , p_init_msg_lst => fnd_api.g_false
5962: , x_return_status => l_return_status
5963: , x_msg_count => x_msg_count
5964: , x_msg_data => x_msg_data
5965: , p_mtl_maintain_rsv_rec => l_mtl_maint_rsv_rec

Line 5973: IF l_return_status = fnd_api.g_ret_sts_error THEN

5969: IF g_debug= C_Debug_Enabled THEN
5970: mydebug ('Return Status after calling reduce reservations: '|| l_return_status, c_api_name,9);
5971: END IF;
5972:
5973: IF l_return_status = fnd_api.g_ret_sts_error THEN
5974:
5975: IF g_debug= C_Debug_Enabled THEN
5976: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
5977: END IF;

Line 5978: RAISE fnd_api.g_exc_error;

5974:
5975: IF g_debug= C_Debug_Enabled THEN
5976: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
5977: END IF;
5978: RAISE fnd_api.g_exc_error;
5979:
5980: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5981:
5982: IF g_debug= C_Debug_Enabled THEN

Line 5980: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

5976: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
5977: END IF;
5978: RAISE fnd_api.g_exc_error;
5979:
5980: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5981:
5982: IF g_debug= C_Debug_Enabled THEN
5983: mydebug('Rasing Unexpected error'|| l_return_status, c_api_name,9);
5984: END IF;

Line 5985: RAISE fnd_api.g_exc_unexpected_error;

5981:
5982: IF g_debug= C_Debug_Enabled THEN
5983: mydebug('Rasing Unexpected error'|| l_return_status, c_api_name,9);
5984: END IF;
5985: RAISE fnd_api.g_exc_unexpected_error;
5986:
5987: END IF;
5988: END LOOP;
5989: END IF; --Reservation Exists

Line 6037: , p_init_msg_lst => fnd_api.g_false

6033:
6034: reduce_reservation
6035: (
6036: p_api_version_number => 1.0
6037: , p_init_msg_lst => fnd_api.g_false
6038: , x_return_status => l_return_status
6039: , x_msg_count => x_msg_count
6040: , x_msg_data => x_msg_data
6041: , p_mtl_maintain_rsv_rec => l_mtl_maint_rsv_rec

Line 6049: IF l_return_status = fnd_api.g_ret_sts_error THEN

6045: IF g_debug= C_Debug_Enabled THEN
6046: mydebug ('Return Status after calling reduce reservations: '|| l_return_status, c_api_name,9);
6047: END IF;
6048:
6049: IF l_return_status = fnd_api.g_ret_sts_error THEN
6050:
6051: IF g_debug= C_Debug_Enabled THEN
6052: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
6053: END IF;

Line 6054: RAISE fnd_api.g_exc_error;

6050:
6051: IF g_debug= C_Debug_Enabled THEN
6052: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
6053: END IF;
6054: RAISE fnd_api.g_exc_error;
6055:
6056: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6057:
6058: IF g_debug= C_Debug_Enabled THEN

Line 6056: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

6052: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
6053: END IF;
6054: RAISE fnd_api.g_exc_error;
6055:
6056: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6057:
6058: IF g_debug= C_Debug_Enabled THEN
6059: mydebug('Rasing Unexpected error'|| l_return_status, c_api_name,9);
6060: END IF;

Line 6061: RAISE fnd_api.g_exc_unexpected_error;

6057:
6058: IF g_debug= C_Debug_Enabled THEN
6059: mydebug('Rasing Unexpected error'|| l_return_status, c_api_name,9);
6060: END IF;
6061: RAISE fnd_api.g_exc_unexpected_error;
6062:
6063: END IF;
6064:
6065: END IF; --Reservation Exists

Line 6130: , p_init_msg_lst => fnd_api.g_false

6126:
6127: reduce_reservation
6128: (
6129: p_api_version_number => 1.0
6130: , p_init_msg_lst => fnd_api.g_false
6131: , x_return_status => l_return_status
6132: , x_msg_count => x_msg_count
6133: , x_msg_data => x_msg_data
6134: , p_mtl_maintain_rsv_rec => l_mtl_maint_rsv_rec

Line 6142: IF l_return_status = fnd_api.g_ret_sts_error THEN

6138: IF g_debug= C_Debug_Enabled THEN
6139: mydebug ('Return Status after calling reduce reservations: '|| l_return_status, c_api_name,9);
6140: END IF;
6141:
6142: IF l_return_status = fnd_api.g_ret_sts_error THEN
6143:
6144: IF g_debug= C_Debug_Enabled THEN
6145: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
6146: END IF;

Line 6147: RAISE fnd_api.g_exc_error;

6143:
6144: IF g_debug= C_Debug_Enabled THEN
6145: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
6146: END IF;
6147: RAISE fnd_api.g_exc_error;
6148:
6149: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6150:
6151: IF g_debug= C_Debug_Enabled THEN

Line 6149: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

6145: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
6146: END IF;
6147: RAISE fnd_api.g_exc_error;
6148:
6149: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6150:
6151: IF g_debug= C_Debug_Enabled THEN
6152: mydebug('Rasing Unexpected error'|| l_return_status, c_api_name,9);
6153: END IF;

Line 6154: RAISE fnd_api.g_exc_unexpected_error;

6150:
6151: IF g_debug= C_Debug_Enabled THEN
6152: mydebug('Rasing Unexpected error'|| l_return_status, c_api_name,9);
6153: END IF;
6154: RAISE fnd_api.g_exc_unexpected_error;
6155:
6156: END IF;
6157: END LOOP; --get_distr
6158:

Line 6210: , p_init_msg_lst => fnd_api.g_false

6206:
6207: reduce_reservation
6208: (
6209: p_api_version_number => 1.0
6210: , p_init_msg_lst => fnd_api.g_false
6211: , x_return_status => l_return_status
6212: , x_msg_count => x_msg_count
6213: , x_msg_data => x_msg_data
6214: , p_mtl_maintain_rsv_rec => l_mtl_maint_rsv_rec

Line 6222: IF l_return_status = fnd_api.g_ret_sts_error THEN

6218: IF g_debug= C_Debug_Enabled THEN
6219: mydebug ('Return Status after calling reduce reservations: '|| l_return_status, c_api_name,9);
6220: END IF;
6221:
6222: IF l_return_status = fnd_api.g_ret_sts_error THEN
6223:
6224: IF g_debug= C_Debug_Enabled THEN
6225: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
6226: END IF;

Line 6227: RAISE fnd_api.g_exc_error;

6223:
6224: IF g_debug= C_Debug_Enabled THEN
6225: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
6226: END IF;
6227: RAISE fnd_api.g_exc_error;
6228:
6229: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6230:
6231: IF g_debug= C_Debug_Enabled THEN

Line 6229: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

6225: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
6226: END IF;
6227: RAISE fnd_api.g_exc_error;
6228:
6229: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6230:
6231: IF g_debug= C_Debug_Enabled THEN
6232: mydebug('Rasing Unexpected error'|| l_return_status, c_api_name,9);
6233: END IF;

Line 6234: RAISE fnd_api.g_exc_unexpected_error;

6230:
6231: IF g_debug= C_Debug_Enabled THEN
6232: mydebug('Rasing Unexpected error'|| l_return_status, c_api_name,9);
6233: END IF;
6234: RAISE fnd_api.g_exc_unexpected_error;
6235:
6236: END IF;
6237:
6238: END IF; --Reservation Exists

Line 6300: , p_init_msg_lst => fnd_api.g_false

6296:
6297: reduce_reservation
6298: (
6299: p_api_version_number => 1.0
6300: , p_init_msg_lst => fnd_api.g_false
6301: , x_return_status => l_return_status
6302: , x_msg_count => x_msg_count
6303: , x_msg_data => x_msg_data
6304: , p_mtl_maintain_rsv_rec => l_mtl_maint_rsv_rec

Line 6314: IF l_return_status = fnd_api.g_ret_sts_error THEN

6310: mydebug ('Expected qty: '|| p_ordered_quantity, c_api_name,9);
6311: mydebug ('Modified qty: '|| l_quantity_modified, c_api_name,9);
6312: END IF;
6313:
6314: IF l_return_status = fnd_api.g_ret_sts_error THEN
6315:
6316: IF g_debug= C_Debug_Enabled THEN
6317: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
6318: END IF;

Line 6319: RAISE fnd_api.g_exc_error;

6315:
6316: IF g_debug= C_Debug_Enabled THEN
6317: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
6318: END IF;
6319: RAISE fnd_api.g_exc_error;
6320:
6321: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6322:
6323: IF g_debug= C_Debug_Enabled THEN

Line 6321: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

6317: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
6318: END IF;
6319: RAISE fnd_api.g_exc_error;
6320:
6321: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6322:
6323: IF g_debug= C_Debug_Enabled THEN
6324: mydebug('Rasing Unexpected error'|| l_return_status, c_api_name,9);
6325: END IF;

Line 6326: RAISE fnd_api.g_exc_unexpected_error;

6322:
6323: IF g_debug= C_Debug_Enabled THEN
6324: mydebug('Rasing Unexpected error'|| l_return_status, c_api_name,9);
6325: END IF;
6326: RAISE fnd_api.g_exc_unexpected_error;
6327:
6328: END IF;
6329:
6330: ELSE

Line 6350: , p_init_msg_lst => fnd_api.g_false

6346:
6347: reduce_reservation
6348: (
6349: p_api_version_number => 1.0
6350: , p_init_msg_lst => fnd_api.g_false
6351: , x_return_status => l_return_status
6352: , x_msg_count => x_msg_count
6353: , x_msg_data => x_msg_data
6354: , p_mtl_maintain_rsv_rec => l_mtl_maint_rsv_rec

Line 6365: IF l_return_status = fnd_api.g_ret_sts_error THEN

6361: mydebug ('Expected qty: '|| p_ordered_quantity, c_api_name,9);
6362: mydebug ('Modified qty: '|| l_quantity_modified, c_api_name,9);
6363: END IF;
6364:
6365: IF l_return_status = fnd_api.g_ret_sts_error THEN
6366:
6367: IF g_debug= C_Debug_Enabled THEN
6368: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
6369: END IF;

Line 6370: RAISE fnd_api.g_exc_error;

6366:
6367: IF g_debug= C_Debug_Enabled THEN
6368: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
6369: END IF;
6370: RAISE fnd_api.g_exc_error;
6371:
6372: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6373:
6374: IF g_debug= C_Debug_Enabled THEN

Line 6372: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

6368: mydebug('Raising expected error'|| l_return_status, c_api_name,9);
6369: END IF;
6370: RAISE fnd_api.g_exc_error;
6371:
6372: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6373:
6374: IF g_debug= C_Debug_Enabled THEN
6375: mydebug('Rasing Unexpected error'|| l_return_status, c_api_name,9);
6376: END IF;

Line 6377: RAISE fnd_api.g_exc_unexpected_error;

6373:
6374: IF g_debug= C_Debug_Enabled THEN
6375: mydebug('Rasing Unexpected error'|| l_return_status, c_api_name,9);
6376: END IF;
6377: RAISE fnd_api.g_exc_unexpected_error;
6378:
6379: END IF;
6380: END IF; -- ordered qty
6381:

Line 6397: If x_return_status = fnd_api.g_ret_sts_success THEN

6393: End If;
6394:
6395: x_return_status := l_return_status;
6396:
6397: If x_return_status = fnd_api.g_ret_sts_success THEN
6398: l_Fnd_Log_message := 'Calling maintain_reservation API was successful ';
6399: -- Fnd_Log_Debug(fnd_log.Level_Error,C_Module_name, l_Fnd_Log_Message );
6400: IF G_debug= C_Debug_Enabled THEN
6401: mydebug(l_Fnd_Log_Message, c_api_name,9);

Line 6421: WHEN fnd_api.g_exc_error THEN

6417: END IF;
6418:
6419: --
6420: EXCEPTION
6421: WHEN fnd_api.g_exc_error THEN
6422: x_return_status := fnd_api.g_ret_sts_error;
6423:
6424: -- Get message count and data
6425: fnd_msg_pub.count_and_get

Line 6422: x_return_status := fnd_api.g_ret_sts_error;

6418:
6419: --
6420: EXCEPTION
6421: WHEN fnd_api.g_exc_error THEN
6422: x_return_status := fnd_api.g_ret_sts_error;
6423:
6424: -- Get message count and data
6425: fnd_msg_pub.count_and_get
6426: ( p_count => x_msg_count

Line 6463: WHEN fnd_api.g_exc_unexpected_error THEN

6459: END IF;
6460: End Loop ;
6461: End If;
6462:
6463: WHEN fnd_api.g_exc_unexpected_error THEN
6464: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6465:
6466: -- Get message count and data
6467: fnd_msg_pub.count_and_get

Line 6464: x_return_status := fnd_api.g_ret_sts_unexp_error ;

6460: End Loop ;
6461: End If;
6462:
6463: WHEN fnd_api.g_exc_unexpected_error THEN
6464: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6465:
6466: -- Get message count and data
6467: fnd_msg_pub.count_and_get
6468: ( p_count => x_msg_count

Line 6506: x_return_status := fnd_api.g_ret_sts_unexp_error ;

6502: End Loop ;
6503: End If;
6504:
6505: WHEN OTHERS THEN
6506: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6507:
6508: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
6509: THEN
6510: fnd_msg_pub.add_exc_msg