Addresses #451
git-svn-id: http://locode01.ad.dom/svn/WEBMIP/trunk@4712 248e525c-4dfb-0310-94bc-949c084e9493
This commit is contained in:
@@ -1560,7 +1560,8 @@ RECEIVED AT THIS ADDRESS CANNOT BE RESPONDED TO.');
|
|||||||
AND p_enqu.required_svcp_code IN ('LP', 'MP') THEN
|
AND p_enqu.required_svcp_code IN ('LP', 'MP') THEN
|
||||||
p_manual_or_automatic_quote := gc_manual_quote;
|
p_manual_or_automatic_quote := gc_manual_quote;
|
||||||
add_quote_reason(p_enqu.id
|
add_quote_reason(p_enqu.id
|
||||||
,'Site Survey is required for alteration (relocation or reposition) of an existing meter.'
|
,'Site Survey is required for alteration (relocation or reposition) of an existing ' ||
|
||||||
|
p_enqu.required_svcp_code || ' meter.'
|
||||||
,gc_external_reason);
|
,gc_external_reason);
|
||||||
END IF; -- ALTERATION
|
END IF; -- ALTERATION
|
||||||
|
|
||||||
@@ -1581,7 +1582,8 @@ RECEIVED AT THIS ADDRESS CANNOT BE RESPONDED TO.');
|
|||||||
p_manual_or_automatic_quote := gc_manual_quote;
|
p_manual_or_automatic_quote := gc_manual_quote;
|
||||||
add_quote_reason(p_enqu.id
|
add_quote_reason(p_enqu.id
|
||||||
,'Site Survey is required for exchange of an existing ' ||
|
,'Site Survey is required for exchange of an existing ' ||
|
||||||
l_svcpt_code || ' meter.'
|
l_svcpt_code || ' ' ||
|
||||||
|
l_rec_metr_details.mety_code || ' meter.'
|
||||||
,gc_external_reason);
|
,gc_external_reason);
|
||||||
ELSE
|
ELSE
|
||||||
-- Exchange, MP
|
-- Exchange, MP
|
||||||
@@ -2527,25 +2529,30 @@ RECEIVED AT THIS ADDRESS CANNOT BE RESPONDED TO.');
|
|||||||
END IF;
|
END IF;
|
||||||
|
|
||||||
END IF;
|
END IF;
|
||||||
/* Always get costs for LIFTING GEAR */
|
|
||||||
|
|
||||||
l_additional_costs := get_aico(p_adit_code => 'LIFTING GEAR'
|
/* Lifting gear required UNLESS Install/Standard Install of an LP Diaphragm */
|
||||||
,p_regi_code => l_regi_code);
|
IF NOT (p_enqu.enty_code IN ('INSTALL', 'STD INSTALL') AND
|
||||||
l_rec_module.lifting_gear_selling_price := l_additional_costs.selling_price;
|
l_rec_module.mety_code = 'DIAPHRAGM' AND
|
||||||
l_rec_module.lifting_gear_cost_price := l_additional_costs.cost_price;
|
l_rec_module.laco_svcpt_code = 'LP') THEN
|
||||||
l_rec_module.lifting_gear_delivery_cost := l_additional_costs.delivery_cost;
|
|
||||||
l_rec_module.lifting_gear_lead_time := l_additional_costs.lead_time;
|
l_additional_costs := get_aico(p_adit_code => 'LIFTING GEAR'
|
||||||
IF l_rec_module.lifting_gear_selling_price IS NULL THEN
|
,p_regi_code => l_regi_code);
|
||||||
l_this_is_automatic_quote := FALSE;
|
l_rec_module.lifting_gear_selling_price := l_additional_costs.selling_price;
|
||||||
add_quote_reason(p_enqu.id
|
l_rec_module.lifting_gear_cost_price := l_additional_costs.cost_price;
|
||||||
,p_reason => 'Unable to find selling price for LIFTING GEAR.'
|
l_rec_module.lifting_gear_delivery_cost := l_additional_costs.delivery_cost;
|
||||||
,p_internal_or_external => gc_internal_reason);
|
l_rec_module.lifting_gear_lead_time := l_additional_costs.lead_time;
|
||||||
END IF;
|
IF l_rec_module.lifting_gear_selling_price IS NULL THEN
|
||||||
IF l_rec_module.lifting_gear_lead_time IS NULL THEN
|
l_this_is_automatic_quote := FALSE;
|
||||||
l_this_is_automatic_quote := FALSE;
|
add_quote_reason(p_enqu.id
|
||||||
add_quote_reason(p_enqu.id
|
,p_reason => 'Unable to find selling price for LIFTING GEAR.'
|
||||||
,p_reason => 'Unable to find lead time for LIFTING GEAR.'
|
,p_internal_or_external => gc_internal_reason);
|
||||||
,p_internal_or_external => gc_internal_reason);
|
END IF;
|
||||||
|
IF l_rec_module.lifting_gear_lead_time IS NULL THEN
|
||||||
|
l_this_is_automatic_quote := FALSE;
|
||||||
|
add_quote_reason(p_enqu.id
|
||||||
|
,p_reason => 'Unable to find lead time for LIFTING GEAR.'
|
||||||
|
,p_internal_or_external => gc_internal_reason);
|
||||||
|
END IF;
|
||||||
END IF;
|
END IF;
|
||||||
|
|
||||||
IF l_this_is_automatic_quote THEN
|
IF l_this_is_automatic_quote THEN
|
||||||
@@ -2711,26 +2718,27 @@ RECEIVED AT THIS ADDRESS CANNOT BE RESPONDED TO.');
|
|||||||
,'AQI');
|
,'AQI');
|
||||||
END IF;
|
END IF;
|
||||||
|
|
||||||
/* Always include LIFTING GEAR */
|
IF l_rec_module.lifting_gear_selling_price IS NOT NULL THEN
|
||||||
|
|
||||||
INSERT INTO quote_items
|
INSERT INTO quote_items
|
||||||
(id
|
(id
|
||||||
,qute_id
|
,qute_id
|
||||||
,adit_code
|
,adit_code
|
||||||
,cost_price
|
,cost_price
|
||||||
,selling_price
|
,selling_price
|
||||||
,delivery_price
|
,delivery_price
|
||||||
,lead_time
|
,lead_time
|
||||||
,quit_type)
|
,quit_type)
|
||||||
VALUES
|
VALUES
|
||||||
(quit_seq.NEXTVAL
|
(quit_seq.NEXTVAL
|
||||||
,l_qute_id
|
,l_qute_id
|
||||||
,'LIFTING GEAR'
|
,'LIFTING GEAR'
|
||||||
,l_rec_module.lifting_gear_cost_price
|
,l_rec_module.lifting_gear_cost_price
|
||||||
,l_rec_module.lifting_gear_selling_price
|
,l_rec_module.lifting_gear_selling_price
|
||||||
,l_rec_module.lifting_gear_delivery_cost
|
,l_rec_module.lifting_gear_delivery_cost
|
||||||
,l_rec_module.lifting_gear_lead_time
|
,l_rec_module.lifting_gear_lead_time
|
||||||
,'AQI');
|
,'AQI');
|
||||||
|
END IF;
|
||||||
|
|
||||||
-- Generate the quote PDF
|
-- Generate the quote PDF
|
||||||
/*BEGIN*/
|
/*BEGIN*/
|
||||||
|
|||||||
Reference in New Issue
Block a user