2447: -- Min charges for distance charges is across all dist types
2448: -- It is assumed that both continuous move line and loaded dist line
2449: -- do not exist in the same call
2450:
2451: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_MIN_DISTANCE_CH
2452: AND nvl(l_qp_out_det_rec.adjustment_amount,0) >0 ) THEN
2453: fte_freight_pricing_util.print_msg(fte_freight_pricing_util.G_DBG,
2454: 'MIN_CHARGE: Minimum charge applied to distance base rates');
2455: END IF;
2456:
2457: END IF;
2458:
2459: IF (l_req_line_info_rec.line_type = G_CONT_DIST_BASE_LINE
2460: AND l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_MIN_DISTANCE_CH
2461: AND nvl(l_qp_out_det_rec.adjustment_amount,0) >0 ) THEN
2462:
2463: fte_freight_pricing_util.print_msg(fte_freight_pricing_util.G_DBG,
2464: 'MIN_CHARGE: Minimum charge applied to distance base rates (continuous move)');
2465:
2466: END IF;
2467:
2468: IF (l_req_line_info_rec.line_type = G_UNITS_BASE_LINE
2469: AND l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_MIN_UNIT_CH
2470: AND nvl(l_qp_out_det_rec.adjustment_amount,0) > 0) THEN
2471:
2472: fte_freight_pricing_util.print_msg(fte_freight_pricing_util.G_DBG,
2473: 'MIN_CHARGE: Minimum charge applied to units base rates ');
2474:
2475: END IF;
2476:
2477: IF (l_req_line_info_rec.line_type = G_TIME_BASE_LINE
2478: AND l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_MIN_TIME_CH
2479: AND nvl(l_qp_out_det_rec.adjustment_amount,0) > 0) THEN
2480:
2481: fte_freight_pricing_util.print_msg(fte_freight_pricing_util.G_DBG,
2482: 'MIN_CHARGE: Minimum charge applied to time base rates ');
2487:
2488: IF (l_req_line_info_rec.line_type = G_LOAD_CHARGE_LINE ) THEN
2489:
2490: -- dig up load (trip) level charges
2491: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_STOP_OFF_CH) THEN
2492: x_trip_charges_rec.stop_off_chrg := l_qp_out_det_rec.adjustment_amount;
2493: END IF;
2494:
2495: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_OUT_OF_ROUTE_CH) THEN
2491: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_STOP_OFF_CH) THEN
2492: x_trip_charges_rec.stop_off_chrg := l_qp_out_det_rec.adjustment_amount;
2493: END IF;
2494:
2495: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_OUT_OF_ROUTE_CH) THEN
2496: IF (l_qp_out_det_rec.adjustment_amount is not null
2497: AND l_qp_out_det_rec.line_quantity is not null) THEN
2498: -- x_trip_charges_rec.out_of_route_chrg :=
2499: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2501: x_trip_charges_rec.out_of_route_chrg := l_qp_out_det_rec.adjustment_amount;
2502: END IF;
2503: END IF;
2504:
2505: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_DOCUMENT_CH) THEN
2506: x_trip_charges_rec.document_chrg := l_qp_out_det_rec.adjustment_amount;
2507: END IF;
2508:
2509: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_HANDLING_WEIGHT_CH) THEN
2505: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_DOCUMENT_CH) THEN
2506: x_trip_charges_rec.document_chrg := l_qp_out_det_rec.adjustment_amount;
2507: END IF;
2508:
2509: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_HANDLING_WEIGHT_CH) THEN
2510: IF (l_qp_out_det_rec.adjustment_amount is not null
2511: AND l_qp_out_det_rec.line_quantity is not null) THEN
2512: -- x_trip_charges_rec.handling_chrg :=
2513: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2512: -- x_trip_charges_rec.handling_chrg :=
2513: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2514: -- bug 3474455
2515: x_trip_charges_rec.handling_chrg := l_qp_out_det_rec.adjustment_amount;
2516: x_trip_charges_rec.handling_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
2517: END IF;
2518: END IF;
2519:
2520: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_HANDLING_VOLUME_CH) THEN
2516: x_trip_charges_rec.handling_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
2517: END IF;
2518: END IF;
2519:
2520: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_HANDLING_VOLUME_CH) THEN
2521: IF (l_qp_out_det_rec.adjustment_amount is not null
2522: AND l_qp_out_det_rec.line_quantity is not null) THEN
2523: -- x_trip_charges_rec.handling_chrg :=
2524: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2523: -- x_trip_charges_rec.handling_chrg :=
2524: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2525: -- bug 3474455
2526: x_trip_charges_rec.handling_chrg := l_qp_out_det_rec.adjustment_amount;
2527: x_trip_charges_rec.handling_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
2528: END IF;
2529: END IF;
2530:
2531: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_HANDLING_FLAT_CH) THEN
2527: x_trip_charges_rec.handling_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
2528: END IF;
2529: END IF;
2530:
2531: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_HANDLING_FLAT_CH) THEN
2532: x_trip_charges_rec.handling_chrg := l_qp_out_det_rec.adjustment_amount;
2533: x_trip_charges_rec.handling_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
2534: END IF;
2535:
2529: END IF;
2530:
2531: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_HANDLING_FLAT_CH) THEN
2532: x_trip_charges_rec.handling_chrg := l_qp_out_det_rec.adjustment_amount;
2533: x_trip_charges_rec.handling_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
2534: END IF;
2535:
2536: -- TODO : Add other handling basis if we support them
2537:
2535:
2536: -- TODO : Add other handling basis if we support them
2537:
2538: IF (l_qp_out_det_rec.charge_subtype_code
2539: = fte_rtg_globals.G_C_CONTINUOUS_MOVE_DISCOUNT) THEN
2540: x_trip_charges_rec.cm_discount_percent := l_qp_out_det_rec.operand_value;
2541: END IF;
2542:
2543: -- Fuel Surcharge : bug: 3353264 (enhancement)
2540: x_trip_charges_rec.cm_discount_percent := l_qp_out_det_rec.operand_value;
2541: END IF;
2542:
2543: -- Fuel Surcharge : bug: 3353264 (enhancement)
2544: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_FUEL_CH) THEN
2545: fte_freight_pricing_util.print_msg(fte_freight_pricing_util.G_DBG,
2546: 'G_C_FUEL_CH : operand_value='||l_qp_out_det_rec.operand_value);
2547: IF (l_qp_out_det_rec.operand_value >0) THEN
2548: x_trip_charges_rec.fuel_chrg :=
2624: -- dig up stop level charges
2625:
2626: -- Look for Loading and Assisted Loading Charges --
2627:
2628: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_LOADING_WEIGHT_CH ) THEN
2629:
2630: IF (l_qp_out_det_rec.adjustment_amount is not null
2631: AND l_qp_out_det_rec.line_quantity is not null) THEN
2632: -- l_stop_rec.loading_chrg :=
2632: -- l_stop_rec.loading_chrg :=
2633: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2634: -- bug 3474455
2635: l_stop_rec.loading_chrg := l_qp_out_det_rec.adjustment_amount;
2636: l_stop_rec.loading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
2637: END IF;
2638:
2639: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_LOADING_VOLUME_CH ) THEN
2640:
2635: l_stop_rec.loading_chrg := l_qp_out_det_rec.adjustment_amount;
2636: l_stop_rec.loading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
2637: END IF;
2638:
2639: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_LOADING_VOLUME_CH ) THEN
2640:
2641: IF (l_qp_out_det_rec.adjustment_amount is not null
2642: AND l_qp_out_det_rec.line_quantity is not null) THEN
2643: --l_stop_rec.loading_chrg :=
2643: --l_stop_rec.loading_chrg :=
2644: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2645: -- bug 3474455
2646: l_stop_rec.loading_chrg := l_qp_out_det_rec.adjustment_amount;
2647: l_stop_rec.loading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
2648: END IF;
2649:
2650: ELSIF (l_qp_out_det_rec.charge_subtype_code
2651: = fte_rtg_globals.G_C_LOADING_CONTAINER_CH ) THEN
2647: l_stop_rec.loading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
2648: END IF;
2649:
2650: ELSIF (l_qp_out_det_rec.charge_subtype_code
2651: = fte_rtg_globals.G_C_LOADING_CONTAINER_CH ) THEN
2652:
2653: IF (l_qp_out_det_rec.adjustment_amount is not null
2654: AND l_qp_out_det_rec.line_quantity is not null) THEN
2655: -- l_stop_rec.loading_chrg :=
2655: -- l_stop_rec.loading_chrg :=
2656: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2657: -- bug 3474455
2658: l_stop_rec.loading_chrg := l_qp_out_det_rec.adjustment_amount;
2659: l_stop_rec.loading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
2660: END IF;
2661:
2662: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_LOADING_PALLET_CH ) THEN
2663:
2658: l_stop_rec.loading_chrg := l_qp_out_det_rec.adjustment_amount;
2659: l_stop_rec.loading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
2660: END IF;
2661:
2662: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_LOADING_PALLET_CH ) THEN
2663:
2664: IF (l_qp_out_det_rec.adjustment_amount is not null
2665: AND l_qp_out_det_rec.line_quantity is not null) THEN
2666: -- l_stop_rec.loading_chrg :=
2666: -- l_stop_rec.loading_chrg :=
2667: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2668: -- bug 3474455
2669: l_stop_rec.loading_chrg := l_qp_out_det_rec.adjustment_amount;
2670: l_stop_rec.loading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
2671: END IF;
2672:
2673: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_LOADING_FLAT_CH ) THEN
2674:
2669: l_stop_rec.loading_chrg := l_qp_out_det_rec.adjustment_amount;
2670: l_stop_rec.loading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
2671: END IF;
2672:
2673: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_LOADING_FLAT_CH ) THEN
2674:
2675: l_stop_rec.loading_chrg := l_qp_out_det_rec.adjustment_amount;
2676: l_stop_rec.loading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
2677:
2672:
2673: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_LOADING_FLAT_CH ) THEN
2674:
2675: l_stop_rec.loading_chrg := l_qp_out_det_rec.adjustment_amount;
2676: l_stop_rec.loading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
2677:
2678: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_LOADING_WEIGHT_CH ) THEN
2679:
2680: IF (l_qp_out_det_rec.adjustment_amount is not null
2674:
2675: l_stop_rec.loading_chrg := l_qp_out_det_rec.adjustment_amount;
2676: l_stop_rec.loading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
2677:
2678: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_LOADING_WEIGHT_CH ) THEN
2679:
2680: IF (l_qp_out_det_rec.adjustment_amount is not null
2681: AND l_qp_out_det_rec.line_quantity is not null) THEN
2682: -- l_stop_rec.ast_loading_chrg :=
2682: -- l_stop_rec.ast_loading_chrg :=
2683: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2684: -- bug 3474455
2685: l_stop_rec.ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2686: l_stop_rec.ast_loading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
2687: END IF;
2688:
2689: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_LOADING_VOLUME_CH ) THEN
2690:
2685: l_stop_rec.ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2686: l_stop_rec.ast_loading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
2687: END IF;
2688:
2689: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_LOADING_VOLUME_CH ) THEN
2690:
2691: IF (l_qp_out_det_rec.adjustment_amount is not null
2692: AND l_qp_out_det_rec.line_quantity is not null) THEN
2693: -- l_stop_rec.ast_loading_chrg :=
2693: -- l_stop_rec.ast_loading_chrg :=
2694: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2695: -- bug 3474455
2696: l_stop_rec.ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2697: l_stop_rec.ast_loading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
2698: END IF;
2699:
2700: ELSIF (l_qp_out_det_rec.charge_subtype_code
2701: = fte_rtg_globals.G_C_AST_LOADING_CONTAINER_CH ) THEN
2697: l_stop_rec.ast_loading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
2698: END IF;
2699:
2700: ELSIF (l_qp_out_det_rec.charge_subtype_code
2701: = fte_rtg_globals.G_C_AST_LOADING_CONTAINER_CH ) THEN
2702:
2703: IF (l_qp_out_det_rec.adjustment_amount is not null
2704: AND l_qp_out_det_rec.line_quantity is not null) THEN
2705: -- l_stop_rec.ast_loading_chrg :=
2704: AND l_qp_out_det_rec.line_quantity is not null) THEN
2705: -- l_stop_rec.ast_loading_chrg :=
2706: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2707: -- bug 3474455
2708: l_stop_rec.ast_loading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
2709: l_stop_rec.ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2710: END IF;
2711:
2712: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_LOADING_PALLET_CH ) THEN
2708: l_stop_rec.ast_loading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
2709: l_stop_rec.ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2710: END IF;
2711:
2712: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_LOADING_PALLET_CH ) THEN
2713:
2714: IF (l_qp_out_det_rec.adjustment_amount is not null
2715: AND l_qp_out_det_rec.line_quantity is not null) THEN
2716: -- l_stop_rec.ast_loading_chrg :=
2716: -- l_stop_rec.ast_loading_chrg :=
2717: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2718: -- bug 3474455
2719: l_stop_rec.ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2720: l_stop_rec.ast_loading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
2721: END IF;
2722:
2723: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_LOADING_FLAT_CH ) THEN
2724:
2719: l_stop_rec.ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2720: l_stop_rec.ast_loading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
2721: END IF;
2722:
2723: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_LOADING_FLAT_CH ) THEN
2724:
2725: l_stop_rec.ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2726: l_stop_rec.ast_loading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
2727:
2722:
2723: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_LOADING_FLAT_CH ) THEN
2724:
2725: l_stop_rec.ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2726: l_stop_rec.ast_loading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
2727:
2728: END IF; -- Loading and Assisted Loading
2729:
2730: -- Look for Unloading and Assisted Unloading Charges
2727:
2728: END IF; -- Loading and Assisted Loading
2729:
2730: -- Look for Unloading and Assisted Unloading Charges
2731: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_UNLOADING_WEIGHT_CH ) THEN
2732:
2733: IF (l_qp_out_det_rec.adjustment_amount is not null
2734: AND l_qp_out_det_rec.line_quantity is not null) THEN
2735: -- l_stop_rec.unloading_chrg :=
2735: -- l_stop_rec.unloading_chrg :=
2736: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2737: -- bug 3474455
2738: l_stop_rec.unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2739: l_stop_rec.unloading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
2740: END IF;
2741:
2742: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_UNLOADING_VOLUME_CH ) THEN
2743:
2738: l_stop_rec.unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2739: l_stop_rec.unloading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
2740: END IF;
2741:
2742: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_UNLOADING_VOLUME_CH ) THEN
2743:
2744: IF (l_qp_out_det_rec.adjustment_amount is not null
2745: AND l_qp_out_det_rec.line_quantity is not null) THEN
2746: -- l_stop_rec.unloading_chrg :=
2746: -- l_stop_rec.unloading_chrg :=
2747: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2748: -- bug 3474455
2749: l_stop_rec.unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2750: l_stop_rec.unloading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
2751: END IF;
2752:
2753: ELSIF (l_qp_out_det_rec.charge_subtype_code
2754: = fte_rtg_globals.G_C_UNLOADING_CONTAINER_CH ) THEN
2750: l_stop_rec.unloading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
2751: END IF;
2752:
2753: ELSIF (l_qp_out_det_rec.charge_subtype_code
2754: = fte_rtg_globals.G_C_UNLOADING_CONTAINER_CH ) THEN
2755:
2756: IF (l_qp_out_det_rec.adjustment_amount is not null
2757: AND l_qp_out_det_rec.line_quantity is not null) THEN
2758: -- l_stop_rec.unloading_chrg :=
2758: -- l_stop_rec.unloading_chrg :=
2759: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2760: -- bug 3474455
2761: l_stop_rec.unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2762: l_stop_rec.unloading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
2763: END IF;
2764:
2765: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_UNLOADING_PALLET_CH ) THEN
2766:
2761: l_stop_rec.unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2762: l_stop_rec.unloading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
2763: END IF;
2764:
2765: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_UNLOADING_PALLET_CH ) THEN
2766:
2767: IF (l_qp_out_det_rec.adjustment_amount is not null
2768: AND l_qp_out_det_rec.line_quantity is not null) THEN
2769: -- l_stop_rec.unloading_chrg :=
2769: -- l_stop_rec.unloading_chrg :=
2770: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2771: -- bug 3474455
2772: l_stop_rec.unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2773: l_stop_rec.unloading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
2774: END IF;
2775:
2776: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_UNLOADING_FLAT_CH ) THEN
2777:
2772: l_stop_rec.unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2773: l_stop_rec.unloading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
2774: END IF;
2775:
2776: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_UNLOADING_FLAT_CH ) THEN
2777:
2778: l_stop_rec.unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2779: l_stop_rec.unloading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
2780:
2775:
2776: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_UNLOADING_FLAT_CH ) THEN
2777:
2778: l_stop_rec.unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2779: l_stop_rec.unloading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
2780:
2781: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_UNLOADING_WEIGHT_CH ) THEN
2782:
2783: IF (l_qp_out_det_rec.adjustment_amount is not null
2777:
2778: l_stop_rec.unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2779: l_stop_rec.unloading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
2780:
2781: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_UNLOADING_WEIGHT_CH ) THEN
2782:
2783: IF (l_qp_out_det_rec.adjustment_amount is not null
2784: AND l_qp_out_det_rec.line_quantity is not null) THEN
2785: -- l_stop_rec.ast_unloading_chrg :=
2785: -- l_stop_rec.ast_unloading_chrg :=
2786: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2787: -- bug 3474455
2788: l_stop_rec.ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2789: l_stop_rec.ast_unloading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
2790: END IF;
2791:
2792: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_UNLOADING_VOLUME_CH ) THEN
2793:
2788: l_stop_rec.ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2789: l_stop_rec.ast_unloading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
2790: END IF;
2791:
2792: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_UNLOADING_VOLUME_CH ) THEN
2793:
2794: IF (l_qp_out_det_rec.adjustment_amount is not null
2795: AND l_qp_out_det_rec.line_quantity is not null) THEN
2796: -- l_stop_rec.ast_unloading_chrg :=
2796: -- l_stop_rec.ast_unloading_chrg :=
2797: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2798: -- bug 3474455
2799: l_stop_rec.ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2800: l_stop_rec.ast_unloading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
2801: END IF;
2802:
2803: ELSIF (l_qp_out_det_rec.charge_subtype_code
2804: = fte_rtg_globals.G_C_AST_UNLOADING_CONTAINER_CH ) THEN
2800: l_stop_rec.ast_unloading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
2801: END IF;
2802:
2803: ELSIF (l_qp_out_det_rec.charge_subtype_code
2804: = fte_rtg_globals.G_C_AST_UNLOADING_CONTAINER_CH ) THEN
2805:
2806: IF (l_qp_out_det_rec.adjustment_amount is not null
2807: AND l_qp_out_det_rec.line_quantity is not null) THEN
2808: -- l_stop_rec.ast_unloading_chrg :=
2808: -- l_stop_rec.ast_unloading_chrg :=
2809: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2810: -- bug 3474455
2811: l_stop_rec.ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2812: l_stop_rec.ast_unloading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
2813: END IF;
2814:
2815: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_UNLOADING_PALLET_CH ) THEN
2816:
2811: l_stop_rec.ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2812: l_stop_rec.ast_unloading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
2813: END IF;
2814:
2815: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_UNLOADING_PALLET_CH ) THEN
2816:
2817: IF (l_qp_out_det_rec.adjustment_amount is not null
2818: AND l_qp_out_det_rec.line_quantity is not null) THEN
2819: -- l_stop_rec.ast_unloading_chrg :=
2819: -- l_stop_rec.ast_unloading_chrg :=
2820: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2821: -- bug 3474455
2822: l_stop_rec.ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2823: l_stop_rec.ast_unloading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
2824: END IF;
2825:
2826: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_UNLOADING_FLAT_CH ) THEN
2827:
2822: l_stop_rec.ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2823: l_stop_rec.ast_unloading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
2824: END IF;
2825:
2826: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_UNLOADING_FLAT_CH ) THEN
2827:
2828: l_stop_rec.ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2829: l_stop_rec.ast_unloading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
2830:
2825:
2826: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_UNLOADING_FLAT_CH ) THEN
2827:
2828: l_stop_rec.ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2829: l_stop_rec.ast_unloading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
2830:
2831: END IF; -- Unloading and Assisted Unloading
2832:
2833:
2832:
2833:
2834: -- Look for Origin and Destination Surcharges --
2835:
2836: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_ORIGIN_SURCHRG ) THEN
2837:
2838: l_stop_rec.origin_surchrg := l_qp_out_det_rec.adjustment_amount;
2839:
2840: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_DESTINATION_SURCHRG ) THEN
2836: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_ORIGIN_SURCHRG ) THEN
2837:
2838: l_stop_rec.origin_surchrg := l_qp_out_det_rec.adjustment_amount;
2839:
2840: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_DESTINATION_SURCHRG ) THEN
2841:
2842: l_stop_rec.destination_surchrg := l_qp_out_det_rec.adjustment_amount;
2843:
2844: END IF;
2844: END IF;
2845:
2846: -- Look for Weekday and Weekend Layover Charges
2847:
2848: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_WEEKDAY_LAYOVER_CH ) THEN
2849:
2850: fte_freight_pricing_util.print_msg(fte_freight_pricing_util.G_DBG,
2851: 'G_C_WEEKDAY_LAYOVER_CH : adjustment_amount='||l_qp_out_det_rec.adjustment_amount);
2852: IF (l_qp_out_det_rec.adjustment_amount is not null
2856: -- bug 3474455
2857: l_stop_rec.weekday_layover_chrg := l_qp_out_det_rec.adjustment_amount;
2858: END IF;
2859:
2860: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_WEEKEND_LAYOVER_CH ) THEN
2861:
2862: fte_freight_pricing_util.print_msg(fte_freight_pricing_util.G_DBG,
2863: 'G_C_WEEKEND_LAYOVER_CH : adjustment_amount='||l_qp_out_det_rec.adjustment_amount);
2864:
2884: -- dig up facility level charges
2885:
2886: -- Look for Facility Loading and Assisted Loading Charges --
2887:
2888: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_LOADING_WEIGHT_CH ) THEN
2889:
2890: -- l_stop_rec.fac_loading_chrg
2891: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2892: -- bug 3474455
2890: -- l_stop_rec.fac_loading_chrg
2891: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2892: -- bug 3474455
2893: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2894: l_stop_rec.fac_loading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
2895:
2896: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_LOADING_VOLUME_CH ) THEN
2897:
2898: -- l_stop_rec.fac_loading_chrg
2892: -- bug 3474455
2893: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2894: l_stop_rec.fac_loading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
2895:
2896: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_LOADING_VOLUME_CH ) THEN
2897:
2898: -- l_stop_rec.fac_loading_chrg
2899: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2900: -- bug 3474455
2898: -- l_stop_rec.fac_loading_chrg
2899: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2900: -- bug 3474455
2901: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2902: l_stop_rec.fac_loading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
2903:
2904: ELSIF (l_qp_out_det_rec.charge_subtype_code
2905: = fte_rtg_globals.G_F_LOADING_CONTAINER_CH ) THEN
2906:
2901: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2902: l_stop_rec.fac_loading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
2903:
2904: ELSIF (l_qp_out_det_rec.charge_subtype_code
2905: = fte_rtg_globals.G_F_LOADING_CONTAINER_CH ) THEN
2906:
2907: -- l_stop_rec.fac_loading_chrg
2908: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2909: -- bug 3474455
2907: -- l_stop_rec.fac_loading_chrg
2908: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2909: -- bug 3474455
2910: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2911: l_stop_rec.fac_loading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
2912:
2913: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_LOADING_PALLET_CH ) THEN
2914:
2915: -- l_stop_rec.fac_loading_chrg
2909: -- bug 3474455
2910: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2911: l_stop_rec.fac_loading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
2912:
2913: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_LOADING_PALLET_CH ) THEN
2914:
2915: -- l_stop_rec.fac_loading_chrg
2916: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2917: -- bug 3474455
2915: -- l_stop_rec.fac_loading_chrg
2916: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2917: -- bug 3474455
2918: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2919: l_stop_rec.fac_loading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
2920:
2921: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_LOADING_FLAT_CH ) THEN
2922:
2923: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2917: -- bug 3474455
2918: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2919: l_stop_rec.fac_loading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
2920:
2921: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_LOADING_FLAT_CH ) THEN
2922:
2923: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2924: l_stop_rec.fac_loading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
2925:
2920:
2921: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_LOADING_FLAT_CH ) THEN
2922:
2923: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2924: l_stop_rec.fac_loading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
2925:
2926: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_LOADING_WEIGHT_CH ) THEN
2927:
2928: -- l_stop_rec.fac_ast_loading_chrg
2922:
2923: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2924: l_stop_rec.fac_loading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
2925:
2926: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_LOADING_WEIGHT_CH ) THEN
2927:
2928: -- l_stop_rec.fac_ast_loading_chrg
2929: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2930: -- bug 3474455
2928: -- l_stop_rec.fac_ast_loading_chrg
2929: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2930: -- bug 3474455
2931: l_stop_rec.fac_ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2932: l_stop_rec.fac_ast_loading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
2933:
2934: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_LOADING_VOLUME_CH ) THEN
2935:
2936: -- l_stop_rec.fac_ast_loading_chrg
2930: -- bug 3474455
2931: l_stop_rec.fac_ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2932: l_stop_rec.fac_ast_loading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
2933:
2934: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_LOADING_VOLUME_CH ) THEN
2935:
2936: -- l_stop_rec.fac_ast_loading_chrg
2937: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2938: -- bug 3474455
2936: -- l_stop_rec.fac_ast_loading_chrg
2937: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2938: -- bug 3474455
2939: l_stop_rec.fac_ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2940: l_stop_rec.fac_ast_loading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
2941:
2942: ELSIF (l_qp_out_det_rec.charge_subtype_code
2943: = fte_rtg_globals.G_F_AST_LOADING_CONTAINER_CH ) THEN
2944:
2939: l_stop_rec.fac_ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2940: l_stop_rec.fac_ast_loading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
2941:
2942: ELSIF (l_qp_out_det_rec.charge_subtype_code
2943: = fte_rtg_globals.G_F_AST_LOADING_CONTAINER_CH ) THEN
2944:
2945: -- l_stop_rec.fac_ast_loading_chrg
2946: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2947: -- bug 3474455
2945: -- l_stop_rec.fac_ast_loading_chrg
2946: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2947: -- bug 3474455
2948: l_stop_rec.fac_ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2949: l_stop_rec.fac_ast_loading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
2950:
2951: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_LOADING_PALLET_CH ) THEN
2952:
2953: l_stop_rec.fac_ast_loading_chrg
2947: -- bug 3474455
2948: l_stop_rec.fac_ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2949: l_stop_rec.fac_ast_loading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
2950:
2951: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_LOADING_PALLET_CH ) THEN
2952:
2953: l_stop_rec.fac_ast_loading_chrg
2954: := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2955: -- bug 3474455
2953: l_stop_rec.fac_ast_loading_chrg
2954: := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2955: -- bug 3474455
2956: l_stop_rec.fac_ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2957: l_stop_rec.fac_ast_loading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
2958:
2959: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_LOADING_FLAT_CH ) THEN
2960:
2961: l_stop_rec.fac_ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2955: -- bug 3474455
2956: l_stop_rec.fac_ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2957: l_stop_rec.fac_ast_loading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
2958:
2959: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_LOADING_FLAT_CH ) THEN
2960:
2961: l_stop_rec.fac_ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2962: l_stop_rec.fac_ast_loading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
2963:
2958:
2959: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_LOADING_FLAT_CH ) THEN
2960:
2961: l_stop_rec.fac_ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
2962: l_stop_rec.fac_ast_loading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
2963:
2964: END IF; -- Facility Loading and Assisted Loading
2965:
2966: -- Look for Facility Unloading and Assisted Unloading Charges
2963:
2964: END IF; -- Facility Loading and Assisted Loading
2965:
2966: -- Look for Facility Unloading and Assisted Unloading Charges
2967: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_UNLOADING_WEIGHT_CH ) THEN
2968:
2969: -- l_stop_rec.fac_unloading_chrg
2970: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2971: -- bug 3474455
2969: -- l_stop_rec.fac_unloading_chrg
2970: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2971: -- bug 3474455
2972: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2973: l_stop_rec.fac_unloading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
2974:
2975: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_UNLOADING_VOLUME_CH ) THEN
2976:
2977: -- l_stop_rec.fac_unloading_chrg
2971: -- bug 3474455
2972: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2973: l_stop_rec.fac_unloading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
2974:
2975: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_UNLOADING_VOLUME_CH ) THEN
2976:
2977: -- l_stop_rec.fac_unloading_chrg
2978: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2979: -- bug 3474455
2977: -- l_stop_rec.fac_unloading_chrg
2978: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2979: -- bug 3474455
2980: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2981: l_stop_rec.fac_unloading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
2982:
2983: ELSIF (l_qp_out_det_rec.charge_subtype_code
2984: = fte_rtg_globals.G_F_UNLOADING_CONTAINER_CH ) THEN
2985:
2980: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2981: l_stop_rec.fac_unloading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
2982:
2983: ELSIF (l_qp_out_det_rec.charge_subtype_code
2984: = fte_rtg_globals.G_F_UNLOADING_CONTAINER_CH ) THEN
2985:
2986: -- l_stop_rec.fac_unloading_chrg
2987: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2988: -- bug 3474455
2986: -- l_stop_rec.fac_unloading_chrg
2987: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2988: -- bug 3474455
2989: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2990: l_stop_rec.fac_unloading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
2991:
2992: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_UNLOADING_PALLET_CH ) THEN
2993:
2994: -- l_stop_rec.fac_unloading_chrg
2988: -- bug 3474455
2989: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2990: l_stop_rec.fac_unloading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
2991:
2992: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_UNLOADING_PALLET_CH ) THEN
2993:
2994: -- l_stop_rec.fac_unloading_chrg
2995: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2996: -- bug 3474455
2994: -- l_stop_rec.fac_unloading_chrg
2995: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
2996: -- bug 3474455
2997: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2998: l_stop_rec.fac_unloading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
2999:
3000: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_UNLOADING_FLAT_CH ) THEN
3001:
3002: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2996: -- bug 3474455
2997: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
2998: l_stop_rec.fac_unloading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
2999:
3000: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_UNLOADING_FLAT_CH ) THEN
3001:
3002: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
3003: l_stop_rec.fac_unloading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
3004:
2999:
3000: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_UNLOADING_FLAT_CH ) THEN
3001:
3002: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
3003: l_stop_rec.fac_unloading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
3004:
3005: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_UNLOADING_WEIGHT_CH ) THEN
3006:
3007: -- l_stop_rec.fac_ast_unloading_chrg
3001:
3002: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
3003: l_stop_rec.fac_unloading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
3004:
3005: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_UNLOADING_WEIGHT_CH ) THEN
3006:
3007: -- l_stop_rec.fac_ast_unloading_chrg
3008: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
3009: -- bug 3474455
3007: -- l_stop_rec.fac_ast_unloading_chrg
3008: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
3009: -- bug 3474455
3010: l_stop_rec.fac_ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
3011: l_stop_rec.fac_ast_unloading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
3012:
3013: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_UNLOADING_VOLUME_CH ) THEN
3014:
3015: -- l_stop_rec.fac_ast_unloading_chrg
3009: -- bug 3474455
3010: l_stop_rec.fac_ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
3011: l_stop_rec.fac_ast_unloading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
3012:
3013: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_UNLOADING_VOLUME_CH ) THEN
3014:
3015: -- l_stop_rec.fac_ast_unloading_chrg
3016: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
3017: -- bug 3474455
3015: -- l_stop_rec.fac_ast_unloading_chrg
3016: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
3017: -- bug 3474455
3018: l_stop_rec.fac_ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
3019: l_stop_rec.fac_ast_unloading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
3020:
3021: ELSIF (l_qp_out_det_rec.charge_subtype_code
3022: = fte_rtg_globals.G_F_AST_UNLOADING_CONTAINER_CH ) THEN
3023:
3018: l_stop_rec.fac_ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
3019: l_stop_rec.fac_ast_unloading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
3020:
3021: ELSIF (l_qp_out_det_rec.charge_subtype_code
3022: = fte_rtg_globals.G_F_AST_UNLOADING_CONTAINER_CH ) THEN
3023:
3024: -- l_stop_rec.fac_ast_unloading_chrg
3025: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
3026: -- bug 3474455
3024: -- l_stop_rec.fac_ast_unloading_chrg
3025: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
3026: -- bug 3474455
3027: l_stop_rec.fac_ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
3028: l_stop_rec.fac_ast_unloading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
3029:
3030: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_UNLOADING_PALLET_CH ) THEN
3031:
3032: -- l_stop_rec.fac_ast_unloading_chrg
3026: -- bug 3474455
3027: l_stop_rec.fac_ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
3028: l_stop_rec.fac_ast_unloading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
3029:
3030: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_UNLOADING_PALLET_CH ) THEN
3031:
3032: -- l_stop_rec.fac_ast_unloading_chrg
3033: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
3034: -- bug 3474455
3032: -- l_stop_rec.fac_ast_unloading_chrg
3033: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
3034: -- bug 3474455
3035: l_stop_rec.fac_ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
3036: l_stop_rec.fac_ast_unloading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
3037:
3038: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_UNLOADING_FLAT_CH ) THEN
3039:
3040: l_stop_rec.fac_ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
3034: -- bug 3474455
3035: l_stop_rec.fac_ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
3036: l_stop_rec.fac_ast_unloading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
3037:
3038: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_UNLOADING_FLAT_CH ) THEN
3039:
3040: l_stop_rec.fac_ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
3041: l_stop_rec.fac_ast_unloading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
3042:
3037:
3038: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_UNLOADING_FLAT_CH ) THEN
3039:
3040: l_stop_rec.fac_ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
3041: l_stop_rec.fac_ast_unloading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
3042:
3043: END IF; -- Facility Unloading and Assisted Unloading
3044:
3045: -- Look for Facility Handling Charges --
3043: END IF; -- Facility Unloading and Assisted Unloading
3044:
3045: -- Look for Facility Handling Charges --
3046:
3047: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_HANDLING_WEIGHT_CH ) THEN
3048:
3049: -- l_stop_rec.fac_handling_chrg
3050: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
3051: -- bug 3474455
3049: -- l_stop_rec.fac_handling_chrg
3050: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
3051: -- bug 3474455
3052: l_stop_rec.fac_handling_chrg := l_qp_out_det_rec.adjustment_amount;
3053: l_stop_rec.fac_handling_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
3054:
3055: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_HANDLING_VOLUME_CH ) THEN
3056:
3057: -- l_stop_rec.fac_handling_chrg
3051: -- bug 3474455
3052: l_stop_rec.fac_handling_chrg := l_qp_out_det_rec.adjustment_amount;
3053: l_stop_rec.fac_handling_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
3054:
3055: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_HANDLING_VOLUME_CH ) THEN
3056:
3057: -- l_stop_rec.fac_handling_chrg
3058: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
3059: -- bug 3474455
3057: -- l_stop_rec.fac_handling_chrg
3058: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
3059: -- bug 3474455
3060: l_stop_rec.fac_handling_chrg := l_qp_out_det_rec.adjustment_amount;
3061: l_stop_rec.fac_handling_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
3062:
3063: ELSIF (l_qp_out_det_rec.charge_subtype_code
3064: = fte_rtg_globals.G_F_HANDLING_CONTAINER_CH ) THEN
3065:
3060: l_stop_rec.fac_handling_chrg := l_qp_out_det_rec.adjustment_amount;
3061: l_stop_rec.fac_handling_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
3062:
3063: ELSIF (l_qp_out_det_rec.charge_subtype_code
3064: = fte_rtg_globals.G_F_HANDLING_CONTAINER_CH ) THEN
3065:
3066: -- l_stop_rec.fac_handling_chrg
3067: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
3068: -- bug 3474455
3066: -- l_stop_rec.fac_handling_chrg
3067: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
3068: -- bug 3474455
3069: l_stop_rec.fac_handling_chrg := l_qp_out_det_rec.adjustment_amount;
3070: l_stop_rec.fac_handling_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
3071:
3072: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_HANDLING_PALLET_CH ) THEN
3073:
3074: -- l_stop_rec.fac_handling_chrg
3068: -- bug 3474455
3069: l_stop_rec.fac_handling_chrg := l_qp_out_det_rec.adjustment_amount;
3070: l_stop_rec.fac_handling_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
3071:
3072: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_HANDLING_PALLET_CH ) THEN
3073:
3074: -- l_stop_rec.fac_handling_chrg
3075: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
3076: -- bug 3474455
3074: -- l_stop_rec.fac_handling_chrg
3075: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
3076: -- bug 3474455
3077: l_stop_rec.fac_handling_chrg := l_qp_out_det_rec.adjustment_amount;
3078: l_stop_rec.fac_handling_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
3079:
3080: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_HANDLING_FLAT_CH ) THEN
3081:
3082: l_stop_rec.fac_handling_chrg := l_qp_out_det_rec.adjustment_amount;
3076: -- bug 3474455
3077: l_stop_rec.fac_handling_chrg := l_qp_out_det_rec.adjustment_amount;
3078: l_stop_rec.fac_handling_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
3079:
3080: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_HANDLING_FLAT_CH ) THEN
3081:
3082: l_stop_rec.fac_handling_chrg := l_qp_out_det_rec.adjustment_amount;
3083: l_stop_rec.fac_handling_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
3084:
3079:
3080: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_HANDLING_FLAT_CH ) THEN
3081:
3082: l_stop_rec.fac_handling_chrg := l_qp_out_det_rec.adjustment_amount;
3083: l_stop_rec.fac_handling_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
3084:
3085: END IF; -- facility handling charges
3086:
3087: -----------------------------------------------------------------
3807: -- Min charges for distance charges is across all dist types
3808: -- It is assumed that both continuous move line and loaded dist line
3809: -- do not exist in the same call
3810:
3811: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_MIN_DISTANCE_CH
3812: AND nvl(l_qp_out_det_rec.adjustment_amount,0) >0 ) THEN
3813: fte_freight_pricing_util.print_msg(fte_freight_pricing_util.G_DBG,
3814: 'MIN_CHARGE: Minimum charge applied to distance base rates');
3815: END IF;
3816:
3817: END IF;
3818:
3819: IF (l_req_line_info_rec.line_type = G_CONT_DIST_BASE_LINE
3820: AND l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_MIN_DISTANCE_CH
3821: AND nvl(l_qp_out_det_rec.adjustment_amount,0) >0 ) THEN
3822:
3823: fte_freight_pricing_util.print_msg(fte_freight_pricing_util.G_DBG,
3824: 'MIN_CHARGE: Minimum charge applied to distance base rates (continuous move)');
3825:
3826: END IF;
3827:
3828: IF (l_req_line_info_rec.line_type = G_UNITS_BASE_LINE
3829: AND l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_MIN_UNIT_CH
3830: AND nvl(l_qp_out_det_rec.adjustment_amount,0) > 0) THEN
3831:
3832: fte_freight_pricing_util.print_msg(fte_freight_pricing_util.G_DBG,
3833: 'MIN_CHARGE: Minimum charge applied to units base rates ');
3834:
3835: END IF;
3836:
3837: IF (l_req_line_info_rec.line_type = G_TIME_BASE_LINE
3838: AND l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_MIN_TIME_CH
3839: AND nvl(l_qp_out_det_rec.adjustment_amount,0) > 0) THEN
3840:
3841: fte_freight_pricing_util.print_msg(fte_freight_pricing_util.G_DBG,
3842: 'MIN_CHARGE: Minimum charge applied to time base rates ');
3847:
3848: IF (l_req_line_info_rec.line_type = G_LOAD_CHARGE_LINE ) THEN
3849:
3850: -- dig up load (trip) level charges
3851: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_STOP_OFF_CH) THEN
3852: x_trip_charges_tab(l_trip_index).stop_off_chrg := l_qp_out_det_rec.adjustment_amount;
3853: END IF;
3854:
3855: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_OUT_OF_ROUTE_CH) THEN
3851: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_STOP_OFF_CH) THEN
3852: x_trip_charges_tab(l_trip_index).stop_off_chrg := l_qp_out_det_rec.adjustment_amount;
3853: END IF;
3854:
3855: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_OUT_OF_ROUTE_CH) THEN
3856: IF (l_qp_out_det_rec.adjustment_amount is not null
3857: AND l_qp_out_det_rec.line_quantity is not null) THEN
3858: -- x_trip_charges_rec.out_of_route_chrg :=
3859: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
3861: x_trip_charges_tab(l_trip_index).out_of_route_chrg := l_qp_out_det_rec.adjustment_amount;
3862: END IF;
3863: END IF;
3864:
3865: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_DOCUMENT_CH) THEN
3866: x_trip_charges_tab(l_trip_index).document_chrg := l_qp_out_det_rec.adjustment_amount;
3867: END IF;
3868:
3869: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_HANDLING_WEIGHT_CH) THEN
3865: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_DOCUMENT_CH) THEN
3866: x_trip_charges_tab(l_trip_index).document_chrg := l_qp_out_det_rec.adjustment_amount;
3867: END IF;
3868:
3869: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_HANDLING_WEIGHT_CH) THEN
3870: IF (l_qp_out_det_rec.adjustment_amount is not null
3871: AND l_qp_out_det_rec.line_quantity is not null) THEN
3872: -- x_trip_charges_rec.handling_chrg :=
3873: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
3872: -- x_trip_charges_rec.handling_chrg :=
3873: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
3874: -- bug 3474455
3875: x_trip_charges_tab(l_trip_index).handling_chrg := l_qp_out_det_rec.adjustment_amount;
3876: x_trip_charges_tab(l_trip_index).handling_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
3877: END IF;
3878: END IF;
3879:
3880: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_HANDLING_VOLUME_CH) THEN
3876: x_trip_charges_tab(l_trip_index).handling_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
3877: END IF;
3878: END IF;
3879:
3880: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_HANDLING_VOLUME_CH) THEN
3881: IF (l_qp_out_det_rec.adjustment_amount is not null
3882: AND l_qp_out_det_rec.line_quantity is not null) THEN
3883: -- x_trip_charges_rec.handling_chrg :=
3884: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
3883: -- x_trip_charges_rec.handling_chrg :=
3884: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
3885: -- bug 3474455
3886: x_trip_charges_tab(l_trip_index).handling_chrg := l_qp_out_det_rec.adjustment_amount;
3887: x_trip_charges_tab(l_trip_index).handling_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
3888: END IF;
3889: END IF;
3890:
3891: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_HANDLING_FLAT_CH) THEN
3887: x_trip_charges_tab(l_trip_index).handling_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
3888: END IF;
3889: END IF;
3890:
3891: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_HANDLING_FLAT_CH) THEN
3892: x_trip_charges_tab(l_trip_index).handling_chrg := l_qp_out_det_rec.adjustment_amount;
3893: x_trip_charges_tab(l_trip_index).handling_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
3894: END IF;
3895:
3889: END IF;
3890:
3891: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_HANDLING_FLAT_CH) THEN
3892: x_trip_charges_tab(l_trip_index).handling_chrg := l_qp_out_det_rec.adjustment_amount;
3893: x_trip_charges_tab(l_trip_index).handling_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
3894: END IF;
3895:
3896: -- TODO : Add other handling basis if we support them
3897:
3895:
3896: -- TODO : Add other handling basis if we support them
3897:
3898: IF (l_qp_out_det_rec.charge_subtype_code
3899: = fte_rtg_globals.G_C_CONTINUOUS_MOVE_DISCOUNT) THEN
3900: x_trip_charges_tab(l_trip_index).cm_discount_percent := l_qp_out_det_rec.operand_value;
3901: END IF;
3902:
3903: -- Fuel Surcharge : bug: 3353264 (enhancement)
3900: x_trip_charges_tab(l_trip_index).cm_discount_percent := l_qp_out_det_rec.operand_value;
3901: END IF;
3902:
3903: -- Fuel Surcharge : bug: 3353264 (enhancement)
3904: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_FUEL_CH) THEN
3905: fte_freight_pricing_util.print_msg(fte_freight_pricing_util.G_DBG,
3906: 'G_C_FUEL_CH : operand_value='||l_qp_out_det_rec.operand_value);
3907: IF (l_qp_out_det_rec.operand_value >0) THEN
3908: x_trip_charges_tab(l_trip_index).fuel_chrg :=
3983: -- dig up stop level charges
3984:
3985: -- Look for Loading and Assisted Loading Charges --
3986:
3987: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_LOADING_WEIGHT_CH ) THEN
3988:
3989: IF (l_qp_out_det_rec.adjustment_amount is not null
3990: AND l_qp_out_det_rec.line_quantity is not null) THEN
3991: -- l_stop_rec.loading_chrg :=
3991: -- l_stop_rec.loading_chrg :=
3992: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
3993: -- bug 3474455
3994: l_stop_rec.loading_chrg := l_qp_out_det_rec.adjustment_amount;
3995: l_stop_rec.loading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
3996: END IF;
3997:
3998: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_LOADING_VOLUME_CH ) THEN
3999:
3994: l_stop_rec.loading_chrg := l_qp_out_det_rec.adjustment_amount;
3995: l_stop_rec.loading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
3996: END IF;
3997:
3998: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_LOADING_VOLUME_CH ) THEN
3999:
4000: IF (l_qp_out_det_rec.adjustment_amount is not null
4001: AND l_qp_out_det_rec.line_quantity is not null) THEN
4002: --l_stop_rec.loading_chrg :=
4002: --l_stop_rec.loading_chrg :=
4003: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4004: -- bug 3474455
4005: l_stop_rec.loading_chrg := l_qp_out_det_rec.adjustment_amount;
4006: l_stop_rec.loading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
4007: END IF;
4008:
4009: ELSIF (l_qp_out_det_rec.charge_subtype_code
4010: = fte_rtg_globals.G_C_LOADING_CONTAINER_CH ) THEN
4006: l_stop_rec.loading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
4007: END IF;
4008:
4009: ELSIF (l_qp_out_det_rec.charge_subtype_code
4010: = fte_rtg_globals.G_C_LOADING_CONTAINER_CH ) THEN
4011:
4012: IF (l_qp_out_det_rec.adjustment_amount is not null
4013: AND l_qp_out_det_rec.line_quantity is not null) THEN
4014: -- l_stop_rec.loading_chrg :=
4014: -- l_stop_rec.loading_chrg :=
4015: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4016: -- bug 3474455
4017: l_stop_rec.loading_chrg := l_qp_out_det_rec.adjustment_amount;
4018: l_stop_rec.loading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
4019: END IF;
4020:
4021: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_LOADING_PALLET_CH ) THEN
4022:
4017: l_stop_rec.loading_chrg := l_qp_out_det_rec.adjustment_amount;
4018: l_stop_rec.loading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
4019: END IF;
4020:
4021: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_LOADING_PALLET_CH ) THEN
4022:
4023: IF (l_qp_out_det_rec.adjustment_amount is not null
4024: AND l_qp_out_det_rec.line_quantity is not null) THEN
4025: -- l_stop_rec.loading_chrg :=
4025: -- l_stop_rec.loading_chrg :=
4026: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4027: -- bug 3474455
4028: l_stop_rec.loading_chrg := l_qp_out_det_rec.adjustment_amount;
4029: l_stop_rec.loading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
4030: END IF;
4031:
4032: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_LOADING_FLAT_CH ) THEN
4033:
4028: l_stop_rec.loading_chrg := l_qp_out_det_rec.adjustment_amount;
4029: l_stop_rec.loading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
4030: END IF;
4031:
4032: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_LOADING_FLAT_CH ) THEN
4033:
4034: l_stop_rec.loading_chrg := l_qp_out_det_rec.adjustment_amount;
4035: l_stop_rec.loading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
4036:
4031:
4032: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_LOADING_FLAT_CH ) THEN
4033:
4034: l_stop_rec.loading_chrg := l_qp_out_det_rec.adjustment_amount;
4035: l_stop_rec.loading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
4036:
4037: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_LOADING_WEIGHT_CH ) THEN
4038:
4039: IF (l_qp_out_det_rec.adjustment_amount is not null
4033:
4034: l_stop_rec.loading_chrg := l_qp_out_det_rec.adjustment_amount;
4035: l_stop_rec.loading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
4036:
4037: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_LOADING_WEIGHT_CH ) THEN
4038:
4039: IF (l_qp_out_det_rec.adjustment_amount is not null
4040: AND l_qp_out_det_rec.line_quantity is not null) THEN
4041: -- l_stop_rec.ast_loading_chrg :=
4041: -- l_stop_rec.ast_loading_chrg :=
4042: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4043: -- bug 3474455
4044: l_stop_rec.ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4045: l_stop_rec.ast_loading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
4046: END IF;
4047:
4048: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_LOADING_VOLUME_CH ) THEN
4049:
4044: l_stop_rec.ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4045: l_stop_rec.ast_loading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
4046: END IF;
4047:
4048: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_LOADING_VOLUME_CH ) THEN
4049:
4050: IF (l_qp_out_det_rec.adjustment_amount is not null
4051: AND l_qp_out_det_rec.line_quantity is not null) THEN
4052: -- l_stop_rec.ast_loading_chrg :=
4052: -- l_stop_rec.ast_loading_chrg :=
4053: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4054: -- bug 3474455
4055: l_stop_rec.ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4056: l_stop_rec.ast_loading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
4057: END IF;
4058:
4059: ELSIF (l_qp_out_det_rec.charge_subtype_code
4060: = fte_rtg_globals.G_C_AST_LOADING_CONTAINER_CH ) THEN
4056: l_stop_rec.ast_loading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
4057: END IF;
4058:
4059: ELSIF (l_qp_out_det_rec.charge_subtype_code
4060: = fte_rtg_globals.G_C_AST_LOADING_CONTAINER_CH ) THEN
4061:
4062: IF (l_qp_out_det_rec.adjustment_amount is not null
4063: AND l_qp_out_det_rec.line_quantity is not null) THEN
4064: -- l_stop_rec.ast_loading_chrg :=
4063: AND l_qp_out_det_rec.line_quantity is not null) THEN
4064: -- l_stop_rec.ast_loading_chrg :=
4065: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4066: -- bug 3474455
4067: l_stop_rec.ast_loading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
4068: l_stop_rec.ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4069: END IF;
4070:
4071: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_LOADING_PALLET_CH ) THEN
4067: l_stop_rec.ast_loading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
4068: l_stop_rec.ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4069: END IF;
4070:
4071: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_LOADING_PALLET_CH ) THEN
4072:
4073: IF (l_qp_out_det_rec.adjustment_amount is not null
4074: AND l_qp_out_det_rec.line_quantity is not null) THEN
4075: -- l_stop_rec.ast_loading_chrg :=
4075: -- l_stop_rec.ast_loading_chrg :=
4076: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4077: -- bug 3474455
4078: l_stop_rec.ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4079: l_stop_rec.ast_loading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
4080: END IF;
4081:
4082: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_LOADING_FLAT_CH ) THEN
4083:
4078: l_stop_rec.ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4079: l_stop_rec.ast_loading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
4080: END IF;
4081:
4082: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_LOADING_FLAT_CH ) THEN
4083:
4084: l_stop_rec.ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4085: l_stop_rec.ast_loading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
4086:
4081:
4082: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_LOADING_FLAT_CH ) THEN
4083:
4084: l_stop_rec.ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4085: l_stop_rec.ast_loading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
4086:
4087: END IF; -- Loading and Assisted Loading
4088:
4089: -- Look for Unloading and Assisted Unloading Charges
4086:
4087: END IF; -- Loading and Assisted Loading
4088:
4089: -- Look for Unloading and Assisted Unloading Charges
4090: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_UNLOADING_WEIGHT_CH ) THEN
4091:
4092: IF (l_qp_out_det_rec.adjustment_amount is not null
4093: AND l_qp_out_det_rec.line_quantity is not null) THEN
4094: -- l_stop_rec.unloading_chrg :=
4094: -- l_stop_rec.unloading_chrg :=
4095: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4096: -- bug 3474455
4097: l_stop_rec.unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4098: l_stop_rec.unloading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
4099: END IF;
4100:
4101: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_UNLOADING_VOLUME_CH ) THEN
4102:
4097: l_stop_rec.unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4098: l_stop_rec.unloading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
4099: END IF;
4100:
4101: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_UNLOADING_VOLUME_CH ) THEN
4102:
4103: IF (l_qp_out_det_rec.adjustment_amount is not null
4104: AND l_qp_out_det_rec.line_quantity is not null) THEN
4105: -- l_stop_rec.unloading_chrg :=
4105: -- l_stop_rec.unloading_chrg :=
4106: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4107: -- bug 3474455
4108: l_stop_rec.unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4109: l_stop_rec.unloading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
4110: END IF;
4111:
4112: ELSIF (l_qp_out_det_rec.charge_subtype_code
4113: = fte_rtg_globals.G_C_UNLOADING_CONTAINER_CH ) THEN
4109: l_stop_rec.unloading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
4110: END IF;
4111:
4112: ELSIF (l_qp_out_det_rec.charge_subtype_code
4113: = fte_rtg_globals.G_C_UNLOADING_CONTAINER_CH ) THEN
4114:
4115: IF (l_qp_out_det_rec.adjustment_amount is not null
4116: AND l_qp_out_det_rec.line_quantity is not null) THEN
4117: -- l_stop_rec.unloading_chrg :=
4117: -- l_stop_rec.unloading_chrg :=
4118: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4119: -- bug 3474455
4120: l_stop_rec.unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4121: l_stop_rec.unloading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
4122: END IF;
4123:
4124: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_UNLOADING_PALLET_CH ) THEN
4125:
4120: l_stop_rec.unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4121: l_stop_rec.unloading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
4122: END IF;
4123:
4124: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_UNLOADING_PALLET_CH ) THEN
4125:
4126: IF (l_qp_out_det_rec.adjustment_amount is not null
4127: AND l_qp_out_det_rec.line_quantity is not null) THEN
4128: -- l_stop_rec.unloading_chrg :=
4128: -- l_stop_rec.unloading_chrg :=
4129: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4130: -- bug 3474455
4131: l_stop_rec.unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4132: l_stop_rec.unloading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
4133: END IF;
4134:
4135: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_UNLOADING_FLAT_CH ) THEN
4136:
4131: l_stop_rec.unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4132: l_stop_rec.unloading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
4133: END IF;
4134:
4135: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_UNLOADING_FLAT_CH ) THEN
4136:
4137: l_stop_rec.unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4138: l_stop_rec.unloading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
4139:
4134:
4135: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_UNLOADING_FLAT_CH ) THEN
4136:
4137: l_stop_rec.unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4138: l_stop_rec.unloading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
4139:
4140: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_UNLOADING_WEIGHT_CH ) THEN
4141:
4142: IF (l_qp_out_det_rec.adjustment_amount is not null
4136:
4137: l_stop_rec.unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4138: l_stop_rec.unloading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
4139:
4140: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_UNLOADING_WEIGHT_CH ) THEN
4141:
4142: IF (l_qp_out_det_rec.adjustment_amount is not null
4143: AND l_qp_out_det_rec.line_quantity is not null) THEN
4144: -- l_stop_rec.ast_unloading_chrg :=
4144: -- l_stop_rec.ast_unloading_chrg :=
4145: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4146: -- bug 3474455
4147: l_stop_rec.ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4148: l_stop_rec.ast_unloading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
4149: END IF;
4150:
4151: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_UNLOADING_VOLUME_CH ) THEN
4152:
4147: l_stop_rec.ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4148: l_stop_rec.ast_unloading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
4149: END IF;
4150:
4151: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_UNLOADING_VOLUME_CH ) THEN
4152:
4153: IF (l_qp_out_det_rec.adjustment_amount is not null
4154: AND l_qp_out_det_rec.line_quantity is not null) THEN
4155: -- l_stop_rec.ast_unloading_chrg :=
4155: -- l_stop_rec.ast_unloading_chrg :=
4156: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4157: -- bug 3474455
4158: l_stop_rec.ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4159: l_stop_rec.ast_unloading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
4160: END IF;
4161:
4162: ELSIF (l_qp_out_det_rec.charge_subtype_code
4163: = fte_rtg_globals.G_C_AST_UNLOADING_CONTAINER_CH ) THEN
4159: l_stop_rec.ast_unloading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
4160: END IF;
4161:
4162: ELSIF (l_qp_out_det_rec.charge_subtype_code
4163: = fte_rtg_globals.G_C_AST_UNLOADING_CONTAINER_CH ) THEN
4164:
4165: IF (l_qp_out_det_rec.adjustment_amount is not null
4166: AND l_qp_out_det_rec.line_quantity is not null) THEN
4167: -- l_stop_rec.ast_unloading_chrg :=
4167: -- l_stop_rec.ast_unloading_chrg :=
4168: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4169: -- bug 3474455
4170: l_stop_rec.ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4171: l_stop_rec.ast_unloading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
4172: END IF;
4173:
4174: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_UNLOADING_PALLET_CH ) THEN
4175:
4170: l_stop_rec.ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4171: l_stop_rec.ast_unloading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
4172: END IF;
4173:
4174: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_UNLOADING_PALLET_CH ) THEN
4175:
4176: IF (l_qp_out_det_rec.adjustment_amount is not null
4177: AND l_qp_out_det_rec.line_quantity is not null) THEN
4178: -- l_stop_rec.ast_unloading_chrg :=
4178: -- l_stop_rec.ast_unloading_chrg :=
4179: -- l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4180: -- bug 3474455
4181: l_stop_rec.ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4182: l_stop_rec.ast_unloading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
4183: END IF;
4184:
4185: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_UNLOADING_FLAT_CH ) THEN
4186:
4181: l_stop_rec.ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4182: l_stop_rec.ast_unloading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
4183: END IF;
4184:
4185: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_UNLOADING_FLAT_CH ) THEN
4186:
4187: l_stop_rec.ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4188: l_stop_rec.ast_unloading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
4189:
4184:
4185: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_AST_UNLOADING_FLAT_CH ) THEN
4186:
4187: l_stop_rec.ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4188: l_stop_rec.ast_unloading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
4189:
4190: END IF; -- Unloading and Assisted Unloading
4191:
4192:
4191:
4192:
4193: -- Look for Origin and Destination Surcharges --
4194:
4195: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_ORIGIN_SURCHRG ) THEN
4196:
4197: l_stop_rec.origin_surchrg := l_qp_out_det_rec.adjustment_amount;
4198:
4199: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_DESTINATION_SURCHRG ) THEN
4195: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_ORIGIN_SURCHRG ) THEN
4196:
4197: l_stop_rec.origin_surchrg := l_qp_out_det_rec.adjustment_amount;
4198:
4199: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_DESTINATION_SURCHRG ) THEN
4200:
4201: l_stop_rec.destination_surchrg := l_qp_out_det_rec.adjustment_amount;
4202:
4203: END IF;
4203: END IF;
4204:
4205: -- Look for Weekday and Weekend Layover Charges
4206:
4207: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_WEEKDAY_LAYOVER_CH ) THEN
4208:
4209: fte_freight_pricing_util.print_msg(fte_freight_pricing_util.G_DBG,
4210: 'G_C_WEEKDAY_LAYOVER_CH : adjustment_amount='||l_qp_out_det_rec.adjustment_amount);
4211: IF (l_qp_out_det_rec.adjustment_amount is not null
4215: -- bug 3474455
4216: l_stop_rec.weekday_layover_chrg := l_qp_out_det_rec.adjustment_amount;
4217: END IF;
4218:
4219: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_C_WEEKEND_LAYOVER_CH ) THEN
4220:
4221: fte_freight_pricing_util.print_msg(fte_freight_pricing_util.G_DBG,
4222: 'G_C_WEEKEND_LAYOVER_CH : adjustment_amount='||l_qp_out_det_rec.adjustment_amount);
4223:
4243: -- dig up facility level charges
4244:
4245: -- Look for Facility Loading and Assisted Loading Charges --
4246:
4247: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_LOADING_WEIGHT_CH ) THEN
4248:
4249: -- l_stop_rec.fac_loading_chrg
4250: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4251: -- bug 3474455
4249: -- l_stop_rec.fac_loading_chrg
4250: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4251: -- bug 3474455
4252: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4253: l_stop_rec.fac_loading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
4254:
4255: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_LOADING_VOLUME_CH ) THEN
4256:
4257: -- l_stop_rec.fac_loading_chrg
4251: -- bug 3474455
4252: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4253: l_stop_rec.fac_loading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
4254:
4255: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_LOADING_VOLUME_CH ) THEN
4256:
4257: -- l_stop_rec.fac_loading_chrg
4258: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4259: -- bug 3474455
4257: -- l_stop_rec.fac_loading_chrg
4258: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4259: -- bug 3474455
4260: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4261: l_stop_rec.fac_loading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
4262:
4263: ELSIF (l_qp_out_det_rec.charge_subtype_code
4264: = fte_rtg_globals.G_F_LOADING_CONTAINER_CH ) THEN
4265:
4260: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4261: l_stop_rec.fac_loading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
4262:
4263: ELSIF (l_qp_out_det_rec.charge_subtype_code
4264: = fte_rtg_globals.G_F_LOADING_CONTAINER_CH ) THEN
4265:
4266: -- l_stop_rec.fac_loading_chrg
4267: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4268: -- bug 3474455
4266: -- l_stop_rec.fac_loading_chrg
4267: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4268: -- bug 3474455
4269: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4270: l_stop_rec.fac_loading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
4271:
4272: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_LOADING_PALLET_CH ) THEN
4273:
4274: -- l_stop_rec.fac_loading_chrg
4268: -- bug 3474455
4269: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4270: l_stop_rec.fac_loading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
4271:
4272: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_LOADING_PALLET_CH ) THEN
4273:
4274: -- l_stop_rec.fac_loading_chrg
4275: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4276: -- bug 3474455
4274: -- l_stop_rec.fac_loading_chrg
4275: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4276: -- bug 3474455
4277: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4278: l_stop_rec.fac_loading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
4279:
4280: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_LOADING_FLAT_CH ) THEN
4281:
4282: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4276: -- bug 3474455
4277: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4278: l_stop_rec.fac_loading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
4279:
4280: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_LOADING_FLAT_CH ) THEN
4281:
4282: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4283: l_stop_rec.fac_loading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
4284:
4279:
4280: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_LOADING_FLAT_CH ) THEN
4281:
4282: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4283: l_stop_rec.fac_loading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
4284:
4285: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_LOADING_WEIGHT_CH ) THEN
4286:
4287: -- l_stop_rec.fac_ast_loading_chrg
4281:
4282: l_stop_rec.fac_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4283: l_stop_rec.fac_loading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
4284:
4285: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_LOADING_WEIGHT_CH ) THEN
4286:
4287: -- l_stop_rec.fac_ast_loading_chrg
4288: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4289: -- bug 3474455
4287: -- l_stop_rec.fac_ast_loading_chrg
4288: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4289: -- bug 3474455
4290: l_stop_rec.fac_ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4291: l_stop_rec.fac_ast_loading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
4292:
4293: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_LOADING_VOLUME_CH ) THEN
4294:
4295: -- l_stop_rec.fac_ast_loading_chrg
4289: -- bug 3474455
4290: l_stop_rec.fac_ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4291: l_stop_rec.fac_ast_loading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
4292:
4293: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_LOADING_VOLUME_CH ) THEN
4294:
4295: -- l_stop_rec.fac_ast_loading_chrg
4296: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4297: -- bug 3474455
4295: -- l_stop_rec.fac_ast_loading_chrg
4296: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4297: -- bug 3474455
4298: l_stop_rec.fac_ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4299: l_stop_rec.fac_ast_loading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
4300:
4301: ELSIF (l_qp_out_det_rec.charge_subtype_code
4302: = fte_rtg_globals.G_F_AST_LOADING_CONTAINER_CH ) THEN
4303:
4298: l_stop_rec.fac_ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4299: l_stop_rec.fac_ast_loading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
4300:
4301: ELSIF (l_qp_out_det_rec.charge_subtype_code
4302: = fte_rtg_globals.G_F_AST_LOADING_CONTAINER_CH ) THEN
4303:
4304: -- l_stop_rec.fac_ast_loading_chrg
4305: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4306: -- bug 3474455
4304: -- l_stop_rec.fac_ast_loading_chrg
4305: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4306: -- bug 3474455
4307: l_stop_rec.fac_ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4308: l_stop_rec.fac_ast_loading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
4309:
4310: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_LOADING_PALLET_CH ) THEN
4311:
4312: l_stop_rec.fac_ast_loading_chrg
4306: -- bug 3474455
4307: l_stop_rec.fac_ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4308: l_stop_rec.fac_ast_loading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
4309:
4310: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_LOADING_PALLET_CH ) THEN
4311:
4312: l_stop_rec.fac_ast_loading_chrg
4313: := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4314: -- bug 3474455
4312: l_stop_rec.fac_ast_loading_chrg
4313: := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4314: -- bug 3474455
4315: l_stop_rec.fac_ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4316: l_stop_rec.fac_ast_loading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
4317:
4318: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_LOADING_FLAT_CH ) THEN
4319:
4320: l_stop_rec.fac_ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4314: -- bug 3474455
4315: l_stop_rec.fac_ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4316: l_stop_rec.fac_ast_loading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
4317:
4318: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_LOADING_FLAT_CH ) THEN
4319:
4320: l_stop_rec.fac_ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4321: l_stop_rec.fac_ast_loading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
4322:
4317:
4318: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_LOADING_FLAT_CH ) THEN
4319:
4320: l_stop_rec.fac_ast_loading_chrg := l_qp_out_det_rec.adjustment_amount;
4321: l_stop_rec.fac_ast_loading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
4322:
4323: END IF; -- Facility Loading and Assisted Loading
4324:
4325: -- Look for Facility Unloading and Assisted Unloading Charges
4322:
4323: END IF; -- Facility Loading and Assisted Loading
4324:
4325: -- Look for Facility Unloading and Assisted Unloading Charges
4326: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_UNLOADING_WEIGHT_CH ) THEN
4327:
4328: -- l_stop_rec.fac_unloading_chrg
4329: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4330: -- bug 3474455
4328: -- l_stop_rec.fac_unloading_chrg
4329: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4330: -- bug 3474455
4331: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4332: l_stop_rec.fac_unloading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
4333:
4334: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_UNLOADING_VOLUME_CH ) THEN
4335:
4336: -- l_stop_rec.fac_unloading_chrg
4330: -- bug 3474455
4331: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4332: l_stop_rec.fac_unloading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
4333:
4334: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_UNLOADING_VOLUME_CH ) THEN
4335:
4336: -- l_stop_rec.fac_unloading_chrg
4337: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4338: -- bug 3474455
4336: -- l_stop_rec.fac_unloading_chrg
4337: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4338: -- bug 3474455
4339: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4340: l_stop_rec.fac_unloading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
4341:
4342: ELSIF (l_qp_out_det_rec.charge_subtype_code
4343: = fte_rtg_globals.G_F_UNLOADING_CONTAINER_CH ) THEN
4344:
4339: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4340: l_stop_rec.fac_unloading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
4341:
4342: ELSIF (l_qp_out_det_rec.charge_subtype_code
4343: = fte_rtg_globals.G_F_UNLOADING_CONTAINER_CH ) THEN
4344:
4345: -- l_stop_rec.fac_unloading_chrg
4346: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4347: -- bug 3474455
4345: -- l_stop_rec.fac_unloading_chrg
4346: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4347: -- bug 3474455
4348: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4349: l_stop_rec.fac_unloading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
4350:
4351: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_UNLOADING_PALLET_CH ) THEN
4352:
4353: -- l_stop_rec.fac_unloading_chrg
4347: -- bug 3474455
4348: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4349: l_stop_rec.fac_unloading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
4350:
4351: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_UNLOADING_PALLET_CH ) THEN
4352:
4353: -- l_stop_rec.fac_unloading_chrg
4354: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4355: -- bug 3474455
4353: -- l_stop_rec.fac_unloading_chrg
4354: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4355: -- bug 3474455
4356: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4357: l_stop_rec.fac_unloading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
4358:
4359: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_UNLOADING_FLAT_CH ) THEN
4360:
4361: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4355: -- bug 3474455
4356: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4357: l_stop_rec.fac_unloading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
4358:
4359: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_UNLOADING_FLAT_CH ) THEN
4360:
4361: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4362: l_stop_rec.fac_unloading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
4363:
4358:
4359: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_UNLOADING_FLAT_CH ) THEN
4360:
4361: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4362: l_stop_rec.fac_unloading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
4363:
4364: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_UNLOADING_WEIGHT_CH ) THEN
4365:
4366: -- l_stop_rec.fac_ast_unloading_chrg
4360:
4361: l_stop_rec.fac_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4362: l_stop_rec.fac_unloading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
4363:
4364: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_UNLOADING_WEIGHT_CH ) THEN
4365:
4366: -- l_stop_rec.fac_ast_unloading_chrg
4367: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4368: -- bug 3474455
4366: -- l_stop_rec.fac_ast_unloading_chrg
4367: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4368: -- bug 3474455
4369: l_stop_rec.fac_ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4370: l_stop_rec.fac_ast_unloading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
4371:
4372: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_UNLOADING_VOLUME_CH ) THEN
4373:
4374: -- l_stop_rec.fac_ast_unloading_chrg
4368: -- bug 3474455
4369: l_stop_rec.fac_ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4370: l_stop_rec.fac_ast_unloading_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
4371:
4372: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_UNLOADING_VOLUME_CH ) THEN
4373:
4374: -- l_stop_rec.fac_ast_unloading_chrg
4375: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4376: -- bug 3474455
4374: -- l_stop_rec.fac_ast_unloading_chrg
4375: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4376: -- bug 3474455
4377: l_stop_rec.fac_ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4378: l_stop_rec.fac_ast_unloading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
4379:
4380: ELSIF (l_qp_out_det_rec.charge_subtype_code
4381: = fte_rtg_globals.G_F_AST_UNLOADING_CONTAINER_CH ) THEN
4382:
4377: l_stop_rec.fac_ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4378: l_stop_rec.fac_ast_unloading_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
4379:
4380: ELSIF (l_qp_out_det_rec.charge_subtype_code
4381: = fte_rtg_globals.G_F_AST_UNLOADING_CONTAINER_CH ) THEN
4382:
4383: -- l_stop_rec.fac_ast_unloading_chrg
4384: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4385: -- bug 3474455
4383: -- l_stop_rec.fac_ast_unloading_chrg
4384: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4385: -- bug 3474455
4386: l_stop_rec.fac_ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4387: l_stop_rec.fac_ast_unloading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
4388:
4389: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_UNLOADING_PALLET_CH ) THEN
4390:
4391: -- l_stop_rec.fac_ast_unloading_chrg
4385: -- bug 3474455
4386: l_stop_rec.fac_ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4387: l_stop_rec.fac_ast_unloading_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
4388:
4389: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_UNLOADING_PALLET_CH ) THEN
4390:
4391: -- l_stop_rec.fac_ast_unloading_chrg
4392: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4393: -- bug 3474455
4391: -- l_stop_rec.fac_ast_unloading_chrg
4392: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4393: -- bug 3474455
4394: l_stop_rec.fac_ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4395: l_stop_rec.fac_ast_unloading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
4396:
4397: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_UNLOADING_FLAT_CH ) THEN
4398:
4399: l_stop_rec.fac_ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4393: -- bug 3474455
4394: l_stop_rec.fac_ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4395: l_stop_rec.fac_ast_unloading_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
4396:
4397: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_UNLOADING_FLAT_CH ) THEN
4398:
4399: l_stop_rec.fac_ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4400: l_stop_rec.fac_ast_unloading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
4401:
4396:
4397: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_AST_UNLOADING_FLAT_CH ) THEN
4398:
4399: l_stop_rec.fac_ast_unloading_chrg := l_qp_out_det_rec.adjustment_amount;
4400: l_stop_rec.fac_ast_unloading_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
4401:
4402: END IF; -- Facility Unloading and Assisted Unloading
4403:
4404: -- Look for Facility Handling Charges --
4402: END IF; -- Facility Unloading and Assisted Unloading
4403:
4404: -- Look for Facility Handling Charges --
4405:
4406: IF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_HANDLING_WEIGHT_CH ) THEN
4407:
4408: -- l_stop_rec.fac_handling_chrg
4409: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4410: -- bug 3474455
4408: -- l_stop_rec.fac_handling_chrg
4409: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4410: -- bug 3474455
4411: l_stop_rec.fac_handling_chrg := l_qp_out_det_rec.adjustment_amount;
4412: l_stop_rec.fac_handling_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
4413:
4414: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_HANDLING_VOLUME_CH ) THEN
4415:
4416: -- l_stop_rec.fac_handling_chrg
4410: -- bug 3474455
4411: l_stop_rec.fac_handling_chrg := l_qp_out_det_rec.adjustment_amount;
4412: l_stop_rec.fac_handling_chrg_basis := fte_rtg_globals.G_WEIGHT_BASIS;
4413:
4414: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_HANDLING_VOLUME_CH ) THEN
4415:
4416: -- l_stop_rec.fac_handling_chrg
4417: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4418: -- bug 3474455
4416: -- l_stop_rec.fac_handling_chrg
4417: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4418: -- bug 3474455
4419: l_stop_rec.fac_handling_chrg := l_qp_out_det_rec.adjustment_amount;
4420: l_stop_rec.fac_handling_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
4421:
4422: ELSIF (l_qp_out_det_rec.charge_subtype_code
4423: = fte_rtg_globals.G_F_HANDLING_CONTAINER_CH ) THEN
4424:
4419: l_stop_rec.fac_handling_chrg := l_qp_out_det_rec.adjustment_amount;
4420: l_stop_rec.fac_handling_chrg_basis := fte_rtg_globals.G_VOLUME_BASIS;
4421:
4422: ELSIF (l_qp_out_det_rec.charge_subtype_code
4423: = fte_rtg_globals.G_F_HANDLING_CONTAINER_CH ) THEN
4424:
4425: -- l_stop_rec.fac_handling_chrg
4426: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4427: -- bug 3474455
4425: -- l_stop_rec.fac_handling_chrg
4426: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4427: -- bug 3474455
4428: l_stop_rec.fac_handling_chrg := l_qp_out_det_rec.adjustment_amount;
4429: l_stop_rec.fac_handling_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
4430:
4431: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_HANDLING_PALLET_CH ) THEN
4432:
4433: -- l_stop_rec.fac_handling_chrg
4427: -- bug 3474455
4428: l_stop_rec.fac_handling_chrg := l_qp_out_det_rec.adjustment_amount;
4429: l_stop_rec.fac_handling_chrg_basis := fte_rtg_globals.G_CONTAINER_BASIS;
4430:
4431: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_HANDLING_PALLET_CH ) THEN
4432:
4433: -- l_stop_rec.fac_handling_chrg
4434: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4435: -- bug 3474455
4433: -- l_stop_rec.fac_handling_chrg
4434: -- := l_qp_out_det_rec.adjustment_amount * l_qp_out_det_rec.line_quantity;
4435: -- bug 3474455
4436: l_stop_rec.fac_handling_chrg := l_qp_out_det_rec.adjustment_amount;
4437: l_stop_rec.fac_handling_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
4438:
4439: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_HANDLING_FLAT_CH ) THEN
4440:
4441: l_stop_rec.fac_handling_chrg := l_qp_out_det_rec.adjustment_amount;
4435: -- bug 3474455
4436: l_stop_rec.fac_handling_chrg := l_qp_out_det_rec.adjustment_amount;
4437: l_stop_rec.fac_handling_chrg_basis := fte_rtg_globals.G_PALLET_BASIS;
4438:
4439: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_HANDLING_FLAT_CH ) THEN
4440:
4441: l_stop_rec.fac_handling_chrg := l_qp_out_det_rec.adjustment_amount;
4442: l_stop_rec.fac_handling_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
4443:
4438:
4439: ELSIF (l_qp_out_det_rec.charge_subtype_code = fte_rtg_globals.G_F_HANDLING_FLAT_CH ) THEN
4440:
4441: l_stop_rec.fac_handling_chrg := l_qp_out_det_rec.adjustment_amount;
4442: l_stop_rec.fac_handling_chrg_basis := fte_rtg_globals.G_FLAT_BASIS;
4443:
4444: END IF; -- facility handling charges
4445:
4446: -----------------------------------------------------------------