Wednesday, October 26, 2016

Creating an Application in Oracle Max - Part 4 Adding the Accounts Flow


Welcome to Part 4 where we give access to Accounts information

In this step, you create a second screen flow that gives your users access to account information. The first screen lists your company's accounts. When users click a list item in this screen, they'll open a detail screen that shows them some basic information about the account itself and list of the opportunities that belong to it. As you did previously, you'll use the QuickStarts to build this screen flow
The Designer provides you with different ways to add screens to an app. Previously, you used Application Screens in the navbar to add the Opportunities screen. Here, you'll add a screen using the Properties Inspector for the Application Menu component.
  1. Open the Dashboard by double-clicking the Dashboard snapshot in the screen flow.

  1. In the Properties Inspector for the Application Menu component, click Menu Item.
    1. Complete the Create Screen wizard as follows:
      1. In the Landing Screen page, choose Simple Screen and then click Next.
        1. Enter Accounts in the Screen Title screen and then click Next.
        2. In the Content screen, choose List and then click Next, Finish
        3. Click Accounts in the Preview. Then click Go to Screen in the Properties Inspector.

Now lets put some data in the list 
Previously, you enabled the dashboard components to display data using the Data Mapper tool. In this (and subsequent) steps, you'll use the QuickStarts. These wizards not only allow you to add data to your UI, but enable you to build entire screen flows.
To add data to the accounts list:
  1. In the Properties Inspector for the List component, click the QuickStart icon.
    1. Click the Add Data Quickstart.
    2. In the Layout page, choose Title, Subtitle.
    3. Choose Account as the business object.
    4. Map the Account business object fields to the List Component as follows and then click Next.
      • Drag name to the Title field.
      • Drag city, state, country and region into the Subtitle field.
      • We're not going to filter this data, so click Finish in the Query page.
    5. Back in the Designer, the Accounts list displays in the Preview showing mock data.

Now In this step, you add a screen that lets your users see the opportunities that belong to a selected account along with some high-level information about the account itself.
  1. Click Add a Detail Screen.
  2. Choose Simple Screen with Summary
  3. Enter Account in the Screen Title field and then click Next.
  4. Choose List and then click Next.
  5. Click Finish.
  6. Click Go to Detail Screen.
  1. Open the Components Palette and then select the Card Component.
  2. Drag the Card component into the Summary Panel in the Preview
  3. In the Properties Inspector, click the Properties tab
  4. In the Properties Inspector for the Card component, clear the Graphic and Detail Section options. Select the Subtitle 1, and Subtitle 2 options.
  1. Open the QuickStart menu, choose Add Data and then choose Account. Click Next.
    1. In the Data tab, map the fields as follows and then click Next.
    2. name->Title
    3. city,state,country,region->St1
    4. Website->St2  
  2. You need to filter the data by the Account ID (aid) so that users can see the opportunity details that belong to an account. MAX has volunteered the aid from the parent screen (Accounts), so click Finish.

  1. Resize the summary pane:
    1. Double-click the Account screen header in the Preview.
    2. In the Properties Inspector, click Custom and then decrement the size to 100.
    3. Next, add data to the List component:
      1. Select the List component in the Preview or in the breadcrumbs trail
      2. If the QuickStarts panel doesn't appear, click QuickStarts and then click Add Data.
      3. You need all of the list fields for the account details, so choose the default layout and then click Next.
      4. In the Data Source page, click Opportunity.
  2. You'll see the mapped data when you change the Icon field type from a graphic to a status meter. You'll do that after you filter the data in the next step.
  3. You need to filter the data by the Account ID (aid) to allow users to see the opportunity details that belong to an account. Because the aid parameter belongs to the Accounts screen, click the Parent Screen category. Next, drag aid into the Aid field in the Query Parameters section of the screen. Click Finish.

  1. In the Preview, select the Icon field
  2. Change the icon field from an image to a status meter. The list data displays.
OK we are done adding screens and this blog post. 
In the next post we will cover off Navigation and Testing ! 


No comments: