create or replace package body efnow050$ is private_ModuleRef WSGOC.MODULE_REF; procedure CreateStartupJavaScript; PROCEDURE contract_options_P( p_contract_id IN NUMBER , p_success IN VARCHAR2 DEFAULT 'N' , p_error IN VARCHAR2 DEFAULT 'N' , p_err_msg IN VARCHAR2 DEFAULT NULL ) IS -- contract_options -- -- BEGIN -- Check we have permission to be using this module. IF NOT caco_security.security_check('efnow050$') THEN RETURN; END IF; -- efnow092$.g_package_name := 'efnow050$'; -- efnow092$.contract_options_P( p_contract_id => p_contract_id , p_success => p_success , p_error => p_error , p_err_msg => p_err_msg ); -- END; PROCEDURE contract_rules( p_contract_id IN NUMBER , p_success IN VARCHAR2 DEFAULT 'N' , p_error IN VARCHAR2 DEFAULT 'N' , p_err_msg IN VARCHAR2 DEFAULT NULL ) IS -- contract_rules -- -- BEGIN -- Check we have permission to be using this module. IF NOT caco_security.security_check('efnow050$') THEN RETURN; END IF; -- efnow092$.g_package_name := 'efnow050$'; -- efnow092$.contract_rules( p_contract_id => p_contract_id , p_success => p_success , p_error => p_error , p_err_msg => p_err_msg ); -- END; PROCEDURE contract_startup( p_screen_type IN VARCHAR2 DEFAULT 'CONTRACT' , p_ins_or_upd IN VARCHAR2 DEFAULT 'INSERT' , p_success IN VARCHAR2 DEFAULT NULL , p_contract_id IN contracts.cont_id%TYPE DEFAULT 0 , p_contract_number IN VARCHAR2 DEFAULT NULL , p_pre_contract_id IN contracts.prev_cont_id%TYPE DEFAULT 0 , p_template_id IN contract_templates.cote_id%TYPE DEFAULT 0 , p_template_name IN VARCHAR2 DEFAULT NULL , p_template_desc IN VARCHAR2 DEFAULT NULL , p_emo IN VARCHAR2 DEFAULT NULL , p_customer_id IN customers.cust_id%TYPE DEFAULT 0 , p_spte_id IN spreadsheet_templates.spte_id%TYPE DEFAULT 0 , p_ops_contact IN VARCHAR2 DEFAULT NULL , p_bus_contact IN VARCHAR2 DEFAULT NULL , p_status IN contracts.status%TYPE DEFAULT NULL , p_days_before IN VARCHAR2 DEFAULT NULL , p_date_from IN VARCHAR2 DEFAULT NULL , p_date_to IN VARCHAR2 DEFAULT NULL , p_val_window IN VARCHAR2 DEFAULT 0 , p_val_action IN contracts.validation_action%TYPE DEFAULT NULL , p_val_exception IN contracts.validation_exception%TYPE DEFAULT NULL , p_lookback_action IN contracts.lookback_action%TYPE DEFAULT NULL , p_template_changed IN VARCHAR2 DEFAULT NULL , p_prev_template_id IN NUMBER DEFAULT NULL , p_error IN VARCHAR2 DEFAULT NULL , p_err_msg IN VARCHAR2 DEFAULT NULL , p_nepo_id IN owa_util.vc_arr DEFAULT efnow092$.g_vc_arr , p_cate_id IN owa_util.vc_arr DEFAULT efnow092$.g_vc_arr , p_pars_id IN owa_util.vc_arr DEFAULT efnow092$.g_vc_arr ) IS -- contract_startup -- -- BEGIN -- Check we have permission to be using this module. IF NOT caco_security.security_check('efnow050$') THEN RETURN; END IF; -- -- Set the package name in efnow092$ efnow092$.g_package_name := 'efnow050$'; -- -- Call the contracts startup efnow092$.startup( p_screen_type => p_screen_type , p_ins_or_upd => p_ins_or_upd , p_success => p_success , p_contract_id => p_contract_id , p_contract_number => p_contract_number , p_template_id => p_template_id , p_template_name => p_template_name , p_template_desc => p_template_desc , p_emo => p_emo , p_customer_id => p_customer_id , p_spte_id => p_spte_id , p_ops_contact => p_ops_contact , p_bus_contact => p_bus_contact , p_status => p_status , p_days_before => p_days_before , p_date_from => p_date_from , p_date_to => p_date_to , p_val_window => p_val_window , p_val_action => p_val_action , p_val_exception => p_val_exception , p_lookback_action => p_lookback_action , p_template_changed => p_template_changed , p_prev_template_id => p_prev_template_id , p_error => p_error , p_err_msg => p_err_msg , p_nepo_id => p_nepo_id , p_cate_id => p_cate_id , p_pars_id => p_pars_id ); -- END contract_startup; PROCEDURE contract_values_p2( p_contract_id IN NUMBER , p_page_no IN NUMBER DEFAULT 1 , p_success IN VARCHAR2 DEFAULT 'N' , p_error IN VARCHAR2 DEFAULT 'N' , p_err_msg IN VARCHAR2 DEFAULT NULL , p_cnppv_id IN owa_util.vc_arr DEFAULT efnow092$.g_vc_arr , p_value IN owa_util.vc_arr DEFAULT efnow092$.g_vc_arr , p_data_error IN owa_util.vc_arr DEFAULT efnow092$.g_vc_arr ) IS -- contract_values_p2 -- -- BEGIN -- Check we have permission to be using this module. IF NOT caco_security.security_check('efnow050$') THEN RETURN; END IF; -- -- Set the package name efnow092$.g_package_name := 'efnow050$'; -- -- Call efno092$ efnow092$.contract_values_p2( p_contract_id => p_contract_id , p_page_no => p_page_no , p_success => p_success , p_error => p_error , p_err_msg => p_err_msg , p_cnppv_id => p_cnppv_id , p_value => p_value , p_data_error => p_data_error ); -- END; PROCEDURE template_rules( p_template_id IN NUMBER , p_success IN VARCHAR2 DEFAULT 'N' , p_error IN VARCHAR2 DEFAULT 'N' , p_err_msg IN VARCHAR2 DEFAULT NULL ) IS -- template_rules -- -- BEGIN -- Check we have permission to be using this module. IF NOT caco_security.security_check('efnow050$') THEN RETURN; END IF; -- efnow092$.g_package_name := 'efnow050$'; -- efnow092$.template_rules( p_template_id => p_template_id , p_success => p_success , p_error => p_error , p_err_msg => p_err_msg ); -- END; -------------------------------------------------------------------------------- -- Name: efnow050$.Startup -- -- Description: This procedure is the entry point for the 'efnow050$' -- module. -- -- Parameters: None -- -------------------------------------------------------------------------------- procedure Startup is begin if not caco_security.security_check('efnow050$') then return; end if; WSGL.RegisterURL('efnow050$.startup'); if WSGL.NotLowerCase then return; end if; WSGL.StoreURLLink(0, WSGL.MsgGetText(21,WSGLM.CAP021_TOP_LEVEL)); efnow050$cont.startup( Z_DIRECT_CALL => TRUE ); exception when others then WSGL.DisplayMessage(WSGL.MESS_EXCEPTION, SQLERRM, '', '', 'efnow050$.Startup'); end; -------------------------------------------------------------------------------- -- Name: efnow050$.firstpage -- -- Description: This procedure creates the first page for the 'efnow050$' -- module. -- -- Parameters: Z_DIRECT_CALL -- -------------------------------------------------------------------------------- procedure FirstPage(Z_DIRECT_CALL in boolean ) is begin if not caco_security.security_check('efnow050$') then return; end if; WSGL.OpenPageHead(''); WSGL.METATag; WSGL.ClosePageHead; WSGL.OpenPageBody(FALSE, p_attributes=>''); CreateStartupJavaScript; WSGL.DefaultPageCaption('', 1); htp.formOpen(curl => 'ActionItem', cattributes => 'NAME="SP$AIForm"'); WSGL.NavLinks(WSGL.MENU_LONG, 'EFNOW060', 0, 'efnow060$.startup',p_output_line=>FALSE, p_target=>'_top'); WSGL.NavLinks(WSGL.MENU_LONG, 'EFNOW020', 0, 'efnow020$.startup',p_output_line=>FALSE, p_target=>'_top'); WSGL.NavLinks(WSGL.MENU_LONG, 'EFNOW092', 0, 'efnow092$.startup',p_output_line=>FALSE, p_target=>'_top'); WSGL.NavLinks(WSGL.MENU_LONG, WSGL.MsgGetText(107,WSGLM.DSP107_ABOUT), 0, 'efnow050$.showabout', '_top', p_output_line=>FALSE); WSGL.NavLinks; htp.formClose; WSGL.ClosePageBody; exception when others then WSGL.DisplayMessage(WSGL.MESS_EXCEPTION, SQLERRM, '', '', 'efnow050$.FirstPage'); end; -------------------------------------------------------------------------------- -- Name: efnow050$.showabout -- -- Description: This procedure is used to display an 'About' page for the -- 'efnow050$' module. -- -------------------------------------------------------------------------------- procedure showabout is l_usr varchar2(255) := null; begin if not caco_security.security_check('efnow050$') then return; end if; l_usr := caco_security.get_user; WSGL.RegisterURL('efnow050$.showabout'); if WSGL.NotLowerCase then return; end if; WSGL.OpenPageHead(WSGL.MsgGetText(107,WSGLM.DSP107_ABOUT)||' '); WSGL.METATag; TemplateHeader(TRUE,2); WSGL.ClosePageHead; WSGL.OpenPageBody(FALSE, p_attributes=>''); htp.p(caco_system.menu); WSGL.DefaultPageCaption(WSGL.MsgGetText(107,WSGLM.DSP107_ABOUT)||' '); htp.para; htp.p(' $Revision: 1.4 $'); htp.para; htp.para; htp.p(WSGL.MsgGetText(108,WSGLM.DSP108_GENERATED_BY, 'PL/SQL Web Generator', '10.1.2.6.18')); htp.para; WSGL.Info(FALSE, 'Nominations', 'EFNOW050', l_usr); htp.p(caco_system.footer); WSGL.ClosePageBody; exception when others then WSGL.DisplayMessage(WSGL.MESS_EXCEPTION, SQLERRM, '', '', 'efnow050$.ShowAbout'); end; -------------------------------------------------------------------------------- -- Name: efnow050$.TemplateHeader -- -- Description: -- -------------------------------------------------------------------------------- procedure TemplateHeader(Z_DIRECT_CALL in boolean, Z_TEMPLATE_ID in number) is begin if not caco_security.security_check('efnow050$') then return; end if; if Z_TEMPLATE_ID = 1 then -- Template defined in \\loordv01\framework\css2\css_content.htm htp.p(' '); elsif Z_TEMPLATE_ID = 2 then -- Template defined in \\loordv01\framework\css2\css_about.htm htp.p(' '); elsif Z_TEMPLATE_ID = 3 then -- Template defined in \\loordv01\framework\css2\css_query.htm htp.p(' '); elsif Z_TEMPLATE_ID = 4 then -- Template defined in \\loordv01\framework\css2\css_view.htm htp.p(' '); elsif Z_TEMPLATE_ID = 5 then -- Template defined in \\loordv01\framework\css2\css_insert.htm htp.p(' '); elsif Z_TEMPLATE_ID = 6 then -- Template defined in \\loordv01\framework\css2\css_recordlist.htm htp.p(' '); elsif Z_TEMPLATE_ID = 7 then -- Template defined in \\loordv01\framework\css2\css_lov.htm htp.p(' '); elsif Z_TEMPLATE_ID = 8 then -- Template defined in \\loordv01\framework\css2\css_text.htm htp.p(' '); end if; exception when others then WSGL.DisplayMessage(WSGL.MESS_EXCEPTION, SQLERRM, '', '', 'efnow050$.TemplateHeader'); end; -------------------------------------------------------------------------------- -- Name: efnow050$.GetRef -- -- Description: Returns a handle to the display data for the -- 'efnow050$' module. -- If the display object does not exist then it creates it first. -- -- Parameters: -- -------------------------------------------------------------------------------- function GetRef return WSGOC.MODULE_REF is begin if ( WSGOC.Is_Null(private_ModuleRef)) then private_ModuleRef := WSGOC.Module ( pShortName => 'efnow050$' , pFirstTitle => '' ); end if; return private_ModuleRef; exception when others then WSGL.DisplayMessage(WSGL.MESS_EXCEPTION, SQLERRM, '', '', 'efnow050$.GetRef'); raise; end; -------------------------------------------------------------------------------- -- Name: efnow050$.CreateStartupJavaScript -- -- Description: -- -- Parameters: -- -------------------------------------------------------------------------------- procedure CreateStartupJavaScript is begin htp.p(WSGJSL.OpenScript); htp.p('var FormType = "Startup";'); htp.p(WSGJSL.CloseScript); end; end; /