/* $Id$ */
/*============================================================================*
 |                 Copyright (c) 2016 Applaud Solutions UK Ltd                |
 |                             All rights reserved                            |
 *===========================================================================*/

SET VERIFY OFF
SET FEEDBACK OFF
WHENEVER OSERROR  EXIT FAILURE ROLLBACK
WHENEVER SQLERROR EXIT FAILURE ROLLBACK

CREATE OR REPLACE VIEW XXAS_LINKS_MENU_V
AS
 SELECT function_id ,
  menu_id link_menu_id ,
  NVL(xxas_com_sec_pkg.get_function_parameter(f.function_name,'pLinksMenuName')
  ,fnd_profile.value('XXAS_COM_REG_ACTIONS_MENU')) link_menu_name
FROM fnd_form_functions f ,
  fnd_menus m
WHERE m.menu_name = NVL(xxas_com_sec_pkg.get_function_parameter(f.function_name,'pLinksMenuName') 
                        ,fnd_profile.value('XXAS_COM_REG_ACTIONS_MENU'));

BEGIN
  xxas_fnd_dictionary_pkg.add_view
   (p_application_short_name => xxas_util_pkg.app
   ,p_view_name              => 'XXAS_LINKS_MENU_V'
   ,p_description            => 'Applaud Links menu');
END;
/

COMMIT;
EXIT;

