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 178: IF (NVL(p_param_value,FND_API.G_MISS_DATE) = FND_API.G_MISS_DATE) THEN

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

Line 187: RAISE FND_API.G_EXC_ERROR;

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

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

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

Line 281: x_return_status := fnd_api.g_ret_sts_success;

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

Line 283: if not fnd_api.compatible_api_call(c_api_version_number

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

Line 288: raise fnd_api.g_exc_unexpected_error;

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

Line 293: if fnd_api.to_boolean(p_init_msg_lst) then

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

Line 334: , p_init_msg_lst => fnd_api.g_false

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

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

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

Line 353: raise fnd_api.g_exc_error;

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

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

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

Line 355: raise fnd_api.g_exc_unexpected_error;

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

Line 513: raise fnd_api.g_exc_error;

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

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

519: mydebug ('calling query reservation' ,c_api_name,1);
520: end if;
521:
522: IF (p_mtl_maintain_rsv_rec.project_id IS NOT NULL AND
523: p_mtl_maintain_rsv_rec.project_id <> fnd_api.g_miss_num) THEN
524: l_query_input.project_id := p_mtl_maintain_rsv_rec.project_id;
525: END IF;
526:
527: IF (p_mtl_maintain_rsv_rec.task_id IS NOT NULL AND

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

524: l_query_input.project_id := p_mtl_maintain_rsv_rec.project_id;
525: END IF;
526:
527: IF (p_mtl_maintain_rsv_rec.task_id IS NOT NULL AND
528: p_mtl_maintain_rsv_rec.task_id<> fnd_api.g_miss_num) THEN
529: l_query_input.task_id := p_mtl_maintain_rsv_rec.task_id;
530: END IF;
531:
532: inv_reservation_pvt.query_reservation(

Line 553: if x_return_status = fnd_api.g_ret_sts_error then

549: l_mtl_reservation_tbl_count, c_api_name,1);
550: end if;
551:
552: -- check if query reservation has raised any errors, if so raise exception
553: if x_return_status = fnd_api.g_ret_sts_error then
554: l_fnd_log_message := 'error while calling query_reservation api :';
555: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
556:
557: if g_debug= c_debug_enabled then

Line 561: raise fnd_api.g_exc_error;

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

Line 562: elsif x_return_status = fnd_api.g_ret_sts_unexp_error then

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

Line 569: raise fnd_api.g_exc_unexpected_error;

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

Line 657: raise fnd_api.g_exc_error;

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

Line 679: l_is_transfer_supply := fnd_api.g_true ;

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

Line 687: l_is_transfer_supply := fnd_api.g_false;

683: l_to_rsv_rec.demand_source_type_id := inv_reservation_global.g_source_type_po ;
684: l_to_rsv_rec.demand_source_header_id := l_original_rsv_rec.demand_source_header_id;
685: l_to_rsv_rec.demand_source_line_id := l_original_rsv_rec.demand_source_line_id;
686: l_to_rsv_rec.demand_source_delivery := null;
687: l_is_transfer_supply := fnd_api.g_false;
688: ***************************/
689: end if;
690: -- ignoring serial numbers assingment since serial numbers are not changed
691: -- 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 753: p_init_msg_lst => fnd_api.g_false ,

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

Line 759: p_validation_flag => fnd_api.g_true);

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

Line 765: if x_return_status = fnd_api.g_ret_sts_error then

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

Line 771: raise fnd_api.g_exc_error;

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

Line 772: elsif x_return_status = fnd_api.g_ret_sts_unexp_error then

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

Line 778: raise fnd_api.g_exc_unexpected_error;

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

Line 779: elsif x_return_status = fnd_api.g_ret_sts_success then

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

Line 805: p_mtl_maintain_rsv_rec.expected_quantity_uom = fnd_api.g_miss_char then

801: end if;
802: if nvl(p_mtl_maintain_rsv_rec.expected_quantity,0) > 0 then
803: -- dbms_output.put_line('expected qty is > 0');
804: if p_mtl_maintain_rsv_rec.expected_quantity_uom is null or
805: p_mtl_maintain_rsv_rec.expected_quantity_uom = fnd_api.g_miss_char then
806: -- codereview.su.13. raise error
807: check_reqd_param
808: (
809: p_param_value => p_mtl_maintain_rsv_rec.expected_quantity_uom, p_param_name => 'p_mtl_maintain_rsv_rec.expected_quantity_uom',

Line 812: raise fnd_api.g_exc_error ;

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

Line 819: p_mtl_maintain_rsv_rec.to_primary_uom_code = fnd_api.g_miss_char then

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

Line 893: p_mtl_maintain_rsv_rec.from_primary_txn_quantity = fnd_api.g_miss_num then

889: c_api_name,9);
890:
891: END IF;
892: if p_mtl_maintain_rsv_rec.from_primary_txn_quantity is null or
893: p_mtl_maintain_rsv_rec.from_primary_txn_quantity = fnd_api.g_miss_num then
894: --codereview.su.16 check if from_transaction_uom_code and from_primary_uom_code
895: -- is not null, if they are then raise error
896:
897: -- from_primary_uom_code column is a required column

Line 953: p_mtl_maintain_rsv_rec.to_primary_txn_quantity = fnd_api.g_miss_num then

949: c_api_name,9);
950:
951: END IF;
952: if p_mtl_maintain_rsv_rec.to_primary_txn_quantity is null or
953: p_mtl_maintain_rsv_rec.to_primary_txn_quantity = fnd_api.g_miss_num then
954: -- to_primary_uom_code column is a required column
955: check_reqd_param
956: (
957: p_param_value => p_mtl_maintain_rsv_rec.to_primary_uom_code,

Line 1047: l_is_transfer_supply := fnd_api.g_true ;

1043: l_to_rsv_rec.supply_source_line_id:= l_mtl_reservation_tbl(i).supply_source_line_id;
1044: l_to_rsv_rec.supply_source_line_detail:=
1045: l_mtl_reservation_tbl(i).supply_source_line_detail;
1046:
1047: l_is_transfer_supply := fnd_api.g_true ;
1048: else
1049: l_to_rsv_rec.demand_source_type_id := l_mtl_reservation_tbl(i).demand_source_type_id ;
1050: l_to_rsv_rec.demand_source_header_id:= l_mtl_reservation_tbl(i).demand_source_header_id;
1051: l_to_rsv_rec.demand_source_line_id:= l_mtl_reservation_tbl(i).demand_source_line_id;

Line 1053: l_is_transfer_supply := fnd_api.g_false;

1049: l_to_rsv_rec.demand_source_type_id := l_mtl_reservation_tbl(i).demand_source_type_id ;
1050: l_to_rsv_rec.demand_source_header_id:= l_mtl_reservation_tbl(i).demand_source_header_id;
1051: l_to_rsv_rec.demand_source_line_id:= l_mtl_reservation_tbl(i).demand_source_line_id;
1052: l_to_rsv_rec.demand_source_delivery := null;
1053: l_is_transfer_supply := fnd_api.g_false;
1054: end if;
1055: l_to_rsv_rec.primary_reservation_quantity :=
1056: Nvl(l_mtl_reservation_tbl(i).primary_reservation_quantity,0) - l_primary_need_reduced_qty;
1057: IF g_debug= c_debug_enabled then

Line 1064: p_init_msg_lst => fnd_api.g_false,

1060: END IF;
1061: inv_reservation_pvt.update_reservation
1062: (
1063: p_api_version_number => 1.0,
1064: p_init_msg_lst => fnd_api.g_false,
1065: x_return_status => x_return_status,
1066: x_msg_count => x_msg_count,
1067: x_msg_data => x_msg_data ,
1068: p_original_rsv_rec => l_original_rsv_rec,

Line 1072: p_validation_flag => fnd_api.g_true ,

1068: p_original_rsv_rec => l_original_rsv_rec,
1069: p_to_rsv_rec => l_to_rsv_rec,
1070: p_original_serial_number => l_original_serial_number,
1071: p_to_serial_number => l_to_serial_number,
1072: p_validation_flag => fnd_api.g_true ,
1073: p_check_availability => fnd_api.g_false );
1074:
1075: -- check if delete reservation has raised any errors, if so raise exception
1076: if x_return_status = fnd_api.g_ret_sts_error then

Line 1073: p_check_availability => fnd_api.g_false );

1069: p_to_rsv_rec => l_to_rsv_rec,
1070: p_original_serial_number => l_original_serial_number,
1071: p_to_serial_number => l_to_serial_number,
1072: p_validation_flag => fnd_api.g_true ,
1073: p_check_availability => fnd_api.g_false );
1074:
1075: -- check if delete reservation has raised any errors, if so raise exception
1076: if x_return_status = fnd_api.g_ret_sts_error then
1077: l_fnd_log_message := 'error while calling update reservation api 02:';

Line 1076: if x_return_status = fnd_api.g_ret_sts_error then

1072: p_validation_flag => fnd_api.g_true ,
1073: p_check_availability => fnd_api.g_false );
1074:
1075: -- check if delete reservation has raised any errors, if so raise exception
1076: if x_return_status = fnd_api.g_ret_sts_error then
1077: l_fnd_log_message := 'error while calling update reservation api 02:';
1078: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1079: if g_debug= c_debug_enabled then
1080: mydebug(l_fnd_log_message, c_api_name,9);

Line 1082: raise fnd_api.g_exc_error;

1078: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1079: if g_debug= c_debug_enabled then
1080: mydebug(l_fnd_log_message, c_api_name,9);
1081: end if;
1082: raise fnd_api.g_exc_error;
1083: elsif x_return_status = fnd_api.g_ret_sts_unexp_error then
1084: l_fnd_log_message := 'error while calling update reservation api 02:';
1085: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1086: if g_debug= c_debug_enabled then

Line 1083: elsif x_return_status = fnd_api.g_ret_sts_unexp_error then

1079: if g_debug= c_debug_enabled then
1080: mydebug(l_fnd_log_message, c_api_name,9);
1081: end if;
1082: raise fnd_api.g_exc_error;
1083: elsif x_return_status = fnd_api.g_ret_sts_unexp_error then
1084: l_fnd_log_message := 'error while calling update reservation api 02:';
1085: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1086: if g_debug= c_debug_enabled then
1087: mydebug(l_fnd_log_message, c_api_name,9);

Line 1089: raise fnd_api.g_exc_unexpected_error;

1085: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1086: if g_debug= c_debug_enabled then
1087: mydebug(l_fnd_log_message, c_api_name,9);
1088: end if;
1089: raise fnd_api.g_exc_unexpected_error;
1090: elsif x_return_status = fnd_api.g_ret_sts_success then
1091: l_fnd_log_message := 'calling update reservation api was successful -02:';
1092: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1093: if g_debug= c_debug_enabled then

Line 1090: elsif x_return_status = fnd_api.g_ret_sts_success then

1086: if g_debug= c_debug_enabled then
1087: mydebug(l_fnd_log_message, c_api_name,9);
1088: end if;
1089: raise fnd_api.g_exc_unexpected_error;
1090: elsif x_return_status = fnd_api.g_ret_sts_success then
1091: l_fnd_log_message := 'calling update reservation api was successful -02:';
1092: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1093: if g_debug= c_debug_enabled then
1094: mydebug(l_fnd_log_message, c_api_name,9);

Line 1111: p_init_msg_lst => fnd_api.g_false,

1107: -- dbms_output.put_line('calling delete reservation api');
1108: inv_reservation_pvt.delete_reservation
1109: (
1110: p_api_version_number => 1.0,
1111: p_init_msg_lst => fnd_api.g_false,
1112: x_return_status => x_return_status,
1113: x_msg_count => x_msg_count,
1114: x_msg_data => x_msg_data ,
1115: p_rsv_rec => l_original_rsv_rec,

Line 1117: p_validation_flag => fnd_api.g_true );

1113: x_msg_count => x_msg_count,
1114: x_msg_data => x_msg_data ,
1115: p_rsv_rec => l_original_rsv_rec,
1116: p_original_serial_number => l_original_serial_number,
1117: p_validation_flag => fnd_api.g_true );
1118:
1119: -- check if delete reservation has raised any errors, if so raise exception
1120: if x_return_status = fnd_api.g_ret_sts_error then
1121: l_fnd_log_message := 'error while calling delete reservation api 02:';

Line 1120: if x_return_status = fnd_api.g_ret_sts_error then

1116: p_original_serial_number => l_original_serial_number,
1117: p_validation_flag => fnd_api.g_true );
1118:
1119: -- check if delete reservation has raised any errors, if so raise exception
1120: if x_return_status = fnd_api.g_ret_sts_error then
1121: l_fnd_log_message := 'error while calling delete reservation api 02:';
1122: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1123: if g_debug= c_debug_enabled then
1124: mydebug(l_fnd_log_message, c_api_name,9);

Line 1126: raise fnd_api.g_exc_error;

1122: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1123: if g_debug= c_debug_enabled then
1124: mydebug(l_fnd_log_message, c_api_name,9);
1125: end if;
1126: raise fnd_api.g_exc_error;
1127: elsif x_return_status = fnd_api.g_ret_sts_unexp_error then
1128: l_fnd_log_message := 'error while calling delete reservation api 02:';
1129: ---- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1130: if g_debug= c_debug_enabled then

Line 1127: elsif x_return_status = fnd_api.g_ret_sts_unexp_error then

1123: if g_debug= c_debug_enabled then
1124: mydebug(l_fnd_log_message, c_api_name,9);
1125: end if;
1126: raise fnd_api.g_exc_error;
1127: elsif x_return_status = fnd_api.g_ret_sts_unexp_error then
1128: l_fnd_log_message := 'error while calling delete reservation api 02:';
1129: ---- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1130: if g_debug= c_debug_enabled then
1131: mydebug(l_fnd_log_message, c_api_name,9);

Line 1133: raise fnd_api.g_exc_unexpected_error;

1129: ---- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1130: if g_debug= c_debug_enabled then
1131: mydebug(l_fnd_log_message, c_api_name,9);
1132: end if;
1133: raise fnd_api.g_exc_unexpected_error;
1134: elsif x_return_status = fnd_api.g_ret_sts_success then
1135: l_fnd_log_message := 'calling delete reservation api was successful -02:';
1136: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1137: if g_debug= c_debug_enabled then

Line 1134: elsif x_return_status = fnd_api.g_ret_sts_success then

1130: if g_debug= c_debug_enabled then
1131: mydebug(l_fnd_log_message, c_api_name,9);
1132: end if;
1133: raise fnd_api.g_exc_unexpected_error;
1134: elsif x_return_status = fnd_api.g_ret_sts_success then
1135: l_fnd_log_message := 'calling delete reservation api was successful -02:';
1136: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1137: if g_debug= c_debug_enabled then
1138: mydebug(l_fnd_log_message, c_api_name,9);

Line 1167: when fnd_api.g_exc_error then

1163: if g_debug= c_debug_enabled then
1164: mydebug(l_fnd_log_message, c_api_name,9);
1165: end if;
1166: exception
1167: when fnd_api.g_exc_error then
1168: x_return_status := fnd_api.g_ret_sts_error;
1169:
1170: -- get message count and data
1171: fnd_msg_pub.count_and_get

Line 1168: x_return_status := fnd_api.g_ret_sts_error;

1164: mydebug(l_fnd_log_message, c_api_name,9);
1165: end if;
1166: exception
1167: when fnd_api.g_exc_error then
1168: x_return_status := fnd_api.g_ret_sts_error;
1169:
1170: -- get message count and data
1171: fnd_msg_pub.count_and_get
1172: ( p_count => x_msg_count

Line 1210: when fnd_api.g_exc_unexpected_error then

1206: end loop ;
1207: end if;
1208:
1209:
1210: when fnd_api.g_exc_unexpected_error then
1211: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1212:
1213: -- get message count and data
1214: fnd_msg_pub.count_and_get

Line 1211: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1207: end if;
1208:
1209:
1210: when fnd_api.g_exc_unexpected_error then
1211: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1212:
1213: -- get message count and data
1214: fnd_msg_pub.count_and_get
1215: ( p_count => x_msg_count

Line 1253: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1249: end loop ;
1250: end if;
1251:
1252: when others then
1253: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1254:
1255: if fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
1256: then
1257: fnd_msg_pub.add_exc_msg

Line 1483: l_return_status := fnd_api.g_ret_sts_success;

1479: g_version_printed := false ;
1480: end if;
1481:
1482: -- bug 3600118: initialize return status variable
1483: l_return_status := fnd_api.g_ret_sts_success;
1484:
1485: build_res_rec(x_reservation_rec =>l_rsv);
1486:
1487: l_rsv.inventory_item_id := p_inventory_item_id;

Line 1529: , p_init_msg_lst => fnd_api.g_false

1525:
1526: inv_reservation_pvt.create_reservation
1527: (
1528: p_api_version_number => 1.0
1529: , p_init_msg_lst => fnd_api.g_false
1530: , x_return_status => l_return_status
1531: , x_msg_count => x_msg_count
1532: , x_msg_data => x_msg_data
1533: , p_rsv_rec => l_rsv

Line 1536: , p_partial_reservation_flag => fnd_api.g_true

1532: , x_msg_data => x_msg_data
1533: , p_rsv_rec => l_rsv
1534: , p_serial_number => g_dummy_sn_tbl
1535: , x_serial_number => g_dummy_sn_tbl
1536: , p_partial_reservation_flag => fnd_api.g_true
1537: , p_force_reservation_flag => fnd_api.g_false
1538: , p_validation_flag => fnd_api.g_true
1539: --, p_validation_flag => fnd_api.g_false
1540: , x_quantity_reserved => l_qty

Line 1537: , p_force_reservation_flag => fnd_api.g_false

1533: , p_rsv_rec => l_rsv
1534: , p_serial_number => g_dummy_sn_tbl
1535: , x_serial_number => g_dummy_sn_tbl
1536: , p_partial_reservation_flag => fnd_api.g_true
1537: , p_force_reservation_flag => fnd_api.g_false
1538: , p_validation_flag => fnd_api.g_true
1539: --, p_validation_flag => fnd_api.g_false
1540: , x_quantity_reserved => l_qty
1541: , x_secondary_quantity_reserved => l_second_qty

Line 1538: , p_validation_flag => fnd_api.g_true

1534: , p_serial_number => g_dummy_sn_tbl
1535: , x_serial_number => g_dummy_sn_tbl
1536: , p_partial_reservation_flag => fnd_api.g_true
1537: , p_force_reservation_flag => fnd_api.g_false
1538: , p_validation_flag => fnd_api.g_true
1539: --, p_validation_flag => fnd_api.g_false
1540: , x_quantity_reserved => l_qty
1541: , x_secondary_quantity_reserved => l_second_qty
1542: , x_reservation_id => l_rsv_id

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

1535: , x_serial_number => g_dummy_sn_tbl
1536: , p_partial_reservation_flag => fnd_api.g_true
1537: , p_force_reservation_flag => fnd_api.g_false
1538: , p_validation_flag => fnd_api.g_true
1539: --, p_validation_flag => fnd_api.g_false
1540: , x_quantity_reserved => l_qty
1541: , x_secondary_quantity_reserved => l_second_qty
1542: , x_reservation_id => l_rsv_id
1543: );

Line 1552: if x_return_status = fnd_api.g_ret_sts_success then

1548: end if;
1549:
1550: x_return_status := l_return_status;
1551:
1552: if x_return_status = fnd_api.g_ret_sts_success then
1553: l_fnd_log_message := 'calling create_reservation api was successful ';
1554: -- fnd_log_debug(fnd_log.level_error,c_module_name, l_fnd_log_message );
1555: if g_debug= c_debug_enabled then
1556: mydebug(l_fnd_log_message, c_api_name,9);

Line 1575: when fnd_api.g_exc_error then

1571: mydebug(l_fnd_log_message, c_api_name,9);
1572: end if;
1573:
1574: exception
1575: when fnd_api.g_exc_error then
1576: x_return_status := fnd_api.g_ret_sts_error;
1577:
1578: -- get message count and data
1579: fnd_msg_pub.count_and_get

Line 1576: x_return_status := fnd_api.g_ret_sts_error;

1572: end if;
1573:
1574: exception
1575: when fnd_api.g_exc_error then
1576: x_return_status := fnd_api.g_ret_sts_error;
1577:
1578: -- get message count and data
1579: fnd_msg_pub.count_and_get
1580: ( p_count => x_msg_count

Line 1618: when fnd_api.g_exc_unexpected_error then

1614: end loop ;
1615: end if;
1616:
1617:
1618: when fnd_api.g_exc_unexpected_error then
1619: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1620:
1621: -- get message count and data
1622: fnd_msg_pub.count_and_get

Line 1619: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1615: end if;
1616:
1617:
1618: when fnd_api.g_exc_unexpected_error then
1619: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1620:
1621: -- get message count and data
1622: fnd_msg_pub.count_and_get
1623: ( p_count => x_msg_count

Line 1661: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1657: end loop ;
1658: end if;
1659:
1660: when others then
1661: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1662:
1663: if fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
1664: then
1665: fnd_msg_pub.add_exc_msg

Line 1759: l_return_status := FND_API.g_ret_sts_success;

1755: G_Version_Printed := FALSE ;
1756: END IF;
1757:
1758: -- Bug 3600118: Initialize return status variable
1759: l_return_status := FND_API.g_ret_sts_success;
1760:
1761: IF p_supply_source_header_id is not null THEN
1762: l_rsv_rec.supply_source_header_id := p_supply_source_header_id; --supply header id
1763: END IF;

Line 1772: RAISE fnd_api.g_exc_unexpected_error;

1768:
1769: IF p_supply_source_type_id IS NULL THEN
1770: FND_MESSAGE.SET_NAME('INV','INV_API_NULL_SOURCE_TYPE_ID');
1771: FND_MSG_PUB.Add;
1772: RAISE fnd_api.g_exc_unexpected_error;
1773: ELSIF p_supply_source_type_id NOT IN
1774: (inv_reservation_global.g_source_type_po,
1775: inv_reservation_global.g_source_type_internal_req,
1776: inv_reservation_global.g_source_type_req) THEN

Line 1779: RAISE fnd_api.g_exc_unexpected_error;

1775: inv_reservation_global.g_source_type_internal_req,
1776: inv_reservation_global.g_source_type_req) THEN
1777: FND_MESSAGE.SET_NAME('INV','INV_API_INVALID_SOURCE_TYPE_ID');
1778: FND_MSG_PUB.Add;
1779: RAISE fnd_api.g_exc_unexpected_error;
1780: END IF;
1781:
1782: IF p_project_id is not null THEN
1783: l_rsv_rec.project_id := p_project_id; -- project id

Line 1795: , p_init_msg_lst => fnd_api.g_false

1791:
1792: inv_reservation_pvt.query_reservation
1793: (
1794: p_api_version_number => 1.0
1795: , p_init_msg_lst => fnd_api.g_false
1796: , x_return_status => l_return_status
1797: , x_msg_count => x_msg_count
1798: , x_msg_data => x_msg_data
1799: , p_query_input => l_rsv_rec

Line 1800: , p_lock_records => fnd_api.g_false

1796: , x_return_status => l_return_status
1797: , x_msg_count => x_msg_count
1798: , x_msg_data => x_msg_data
1799: , p_query_input => l_rsv_rec
1800: , p_lock_records => fnd_api.g_false
1801: , p_sort_by_req_date => inv_reservation_global.g_query_demand_ship_date_asc
1802: , p_cancel_order_mode => inv_reservation_global.g_cancel_order_no
1803: , x_mtl_reservation_tbl => l_rsv_array
1804: , x_mtl_reservation_tbl_count => l_record_count

Line 1815: If x_return_status = fnd_api.g_ret_sts_success THEN

1811: End If;
1812:
1813: x_return_status := l_return_status;
1814:
1815: If x_return_status = fnd_api.g_ret_sts_success THEN
1816: l_Fnd_Log_message := 'Calling query_reservation API was successful ';
1817: -- Fnd_Log_Debug(fnd_log.Level_Error,C_Module_name, l_Fnd_Log_Message );
1818: x_rsv_array := l_rsv_array;
1819: x_record_count := l_record_count;

Line 1844: WHEN fnd_api.g_exc_error THEN

1840:
1841:
1842:
1843: EXCEPTION
1844: WHEN fnd_api.g_exc_error THEN
1845: x_return_status := fnd_api.g_ret_sts_error;
1846: x_record_count := -1;
1847:
1848: -- Get message count and data

Line 1845: x_return_status := fnd_api.g_ret_sts_error;

1841:
1842:
1843: EXCEPTION
1844: WHEN fnd_api.g_exc_error THEN
1845: x_return_status := fnd_api.g_ret_sts_error;
1846: x_record_count := -1;
1847:
1848: -- Get message count and data
1849: fnd_msg_pub.count_and_get

Line 1888: WHEN fnd_api.g_exc_unexpected_error THEN

1884: End Loop ;
1885: End If;
1886:
1887:
1888: WHEN fnd_api.g_exc_unexpected_error THEN
1889: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1890: x_record_count := -1;
1891:
1892: -- Get message count and data

Line 1889: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1885: End If;
1886:
1887:
1888: WHEN fnd_api.g_exc_unexpected_error THEN
1889: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1890: x_record_count := -1;
1891:
1892: -- Get message count and data
1893: fnd_msg_pub.count_and_get

Line 1932: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1928: End Loop ;
1929: End If;
1930:
1931: WHEN OTHERS THEN
1932: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1933: x_record_count := -1;
1934:
1935: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
1936: THEN

Line 2040: If l_return_status = fnd_api.g_ret_sts_success THEN

2036: mydebug(l_Fnd_Log_Message,c_api_name,9);
2037: End If;
2038:
2039:
2040: If l_return_status = fnd_api.g_ret_sts_success THEN
2041: l_Fnd_Log_message := 'Calling QUERY_RES API was successful ';
2042: -- Fnd_Log_Debug(fnd_log.Level_Error,C_Module_name, l_Fnd_Log_Message );
2043: IF G_debug= C_Debug_Enabled THEN
2044: mydebug(l_Fnd_Log_Message, c_api_name,9);

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

2128: G_Version_Printed := FALSE ;
2129: END IF;
2130:
2131: -- Bug 3600118: Initialize return status variable
2132: --l_return_status := FND_API.g_ret_sts_success;
2133: --
2134: -- bug fix 2341308
2135: if p_req_line_id IS NULL then
2136: l_Fnd_Log_message := 'p_req_line_id is NULL :';

Line 2162: If l_return_status = fnd_api.g_ret_sts_success THEN

2158: l_Fnd_Log_Message := 'l_return_status: '||l_return_status;
2159: mydebug(l_Fnd_Log_Message,c_api_name,9);
2160: End If;
2161:
2162: If l_return_status = fnd_api.g_ret_sts_success THEN
2163: l_Fnd_Log_message := 'Calling QUERY_RES API was successful ';
2164: -- Fnd_Log_Debug(fnd_log.Level_Error,C_Module_name, l_Fnd_Log_Message );
2165: IF G_debug= C_Debug_Enabled THEN
2166: mydebug(l_Fnd_Log_Message, c_api_name,9);

Line 2242: l_return_status := FND_API.g_ret_sts_success;

2238: G_Version_Printed := FALSE ;
2239: END IF;
2240:
2241: -- Bug 3600118: Initialize return status variable
2242: l_return_status := FND_API.g_ret_sts_success;
2243:
2244: -- find the existing reservation
2245: -- REQ or PO id's
2246: l_rsv.supply_source_header_id := p_supply_source_header_id;

Line 2262: , p_init_msg_lst => fnd_api.g_false

2258: --
2259: inv_reservation_pub.update_reservation
2260: (
2261: p_api_version_number => 1.0
2262: , p_init_msg_lst => fnd_api.g_false
2263: , x_return_status => l_return_status
2264: , x_msg_count => x_msg_count
2265: , x_msg_data => x_msg_data
2266: , p_original_rsv_rec => l_rsv

Line 2270: , p_validation_flag => fnd_api.g_true

2266: , p_original_rsv_rec => l_rsv
2267: , p_to_rsv_rec => l_rsv_new
2268: , p_original_serial_number => g_dummy_sn_tbl -- no serial contorl
2269: , p_to_serial_number => g_dummy_sn_tbl -- no serial control
2270: , p_validation_flag => fnd_api.g_true
2271: );
2272:
2273: If g_debug= C_Debug_Enabled Then
2274: l_Fnd_Log_Message := 'l_return_status: '||l_return_status;

Line 2280: If x_return_status = fnd_api.g_ret_sts_success THEN

2276: End If;
2277:
2278: x_return_status := l_return_status;
2279:
2280: If x_return_status = fnd_api.g_ret_sts_success THEN
2281: l_Fnd_Log_message := 'Calling update_reservation API was successful ';
2282: -- Fnd_Log_Debug(fnd_log.Level_Error,C_Module_name, l_Fnd_Log_Message );
2283: IF G_debug= C_Debug_Enabled THEN
2284: mydebug(l_Fnd_Log_Message, c_api_name,9);

Line 2304: WHEN fnd_api.g_exc_error THEN

2300: END IF;
2301:
2302:
2303: EXCEPTION
2304: WHEN fnd_api.g_exc_error THEN
2305: x_return_status := fnd_api.g_ret_sts_error;
2306:
2307: -- Get message count and data
2308: fnd_msg_pub.count_and_get

Line 2305: x_return_status := fnd_api.g_ret_sts_error;

2301:
2302:
2303: EXCEPTION
2304: WHEN fnd_api.g_exc_error THEN
2305: x_return_status := fnd_api.g_ret_sts_error;
2306:
2307: -- Get message count and data
2308: fnd_msg_pub.count_and_get
2309: ( p_count => x_msg_count

Line 2347: WHEN fnd_api.g_exc_unexpected_error THEN

2343: End Loop ;
2344: End If;
2345:
2346:
2347: WHEN fnd_api.g_exc_unexpected_error THEN
2348: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2349:
2350: -- Get message count and data
2351: fnd_msg_pub.count_and_get

Line 2348: x_return_status := fnd_api.g_ret_sts_unexp_error ;

2344: End If;
2345:
2346:
2347: WHEN fnd_api.g_exc_unexpected_error THEN
2348: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2349:
2350: -- Get message count and data
2351: fnd_msg_pub.count_and_get
2352: ( p_count => x_msg_count

Line 2390: x_return_status := fnd_api.g_ret_sts_unexp_error ;

2386: End Loop ;
2387: End If;
2388:
2389: WHEN OTHERS THEN
2390: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2391:
2392: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
2393: THEN
2394: fnd_msg_pub.add_exc_msg

Line 2497: l_return_status := FND_API.g_ret_sts_success;

2493: G_Version_Printed := FALSE ;
2494: END IF;
2495:
2496: -- Bug 3600118: Initialize return status variable
2497: l_return_status := FND_API.g_ret_sts_success;
2498:
2499: -- print out IN parameter values
2500: IF g_debug= C_Debug_Enabled THEN
2501: l_Fnd_Log_Message := 'p_from_reservation_id:' || p_from_reservation_id;

Line 2573: , p_init_msg_lst => fnd_api.g_false

2569:
2570: inv_reservation_pvt.transfer_reservation
2571: (
2572: p_api_version_number => 1.0
2573: , p_init_msg_lst => fnd_api.g_false
2574: , x_return_status => l_return_status
2575: , x_msg_count => x_msg_count
2576: , x_msg_data => x_msg_data
2577: --, p_is_transfer_supply => fnd_api.g_true

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

2573: , p_init_msg_lst => fnd_api.g_false
2574: , x_return_status => l_return_status
2575: , x_msg_count => x_msg_count
2576: , x_msg_data => x_msg_data
2577: --, p_is_transfer_supply => fnd_api.g_true
2578: , p_original_rsv_rec => l_rsv
2579: , p_to_rsv_rec => l_rsv_new
2580: , p_original_serial_number => g_dummy_sn_tbl -- no serial contorl
2581: -- , p_to_serial_number => g_dummy_sn_tbl -- no serial control

Line 2582: , p_validation_flag => fnd_api.g_true

2578: , p_original_rsv_rec => l_rsv
2579: , p_to_rsv_rec => l_rsv_new
2580: , p_original_serial_number => g_dummy_sn_tbl -- no serial contorl
2581: -- , p_to_serial_number => g_dummy_sn_tbl -- no serial control
2582: , p_validation_flag => fnd_api.g_true
2583: , x_reservation_id => l_new_rsv_id
2584: );
2585:
2586: If g_debug= C_Debug_Enabled Then

Line 2593: If x_return_status = fnd_api.g_ret_sts_success THEN

2589: End If;
2590:
2591: x_return_status := l_return_status;
2592:
2593: If x_return_status = fnd_api.g_ret_sts_success THEN
2594: l_Fnd_Log_message := 'Calling transfer_reservation API was successful ';
2595: -- Fnd_Log_Debug(fnd_log.Level_Error,C_Module_name, l_Fnd_Log_Message );
2596: IF G_debug= C_Debug_Enabled THEN
2597: mydebug(l_Fnd_Log_Message, c_api_name,9);

Line 2616: WHEN fnd_api.g_exc_error THEN

2612: mydebug(l_Fnd_Log_Message, c_api_name,9);
2613: END IF;
2614:
2615: EXCEPTION
2616: WHEN fnd_api.g_exc_error THEN
2617: x_return_status := fnd_api.g_ret_sts_error;
2618:
2619: -- Get message count and data
2620: fnd_msg_pub.count_and_get

Line 2617: x_return_status := fnd_api.g_ret_sts_error;

2613: END IF;
2614:
2615: EXCEPTION
2616: WHEN fnd_api.g_exc_error THEN
2617: x_return_status := fnd_api.g_ret_sts_error;
2618:
2619: -- Get message count and data
2620: fnd_msg_pub.count_and_get
2621: ( p_count => x_msg_count

Line 2658: WHEN fnd_api.g_exc_unexpected_error THEN

2654: END IF;
2655: End Loop ;
2656: End If;
2657:
2658: WHEN fnd_api.g_exc_unexpected_error THEN
2659: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2660:
2661: -- Get message count and data
2662: fnd_msg_pub.count_and_get

Line 2659: x_return_status := fnd_api.g_ret_sts_unexp_error ;

2655: End Loop ;
2656: End If;
2657:
2658: WHEN fnd_api.g_exc_unexpected_error THEN
2659: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2660:
2661: -- Get message count and data
2662: fnd_msg_pub.count_and_get
2663: ( p_count => x_msg_count

Line 2701: x_return_status := fnd_api.g_ret_sts_unexp_error ;

2697: End Loop ;
2698: End If;
2699:
2700: WHEN OTHERS THEN
2701: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2702:
2703: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
2704: THEN
2705: fnd_msg_pub.add_exc_msg

Line 2793: l_return_status := FND_API.g_ret_sts_success;

2789: G_Version_Printed := FALSE ;
2790: END IF;
2791:
2792: -- Bug 3600118: Initialize return status variable
2793: l_return_status := FND_API.g_ret_sts_success;
2794:
2795: -- print out IN parameter values
2796: IF G_debug= C_Debug_Enabled THEN
2797: l_Fnd_Log_Message := 'p_supply_source_header_id: '|| p_supply_source_header_id;

Line 2818: , p_init_msg_lst => fnd_api.g_false

2814: --
2815: inv_reservation_pub.delete_reservation
2816: (
2817: p_api_version_number => 1.0
2818: , p_init_msg_lst => fnd_api.g_false
2819: , x_return_status => l_return_status
2820: , x_msg_count => x_msg_count
2821: , x_msg_data => x_msg_data
2822: , p_rsv_rec => l_rsv

Line 2833: If x_return_status = fnd_api.g_ret_sts_success THEN

2829: End If;
2830:
2831: x_return_status := l_return_status;
2832:
2833: If x_return_status = fnd_api.g_ret_sts_success THEN
2834: l_Fnd_Log_message := 'Calling delete_reservation API was successful ';
2835: -- Fnd_Log_Debug(fnd_log.Level_Error,C_Module_name, l_Fnd_Log_Message );
2836: IF G_debug= C_Debug_Enabled THEN
2837: mydebug(l_Fnd_Log_Message, c_api_name,9);

Line 2855: WHEN fnd_api.g_exc_error THEN

2851: IF G_debug= C_Debug_Enabled THEN
2852: mydebug(l_Fnd_Log_Message, c_api_name,9);
2853: END IF;
2854: EXCEPTION
2855: WHEN fnd_api.g_exc_error THEN
2856: x_return_status := fnd_api.g_ret_sts_error;
2857:
2858: -- Get message count and data
2859: fnd_msg_pub.count_and_get

Line 2856: x_return_status := fnd_api.g_ret_sts_error;

2852: mydebug(l_Fnd_Log_Message, c_api_name,9);
2853: END IF;
2854: EXCEPTION
2855: WHEN fnd_api.g_exc_error THEN
2856: x_return_status := fnd_api.g_ret_sts_error;
2857:
2858: -- Get message count and data
2859: fnd_msg_pub.count_and_get
2860: ( p_count => x_msg_count

Line 2897: WHEN fnd_api.g_exc_unexpected_error THEN

2893: END IF;
2894: End Loop ;
2895: End If;
2896:
2897: WHEN fnd_api.g_exc_unexpected_error THEN
2898: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2899:
2900: -- Get message count and data
2901: fnd_msg_pub.count_and_get

Line 2898: x_return_status := fnd_api.g_ret_sts_unexp_error ;

2894: End Loop ;
2895: End If;
2896:
2897: WHEN fnd_api.g_exc_unexpected_error THEN
2898: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2899:
2900: -- Get message count and data
2901: fnd_msg_pub.count_and_get
2902: ( p_count => x_msg_count

Line 2940: x_return_status := fnd_api.g_ret_sts_unexp_error ;

2936: End Loop ;
2937: End If;
2938:
2939: WHEN OTHERS THEN
2940: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2941:
2942: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
2943: THEN
2944: fnd_msg_pub.add_exc_msg

Line 3179: , p_init_msg_lst IN VARCHAR2 DEFAULT fnd_api.g_false

3175:
3176: PROCEDURE MAINTAIN_RESERVATION
3177: (
3178: p_api_version_number IN NUMBER DEFAULT 1.0
3179: , p_init_msg_lst IN VARCHAR2 DEFAULT fnd_api.g_false
3180: , p_header_id IN NUMBER DEFAULT NULL
3181: , p_line_id IN NUMBER DEFAULT NULL
3182: , p_line_location_id IN NUMBER DEFAULT NULL
3183: , p_distribution_id IN NUMBER DEFAULT NULL

Line 3654: l_return_status := FND_API.g_ret_sts_success;

3650: g_Version_Printed := FALSE ;
3651: END IF;
3652:
3653: -- Bug 3600118: Initialize return status variable
3654: l_return_status := FND_API.g_ret_sts_success;
3655:
3656: -- print out all the IN paramter values
3657: IF g_debug= C_Debug_Enabled THEN
3658: l_Fnd_Log_Message := 'p_header_id : '|| p_header_id ;

Line 3682: RAISE fnd_api.g_exc_unexpected_error;

3678: IF g_debug = C_Debug_Enabled THEN
3679: l_Fnd_Log_Message := 'Null action code';
3680: mydebug(l_Fnd_Log_Message, c_api_name,9);
3681: END IF;
3682: RAISE fnd_api.g_exc_unexpected_error;
3683: END IF;
3684:
3685: IF upper(p_action) = 'APPROVE_REQ_SUPPLY' THEN
3686: --replace with FOR Loops

Line 3838: If x_return_status = fnd_api.g_ret_sts_success THEN

3834: END IF;
3835:
3836: x_return_status := l_return_status;
3837:
3838: If x_return_status = fnd_api.g_ret_sts_success THEN
3839: l_Fnd_Log_message := 'Calling CREATE_RES API was successful ';
3840: -- Fnd_Log_Debug(fnd_log.Level_Error,C_Module_name, l_Fnd_Log_Message );
3841: IF G_debug= C_Debug_Enabled THEN
3842: mydebug(l_Fnd_Log_Message, c_api_name,9);

Line 4163: , p_init_msg_lst => fnd_api.g_false

4159:
4160: reduce_reservation
4161: (
4162: p_api_version_number => 1.0
4163: , p_init_msg_lst => fnd_api.g_false
4164: , x_return_status => l_return_status
4165: , x_msg_count => x_msg_count
4166: , x_msg_data => x_msg_data
4167: , p_mtl_maintain_rsv_rec => l_mtl_maint_rsv_rec

Line 4175: IF l_return_status = fnd_api.g_ret_sts_error THEN

4171: IF g_debug= C_Debug_Enabled THEN
4172: mydebug ('Return Status after calling reduce reservations: '|| l_return_status, c_api_name,9);
4173: END IF;
4174:
4175: IF l_return_status = fnd_api.g_ret_sts_error THEN
4176:
4177: IF g_debug= C_Debug_Enabled THEN
4178: mydebug('Raising expected error'||l_return_status, c_api_name,9);
4179: END IF;

Line 4180: RAISE fnd_api.g_exc_error;

4176:
4177: IF g_debug= C_Debug_Enabled THEN
4178: mydebug('Raising expected error'||l_return_status, c_api_name,9);
4179: END IF;
4180: RAISE fnd_api.g_exc_error;
4181:
4182: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
4183:
4184: IF g_debug= C_Debug_Enabled THEN

Line 4182: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

4178: mydebug('Raising expected error'||l_return_status, c_api_name,9);
4179: END IF;
4180: RAISE fnd_api.g_exc_error;
4181:
4182: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
4183:
4184: IF g_debug= C_Debug_Enabled THEN
4185: mydebug('Rasing Unexpected error'||l_return_status, c_api_name,9);
4186: END IF;

Line 4187: RAISE fnd_api.g_exc_unexpected_error;

4183:
4184: IF g_debug= C_Debug_Enabled THEN
4185: mydebug('Rasing Unexpected error'||l_return_status, c_api_name,9);
4186: END IF;
4187: RAISE fnd_api.g_exc_unexpected_error;
4188:
4189: END IF;
4190: /***** Call reduce reservations instead of delete reservations
4191: DELETE_RES

Line 4293: , p_init_msg_lst => fnd_api.g_false

4289:
4290: reduce_reservation
4291: (
4292: p_api_version_number => 1.0
4293: , p_init_msg_lst => fnd_api.g_false
4294: , x_return_status => l_return_status
4295: , x_msg_count => x_msg_count
4296: , x_msg_data => x_msg_data
4297: , p_mtl_maintain_rsv_rec => l_mtl_maint_rsv_rec

Line 4306: IF l_return_status = fnd_api.g_ret_sts_error THEN

4302: IF g_debug= C_Debug_Enabled THEN
4303: mydebug ('Return Status after calling reduce reservations: '|| l_return_status, c_api_name,9);
4304: END IF;
4305:
4306: IF l_return_status = fnd_api.g_ret_sts_error THEN
4307:
4308: IF g_debug= C_Debug_Enabled THEN
4309: mydebug('Raising expected error'||l_return_status, c_api_name,9);
4310: END IF;

Line 4311: RAISE fnd_api.g_exc_error;

4307:
4308: IF g_debug= C_Debug_Enabled THEN
4309: mydebug('Raising expected error'||l_return_status, c_api_name,9);
4310: END IF;
4311: RAISE fnd_api.g_exc_error;
4312:
4313: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
4314:
4315: IF g_debug= C_Debug_Enabled THEN

Line 4313: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

4309: mydebug('Raising expected error'||l_return_status, c_api_name,9);
4310: END IF;
4311: RAISE fnd_api.g_exc_error;
4312:
4313: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
4314:
4315: IF g_debug= C_Debug_Enabled THEN
4316: mydebug('Rasing Unexpected error'||l_return_status, c_api_name,9);
4317: END IF;

Line 4318: RAISE fnd_api.g_exc_unexpected_error;

4314:
4315: IF g_debug= C_Debug_Enabled THEN
4316: mydebug('Rasing Unexpected error'||l_return_status, c_api_name,9);
4317: END IF;
4318: RAISE fnd_api.g_exc_unexpected_error;
4319:
4320: END IF;
4321:
4322: END IF;

Line 4346: RAISE fnd_api.g_exc_error;

4342:
4343: IF (p_transaction_id IS NULL) THEN
4344: FND_MESSAGE.SET_NAME('INV','INV_INVALID_TRANSACTION_ID');
4345: FND_MSG_PUB.ADD;
4346: RAISE fnd_api.g_exc_error;
4347: END IF;
4348:
4349: OPEN get_source_doc_code(p_transaction_id);
4350: FETCH get_source_doc_code INTO get_source_doc_code_rec;

Line 4366: RAISE fnd_api.g_exc_error;

4362: IF (get_source_doc_code_rec.organization_id IS NULL) THEN
4363: IF g_debug= C_Debug_Enabled THEN
4364: mydebug('Could not find the organization for the transaction id:' || p_transaction_id, c_api_name,9);
4365: END IF;
4366: RAISE fnd_api.g_exc_error;
4367: END IF;
4368:
4369: IF (inv_install.adv_inv_installed(get_source_doc_code_rec.organization_id)) THEN
4370: -- wms org

Line 5373: , p_init_msg_lst => fnd_api.g_false

5369:
5370: reduce_reservation
5371: (
5372: p_api_version_number => 1.0
5373: , p_init_msg_lst => fnd_api.g_false
5374: , x_return_status => l_return_status
5375: , x_msg_count => x_msg_count
5376: , x_msg_data => x_msg_data
5377: , p_mtl_maintain_rsv_rec => l_mtl_maint_rsv_rec

Line 5385: IF l_return_status = fnd_api.g_ret_sts_error THEN

5381: IF g_debug= C_Debug_Enabled THEN
5382: mydebug ('Return Status after calling reduce reservations: '|| l_return_status, c_api_name,9);
5383: END IF;
5384:
5385: IF l_return_status = fnd_api.g_ret_sts_error THEN
5386:
5387: IF g_debug= C_Debug_Enabled THEN
5388: mydebug('Raising expected error'||l_return_status, c_api_name,9);
5389: END IF;

Line 5390: RAISE fnd_api.g_exc_error;

5386:
5387: IF g_debug= C_Debug_Enabled THEN
5388: mydebug('Raising expected error'||l_return_status, c_api_name,9);
5389: END IF;
5390: RAISE fnd_api.g_exc_error;
5391:
5392: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5393:
5394: IF g_debug= C_Debug_Enabled THEN

Line 5392: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

5388: mydebug('Raising expected error'||l_return_status, c_api_name,9);
5389: END IF;
5390: RAISE fnd_api.g_exc_error;
5391:
5392: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5393:
5394: IF g_debug= C_Debug_Enabled THEN
5395: mydebug('Rasing Unexpected error'||l_return_status, c_api_name,9);
5396: END IF;

Line 5397: RAISE fnd_api.g_exc_unexpected_error;

5393:
5394: IF g_debug= C_Debug_Enabled THEN
5395: mydebug('Rasing Unexpected error'||l_return_status, c_api_name,9);
5396: END IF;
5397: RAISE fnd_api.g_exc_unexpected_error;
5398:
5399: END IF;
5400: END IF;
5401: END IF;

Line 5485: , p_Init_Msg_Lst => fnd_api.g_false

5481:
5482: reduce_reservation
5483: (
5484: p_API_Version_Number => 1.0
5485: , p_Init_Msg_Lst => fnd_api.g_false
5486: , x_Return_Status => l_return_status
5487: , x_Msg_Count => x_msg_count
5488: , x_Msg_Data => x_msg_data
5489: , p_Mtl_Maintain_Rsv_rec=> l_mtl_maint_rsv_rec

Line 5498: IF l_return_status = fnd_api.g_ret_sts_error THEN

5494: IF g_debug= C_Debug_Enabled THEN
5495: mydebug ('Return Status after calling reduce reservations: '|| l_return_status, c_api_name,9);
5496: END IF;
5497:
5498: IF l_return_status = fnd_api.g_ret_sts_error THEN
5499:
5500: IF g_debug= C_Debug_Enabled THEN
5501: mydebug('Raising expected error'||l_return_status, c_api_name,9);
5502: END IF;

Line 5503: RAISE fnd_api.g_exc_error;

5499:
5500: IF g_debug= C_Debug_Enabled THEN
5501: mydebug('Raising expected error'||l_return_status, c_api_name,9);
5502: END IF;
5503: RAISE fnd_api.g_exc_error;
5504:
5505: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5506:
5507: IF g_debug= C_Debug_Enabled THEN

Line 5505: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

5501: mydebug('Raising expected error'||l_return_status, c_api_name,9);
5502: END IF;
5503: RAISE fnd_api.g_exc_error;
5504:
5505: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5506:
5507: IF g_debug= C_Debug_Enabled THEN
5508: mydebug('Rasing Unexpected error'||l_return_status, c_api_name,9);
5509: END IF;

Line 5510: RAISE fnd_api.g_exc_unexpected_error;

5506:
5507: IF g_debug= C_Debug_Enabled THEN
5508: mydebug('Rasing Unexpected error'||l_return_status, c_api_name,9);
5509: END IF;
5510: RAISE fnd_api.g_exc_unexpected_error;
5511:
5512: END IF;
5513:
5514: END IF;

Line 5634: , p_init_msg_lst => fnd_api.g_false

5630:
5631: reduce_reservation
5632: (
5633: p_api_version_number => 1.0
5634: , p_init_msg_lst => fnd_api.g_false
5635: , x_return_status => l_return_status
5636: , x_msg_count => x_msg_count
5637: , x_msg_data => x_msg_data
5638: , p_mtl_maintain_rsv_rec => l_mtl_maint_rsv_rec

Line 5646: IF l_return_status = fnd_api.g_ret_sts_error THEN

5642: IF g_debug= C_Debug_Enabled THEN
5643: mydebug ('Return Status after calling reduce reservations: '|| l_return_status, c_api_name,9);
5644: END IF;
5645:
5646: IF l_return_status = fnd_api.g_ret_sts_error THEN
5647:
5648: IF g_debug= C_Debug_Enabled THEN
5649: mydebug('Raising expected error'||l_return_status, c_api_name,9);
5650: END IF;

Line 5651: RAISE fnd_api.g_exc_error;

5647:
5648: IF g_debug= C_Debug_Enabled THEN
5649: mydebug('Raising expected error'||l_return_status, c_api_name,9);
5650: END IF;
5651: RAISE fnd_api.g_exc_error;
5652:
5653: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5654:
5655: IF g_debug= C_Debug_Enabled THEN

Line 5653: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

5649: mydebug('Raising expected error'||l_return_status, c_api_name,9);
5650: END IF;
5651: RAISE fnd_api.g_exc_error;
5652:
5653: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5654:
5655: IF g_debug= C_Debug_Enabled THEN
5656: mydebug('Rasing Unexpected error'||l_return_status, c_api_name,9);
5657: END IF;

Line 5658: RAISE fnd_api.g_exc_unexpected_error;

5654:
5655: IF g_debug= C_Debug_Enabled THEN
5656: mydebug('Rasing Unexpected error'||l_return_status, c_api_name,9);
5657: END IF;
5658: RAISE fnd_api.g_exc_unexpected_error;
5659:
5660: END IF;
5661: END LOOP; --get_distr
5662:

Line 5711: , p_init_msg_lst => fnd_api.g_false

5707:
5708: reduce_reservation
5709: (
5710: p_api_version_number => 1.0
5711: , p_init_msg_lst => fnd_api.g_false
5712: , x_return_status => l_return_status
5713: , x_msg_count => x_msg_count
5714: , x_msg_data => x_msg_data
5715: , p_mtl_maintain_rsv_rec => l_mtl_maint_rsv_rec

Line 5723: IF l_return_status = fnd_api.g_ret_sts_error THEN

5719: IF g_debug= C_Debug_Enabled THEN
5720: mydebug ('Return Status after calling reduce reservations: '|| l_return_status, c_api_name,9);
5721: END IF;
5722:
5723: IF l_return_status = fnd_api.g_ret_sts_error THEN
5724:
5725: IF g_debug= C_Debug_Enabled THEN
5726: mydebug('Raising expected error'||l_return_status, c_api_name,9);
5727: END IF;

Line 5728: RAISE fnd_api.g_exc_error;

5724:
5725: IF g_debug= C_Debug_Enabled THEN
5726: mydebug('Raising expected error'||l_return_status, c_api_name,9);
5727: END IF;
5728: RAISE fnd_api.g_exc_error;
5729:
5730: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5731:
5732: IF g_debug= C_Debug_Enabled THEN

Line 5730: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

5726: mydebug('Raising expected error'||l_return_status, c_api_name,9);
5727: END IF;
5728: RAISE fnd_api.g_exc_error;
5729:
5730: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5731:
5732: IF g_debug= C_Debug_Enabled THEN
5733: mydebug('Rasing Unexpected error'||l_return_status, c_api_name,9);
5734: END IF;

Line 5735: RAISE fnd_api.g_exc_unexpected_error;

5731:
5732: IF g_debug= C_Debug_Enabled THEN
5733: mydebug('Rasing Unexpected error'||l_return_status, c_api_name,9);
5734: END IF;
5735: RAISE fnd_api.g_exc_unexpected_error;
5736:
5737: END IF;
5738: END LOOP;
5739: END IF; --Reservation Exists

Line 5789: , p_init_msg_lst => fnd_api.g_false

5785:
5786: reduce_reservation
5787: (
5788: p_api_version_number => 1.0
5789: , p_init_msg_lst => fnd_api.g_false
5790: , x_return_status => l_return_status
5791: , x_msg_count => x_msg_count
5792: , x_msg_data => x_msg_data
5793: , p_mtl_maintain_rsv_rec => l_mtl_maint_rsv_rec

Line 5801: IF l_return_status = fnd_api.g_ret_sts_error THEN

5797: IF g_debug= C_Debug_Enabled THEN
5798: mydebug ('Return Status after calling reduce reservations: '|| l_return_status, c_api_name,9);
5799: END IF;
5800:
5801: IF l_return_status = fnd_api.g_ret_sts_error THEN
5802:
5803: IF g_debug= C_Debug_Enabled THEN
5804: mydebug('Raising expected error'||l_return_status, c_api_name,9);
5805: END IF;

Line 5806: RAISE fnd_api.g_exc_error;

5802:
5803: IF g_debug= C_Debug_Enabled THEN
5804: mydebug('Raising expected error'||l_return_status, c_api_name,9);
5805: END IF;
5806: RAISE fnd_api.g_exc_error;
5807:
5808: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5809:
5810: IF g_debug= C_Debug_Enabled THEN

Line 5808: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

5804: mydebug('Raising expected error'||l_return_status, c_api_name,9);
5805: END IF;
5806: RAISE fnd_api.g_exc_error;
5807:
5808: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5809:
5810: IF g_debug= C_Debug_Enabled THEN
5811: mydebug('Rasing Unexpected error'||l_return_status, c_api_name,9);
5812: END IF;

Line 5813: RAISE fnd_api.g_exc_unexpected_error;

5809:
5810: IF g_debug= C_Debug_Enabled THEN
5811: mydebug('Rasing Unexpected error'||l_return_status, c_api_name,9);
5812: END IF;
5813: RAISE fnd_api.g_exc_unexpected_error;
5814:
5815: END IF;
5816:
5817: END IF; --Reservation Exists

Line 5882: , p_init_msg_lst => fnd_api.g_false

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

Line 5894: IF l_return_status = fnd_api.g_ret_sts_error THEN

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

Line 5899: RAISE fnd_api.g_exc_error;

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

Line 5901: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

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

Line 5906: RAISE fnd_api.g_exc_unexpected_error;

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

Line 5962: , p_init_msg_lst => fnd_api.g_false

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

Line 5974: IF l_return_status = fnd_api.g_ret_sts_error THEN

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

Line 5979: RAISE fnd_api.g_exc_error;

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

Line 5981: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

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

Line 5986: RAISE fnd_api.g_exc_unexpected_error;

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

Line 6052: , p_init_msg_lst => fnd_api.g_false

6048:
6049: reduce_reservation
6050: (
6051: p_api_version_number => 1.0
6052: , p_init_msg_lst => fnd_api.g_false
6053: , x_return_status => l_return_status
6054: , x_msg_count => x_msg_count
6055: , x_msg_data => x_msg_data
6056: , p_mtl_maintain_rsv_rec => l_mtl_maint_rsv_rec

Line 6066: IF l_return_status = fnd_api.g_ret_sts_error THEN

6062: mydebug ('Expected qty: '|| p_ordered_quantity, c_api_name,9);
6063: mydebug ('Modified qty: '|| l_quantity_modified, c_api_name,9);
6064: END IF;
6065:
6066: IF l_return_status = fnd_api.g_ret_sts_error THEN
6067:
6068: IF g_debug= C_Debug_Enabled THEN
6069: mydebug('Raising expected error'||l_return_status, c_api_name,9);
6070: END IF;

Line 6071: RAISE fnd_api.g_exc_error;

6067:
6068: IF g_debug= C_Debug_Enabled THEN
6069: mydebug('Raising expected error'||l_return_status, c_api_name,9);
6070: END IF;
6071: RAISE fnd_api.g_exc_error;
6072:
6073: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6074:
6075: IF g_debug= C_Debug_Enabled THEN

Line 6073: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

6069: mydebug('Raising expected error'||l_return_status, c_api_name,9);
6070: END IF;
6071: RAISE fnd_api.g_exc_error;
6072:
6073: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6074:
6075: IF g_debug= C_Debug_Enabled THEN
6076: mydebug('Rasing Unexpected error'||l_return_status, c_api_name,9);
6077: END IF;

Line 6078: RAISE fnd_api.g_exc_unexpected_error;

6074:
6075: IF g_debug= C_Debug_Enabled THEN
6076: mydebug('Rasing Unexpected error'||l_return_status, c_api_name,9);
6077: END IF;
6078: RAISE fnd_api.g_exc_unexpected_error;
6079:
6080: END IF;
6081:
6082: ELSE

Line 6102: , p_init_msg_lst => fnd_api.g_false

6098:
6099: reduce_reservation
6100: (
6101: p_api_version_number => 1.0
6102: , p_init_msg_lst => fnd_api.g_false
6103: , x_return_status => l_return_status
6104: , x_msg_count => x_msg_count
6105: , x_msg_data => x_msg_data
6106: , p_mtl_maintain_rsv_rec => l_mtl_maint_rsv_rec

Line 6117: IF l_return_status = fnd_api.g_ret_sts_error THEN

6113: mydebug ('Expected qty: '|| p_ordered_quantity, c_api_name,9);
6114: mydebug ('Modified qty: '|| l_quantity_modified, c_api_name,9);
6115: END IF;
6116:
6117: IF l_return_status = fnd_api.g_ret_sts_error THEN
6118:
6119: IF g_debug= C_Debug_Enabled THEN
6120: mydebug('Raising expected error'||l_return_status, c_api_name,9);
6121: END IF;

Line 6122: RAISE fnd_api.g_exc_error;

6118:
6119: IF g_debug= C_Debug_Enabled THEN
6120: mydebug('Raising expected error'||l_return_status, c_api_name,9);
6121: END IF;
6122: RAISE fnd_api.g_exc_error;
6123:
6124: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6125:
6126: IF g_debug= C_Debug_Enabled THEN

Line 6124: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

6120: mydebug('Raising expected error'||l_return_status, c_api_name,9);
6121: END IF;
6122: RAISE fnd_api.g_exc_error;
6123:
6124: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6125:
6126: IF g_debug= C_Debug_Enabled THEN
6127: mydebug('Rasing Unexpected error'||l_return_status, c_api_name,9);
6128: END IF;

Line 6129: RAISE fnd_api.g_exc_unexpected_error;

6125:
6126: IF g_debug= C_Debug_Enabled THEN
6127: mydebug('Rasing Unexpected error'||l_return_status, c_api_name,9);
6128: END IF;
6129: RAISE fnd_api.g_exc_unexpected_error;
6130:
6131: END IF;
6132: END IF; -- ordered qty
6133:

Line 6149: If x_return_status = fnd_api.g_ret_sts_success THEN

6145: End If;
6146:
6147: x_return_status := l_return_status;
6148:
6149: If x_return_status = fnd_api.g_ret_sts_success THEN
6150: l_Fnd_Log_message := 'Calling maintain_reservation API was successful ';
6151: -- Fnd_Log_Debug(fnd_log.Level_Error,C_Module_name, l_Fnd_Log_Message );
6152: IF G_debug= C_Debug_Enabled THEN
6153: mydebug(l_Fnd_Log_Message, c_api_name,9);

Line 6173: WHEN fnd_api.g_exc_error THEN

6169: END IF;
6170:
6171: --
6172: EXCEPTION
6173: WHEN fnd_api.g_exc_error THEN
6174: x_return_status := fnd_api.g_ret_sts_error;
6175:
6176: -- Get message count and data
6177: fnd_msg_pub.count_and_get

Line 6174: x_return_status := fnd_api.g_ret_sts_error;

6170:
6171: --
6172: EXCEPTION
6173: WHEN fnd_api.g_exc_error THEN
6174: x_return_status := fnd_api.g_ret_sts_error;
6175:
6176: -- Get message count and data
6177: fnd_msg_pub.count_and_get
6178: ( p_count => x_msg_count

Line 6215: WHEN fnd_api.g_exc_unexpected_error THEN

6211: END IF;
6212: End Loop ;
6213: End If;
6214:
6215: WHEN fnd_api.g_exc_unexpected_error THEN
6216: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6217:
6218: -- Get message count and data
6219: fnd_msg_pub.count_and_get

Line 6216: x_return_status := fnd_api.g_ret_sts_unexp_error ;

6212: End Loop ;
6213: End If;
6214:
6215: WHEN fnd_api.g_exc_unexpected_error THEN
6216: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6217:
6218: -- Get message count and data
6219: fnd_msg_pub.count_and_get
6220: ( p_count => x_msg_count

Line 6258: x_return_status := fnd_api.g_ret_sts_unexp_error ;

6254: End Loop ;
6255: End If;
6256:
6257: WHEN OTHERS THEN
6258: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6259:
6260: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
6261: THEN
6262: fnd_msg_pub.add_exc_msg