Search icon CANCEL
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Oracle E-Business Suite R12 Integration and OA Framework Development and Extension Cookbook

You're reading from   Oracle E-Business Suite R12 Integration and OA Framework Development and Extension Cookbook A practical step-by-step guide to develop end-to-end extensions to Oracle E-Business Suite Release 12, with detailed illustrations and explanations

Arrow left icon
Product type Paperback
Published in Mar 2013
Publisher Packt
ISBN-13 9781849687126
Length 398 pages
Edition 1st Edition
Languages
Arrow right icon
Author (1):
Arrow left icon
Andy Penver Andy Penver
Author Profile Icon Andy Penver
Andy Penver
Arrow right icon
View More author details
Toc

Table of Contents (15) Chapters Close

Oracle E-Business Suite R12 Integration and OA Framework Development and Extension Cookbook
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
1. Personalizing OA Framework Pages FREE CHAPTER 2. Getting Started with OA Framework Pages 3. Creating a Master Detail Page in OA Framework 4. Adding a Creation Page and LOV Region in OA Framework 5. Advanced OA Framework 6. BI Publisher 7. Desktop Integration 8. Utilities Index

Using SPEL to trigger personalizations


SPEL stands for Simplest Possible Expression Language. A SPEL statement will return a Boolean value of either True or False and can be used for conditionally setting a property of an item on a page.

Adding a SPEL statement

In this recipe, we are going to use SPEL to set the properties of an item. We are going to set the Read Only property based on a SPEL statement. If the SPEL statement returns True, the item will be made read only to the user.

How to do it...

To set properties using SPEL, perform the following steps:

  1. Log in to Oracle with XXUSER and select the XX Test Manager Self-Service responsibility.

  2. Navigate to the Absence Management page.

  3. Click on the Action icon for an employee record.

  4. Click on the Create Absence button.

  5. Click on the Personalize Page link.

  6. Click on the Complete View radio button.

  7. Click on the Expand All link.

  8. Press Ctrl + F to bring up the search facility on the browser.

  9. Type in Comments and scroll down to the Message Text Input: Absence Comments record (which will be highlighted from the find).

  10. Click on the Personalize icon.

  11. Click on the Choose Levels Displayed button.

  12. Shift all of the items other than Site and Responsibility back to the Available Levels side.

  13. Click on the Apply button.

  14. Set the Read Only property at the Responsibility level to SPEL.

  15. Set the Responsibility level for the SPEL statement to ${oa.FunctionSecurity.XXABSREADONLY}, as shown in the following screenshot:

  16. Click on the Apply button.

  17. Scroll down to the bottom of the page and click on the Return to Application link.

How it works...

You may notice that the comments item is now not displayed on the screen. This is because we need to create the function and add it to the menu for the SPEL condition to be returned.

Creating a function

We are now going to create a function that we will add to a menu.

How to do it...

To create a function, perform the following steps:

  1. Log in to Oracle with XXUSER and select the Application Developer responsibility.

  2. Navigate to Application | Function.

  3. Create a function with the following details:

    Item name

    Item value

    Function

    XXABSREADONLY

    User Function Name

    XX Absence Read Only

    Description

    XX Absence Read Only

    Type

    Subfunction

    The function will be displayed as shown in the following screenshot:

  4. Save the record and dismiss the confirmation message.

Adding a function to a menu

We will now add a function to a menu attached to the XX Test Manager Self Service responsibility. The function will be present in the menu, which will mean that the SPEL statement will return True.

How it works...

To add a function to a menu, perform the following steps:

  1. Log in to Oracle with XXUSER and select the Application Developer responsibility.

  2. Navigate to Application | Menu.

  3. Query back the Manager Self Service menu.

  4. Add the function XXABSREADONLY to the menu with the following details:

    Item name

    Item value

    Seq

    200

    Function

    XX Absence Read Only

  5. Save the menu and dismiss the confirmation message to compile the menu.

We can see that the function has now been added to the menu as shown in the following screenshot:

You have been reading a chapter from
Oracle E-Business Suite R12 Integration and OA Framework Development and Extension Cookbook
Published in: Mar 2013
Publisher: Packt
ISBN-13: 9781849687126
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime