107:
108: wip_logger.entryPoint(p_procName => 'wip_infinite_scheduler_pvt.schedule',
109: p_params => l_params,
110: x_returnStatus => x_returnStatus);
111: if(x_returnStatus <> fnd_api.g_ret_sts_success) then
112: raise fnd_api.g_exc_unexpected_error;
113: end if;
114: end if;
115: x_returnStatus := fnd_api.g_ret_sts_success;
108: wip_logger.entryPoint(p_procName => 'wip_infinite_scheduler_pvt.schedule',
109: p_params => l_params,
110: x_returnStatus => x_returnStatus);
111: if(x_returnStatus <> fnd_api.g_ret_sts_success) then
112: raise fnd_api.g_exc_unexpected_error;
113: end if;
114: end if;
115: x_returnStatus := fnd_api.g_ret_sts_success;
116:
111: if(x_returnStatus <> fnd_api.g_ret_sts_success) then
112: raise fnd_api.g_exc_unexpected_error;
113: end if;
114: end if;
115: x_returnStatus := fnd_api.g_ret_sts_success;
116:
117: if(fnd_api.to_boolean(nvl(p_initMsgList, fnd_api.g_true))) then
118: fnd_msg_pub.initialize;
119: end if;
113: end if;
114: end if;
115: x_returnStatus := fnd_api.g_ret_sts_success;
116:
117: if(fnd_api.to_boolean(nvl(p_initMsgList, fnd_api.g_true))) then
118: fnd_msg_pub.initialize;
119: end if;
120:
121: if (l_logLevel <= wip_constants.full_logging) then
155: x_resTbls => l_resTbls,
156: x_assignedUnits => l_assignedUnits,
157: x_returnStatus => x_returnStatus);
158:
159: if(x_returnStatus <> fnd_api.g_ret_sts_success) then
160: raise fnd_api.g_exc_unexpected_error;
161: end if;
162: /*
163: if(p_repSchedID is not null) then
156: x_assignedUnits => l_assignedUnits,
157: x_returnStatus => x_returnStatus);
158:
159: if(x_returnStatus <> fnd_api.g_ret_sts_success) then
160: raise fnd_api.g_exc_unexpected_error;
161: end if;
162: /*
163: if(p_repSchedID is not null) then
164: select line_id
176: p_startDate => p_startDate,
177: p_endDate => p_endDate,
178: p_opSeqNum => p_opSeqNum,
179: p_resSeqNum => p_resSeqNum,
180: p_endDebug => fnd_api.g_false,
181: x_resTbls => l_resTbls,
182: x_returnStatus => x_returnStatus);
183: if(x_returnStatus <> fnd_api.g_ret_sts_success) then
184: raise fnd_api.g_exc_unexpected_error;
179: p_resSeqNum => p_resSeqNum,
180: p_endDebug => fnd_api.g_false,
181: x_resTbls => l_resTbls,
182: x_returnStatus => x_returnStatus);
183: if(x_returnStatus <> fnd_api.g_ret_sts_success) then
184: raise fnd_api.g_exc_unexpected_error;
185: end if;
186:
187: if (l_logLevel <= wip_constants.full_logging) then
180: p_endDebug => fnd_api.g_false,
181: x_resTbls => l_resTbls,
182: x_returnStatus => x_returnStatus);
183: if(x_returnStatus <> fnd_api.g_ret_sts_success) then
184: raise fnd_api.g_exc_unexpected_error;
185: end if;
186:
187: if (l_logLevel <= wip_constants.full_logging) then
188: wip_logger.log('writing job/schedule...', l_retStatus);
200: p_assignedUnits => l_assignedUnits,
201: x_resTbls => l_resTbls,
202: x_returnStatus => x_returnStatus);
203:
204: if(x_returnStatus <> fnd_api.g_ret_sts_success) then
205: raise fnd_api.g_exc_unexpected_error;
206: end if;
207:
208: if (l_logLevel <= wip_constants.trace_logging) then
201: x_resTbls => l_resTbls,
202: x_returnStatus => x_returnStatus);
203:
204: if(x_returnStatus <> fnd_api.g_ret_sts_success) then
205: raise fnd_api.g_exc_unexpected_error;
206: end if;
207:
208: if (l_logLevel <= wip_constants.trace_logging) then
209: wip_logger.exitPoint(p_procName => 'wip_infinite_scheduler_pvt.schedule',
209: wip_logger.exitPoint(p_procName => 'wip_infinite_scheduler_pvt.schedule',
210: p_procReturnStatus => x_returnStatus,
211: p_msg => 'success',
212: x_returnStatus => l_retStatus);
213: if(fnd_api.to_boolean(nvl(p_endDebug, fnd_api.g_true))) then
214: wip_logger.cleanup(l_retStatus);
215: end if;
216: end if;
217: exception
214: wip_logger.cleanup(l_retStatus);
215: end if;
216: end if;
217: exception
218: when fnd_api.g_exc_unexpected_error then
219: rollback to wipiscdb0;
220: x_returnStatus := fnd_api.g_ret_sts_unexp_error;
221: wip_utilities.get_message_stack(p_msg => x_errorMsg,
222: p_delete_stack => fnd_api.g_false);
216: end if;
217: exception
218: when fnd_api.g_exc_unexpected_error then
219: rollback to wipiscdb0;
220: x_returnStatus := fnd_api.g_ret_sts_unexp_error;
221: wip_utilities.get_message_stack(p_msg => x_errorMsg,
222: p_delete_stack => fnd_api.g_false);
223: if (l_logLevel <= wip_constants.trace_logging) then
224: wip_logger.exitPoint(p_procName => 'wip_infinite_scheduler_pvt.schedule',
218: when fnd_api.g_exc_unexpected_error then
219: rollback to wipiscdb0;
220: x_returnStatus := fnd_api.g_ret_sts_unexp_error;
221: wip_utilities.get_message_stack(p_msg => x_errorMsg,
222: p_delete_stack => fnd_api.g_false);
223: if (l_logLevel <= wip_constants.trace_logging) then
224: wip_logger.exitPoint(p_procName => 'wip_infinite_scheduler_pvt.schedule',
225: p_procReturnStatus => x_returnStatus,
226: p_msg => 'error: ' || x_errorMsg,
224: wip_logger.exitPoint(p_procName => 'wip_infinite_scheduler_pvt.schedule',
225: p_procReturnStatus => x_returnStatus,
226: p_msg => 'error: ' || x_errorMsg,
227: x_returnStatus => l_retStatus);
228: if(fnd_api.to_boolean(nvl(p_endDebug, fnd_api.g_true))) then
229: wip_logger.cleanup(l_retStatus);
230: end if;
231: end if;
232:
231: end if;
232:
233: when others then
234: rollback to wipiscdb0;
235: x_returnStatus := fnd_api.g_ret_sts_unexp_error;
236: fnd_msg_pub.add_exc_msg(p_pkg_name => 'wip_infinite_scheduler_pvt',
237: p_procedure_name => 'schedule',
238: p_error_text => SQLERRM);
239: wip_utilities.get_message_stack(p_msg => x_errorMsg,
236: fnd_msg_pub.add_exc_msg(p_pkg_name => 'wip_infinite_scheduler_pvt',
237: p_procedure_name => 'schedule',
238: p_error_text => SQLERRM);
239: wip_utilities.get_message_stack(p_msg => x_errorMsg,
240: p_delete_stack => fnd_api.g_false);
241: if (l_logLevel <= wip_constants.trace_logging) then
242: wip_logger.exitPoint(p_procName => 'wip_infinite_scheduler_pvt.schedule',
243: p_procReturnStatus => x_returnStatus,
244: p_msg => 'unexp error: ' || x_errorMsg,
242: wip_logger.exitPoint(p_procName => 'wip_infinite_scheduler_pvt.schedule',
243: p_procReturnStatus => x_returnStatus,
244: p_msg => 'unexp error: ' || x_errorMsg,
245: x_returnStatus => l_retStatus);
246: if(fnd_api.to_boolean(nvl(p_endDebug, fnd_api.g_true))) then
247: wip_logger.cleanup(l_retStatus);
248: end if;
249: end if;
250: end schedule;
556: wip_logger.entryPoint(p_procName => 'wip_infinite_scheduler_pvt.readJobSchedule',
557: p_params => l_params,
558: x_returnStatus => l_retStatus);
559: end if;
560: x_returnStatus := fnd_api.g_ret_sts_success;
561:
562: l_hrUOM := fnd_profile.value('BOM:HOUR_UOM_CODE');
563: select conversion_rate, uom_class
564: into l_hrVal, l_uomClass
707: end if;
708: exception
709: /*Fix bug 8914181 (FP 8894732)*/
710: when wip_constants.records_locked then
711: x_returnStatus := fnd_api.g_ret_sts_unexp_error;
712: if (l_logLevel <= wip_constants.trace_logging) then
713: wip_logger.exitPoint(p_procName => 'wip_infinite_scheduler_pvt.readJobSchedule',
714: p_procReturnStatus => x_returnStatus,
715: p_msg => 'records were locked',
717: end if;
718: fnd_message.set_name('WIP', 'WIP_LOCKED_ROW_ALREADY_LOCKED');
719: fnd_msg_pub.add;
720: when others then
721: x_returnStatus := fnd_api.g_ret_sts_unexp_error;
722: fnd_msg_pub.add_exc_msg(p_pkg_name => 'wip_infinite_scheduler_pvt',
723: p_procedure_name => 'readJobSchedule',
724: p_error_text => SQLERRM);
725: if (l_logLevel <= wip_constants.trace_logging) then
795: wip_logger.entryPoint(p_procName => 'wip_infinite_scheduler_pvt.writeJobSchedule',
796: p_params => l_params,
797: x_returnStatus => l_retStatus);
798: end if;
799: x_returnStatus := fnd_api.g_ret_sts_success;
800:
801: --update resources
802: forall i in 1..x_resTbls.resID.count
803: update wip_operation_resources
1185: end if;
1186: exception
1187: when others then
1188: rollback to wipiscdb100;
1189: x_returnStatus := fnd_api.g_ret_sts_unexp_error;
1190: fnd_msg_pub.add_exc_msg(p_pkg_name => 'wip_infinite_scheduler_pvt',
1191: p_procedure_name => 'writeJobSchedule',
1192: p_error_text => SQLERRM);
1193: if (l_logLevel <= wip_constants.trace_logging) then