Architectural View of EnterpriseOne

Title: How to add additional columns in P42101 - (Power Form) Sales Order Entry

Abstract: This document explains how the User Reserved Reference in the Grid can be added/updated when creating Sales Order in P42101. Actual implementation can vary.

Caution: This document may contain information, software, products or services which are not supported by Oracle Support Services and are being provided ‘as is’ without warranty. Please refer to the following site for My Oracle Support Terms of Use: https://support.oracle.com/CSP/ui/TermsOfUse.html


Table of Contents

Introduction
User Interface

Example of Implementation

 


Introduction

A newly introduced Power Form has different set of user interface. Unlike conventional Header/Detail Form (P4210/W4210A – Sales Order Detail) power form handles data through Data Structure not through Business View. The architecture is based on the Model-View-Controller (MVC) pattern.

 

The MVC components are described as follows:

1. Model (data and its surrounding business logic):

The Model is composed of C business functions and state objects (caches, linked lists, etc.) which encapsulate:

o Data model at runtime (i.e. Sales Order Header/Detail information),

o State information (i.e. has a particular line been processed, does the sales order have any unprocessed lines, etc.)

o Business logic (i.e. validate customer, check availability, etc.)

The business logic is exposed through a set of public interfaces defined for the business domain.

 

2. Controller:

Also called Application Controller, the controller is a very thin layer in the MVC architecture that is used to orchestrate execution of the business logic in the model. The controller maps the user’s actions in the view to the model’s public interface based on an Action Code passed in by the caller.

The Action Codes are pre-defined constants that are defined by the controller. The controller is also responsible for error handling and next view selection and is a good place to hook up custom business logic.

 

3. View:

Traditionally, view development in EnterpriseOne has been limited to applications that are designed in Form Design Aid. In order to ensure more effective state management within the view, and to enable the separation of User Interface logic from business logic, a new type of C function is introduced with MVC, the View Controller. In reality, a View Controller is no different than a regular C business function. The only distinction is that MVC places different responsibilities on View Controller functions.

Back to Top

User Interface

Note that this document is written based on EnterpriseOne Application release 9.1. The actual implement can be vary in different application releases but basic concept is to be remaining same.

This information can be obtained by analyzing the JASDEBUG log. Below steps are simplified steps of the user interface with P42101 – (Power Form) Sales Order Entry

1.        In launching application P42101 it calls P42101/W42101C - [Manage Existing Order]

2.       In adding/updating order it calls P42101/W42101D - [Enter New Order]

3.      User input additional columns in the Grid P421002/S421002C - [Sales Order Detail]

4.      B4210620 - S421002C_SOLineViewcontroller (S421002C Sales Order Line View

Controller) delivers message to Header

5.  Map value entered through B4210030

 /* doseo - start to assign user reserved columns */

   jdeStrcpy(lpdsPreProcessor->szUserReservedReference,

             lpdsSalesOrderLine->dsBusinessData.szUserReservedReference);

        /* doseo end */

 

6.      Once message is delivered it follows standard Master Business Function flow through B4200310/B4200311 - F4211FSEditLine/F4211SOEInternalFunctions to save Grid Information into cache (F42UI11/F42UI12)

7.       B4200310 - F4211FSEndDoc (to commit cache to table F4211 – Sales Order Detail)

 

 

Possible Implementation

  1. Add additional column in P421002, S421002C – Sales Order Detail Reusable Subform (to assign GC User Reference)

à Now user is able to enter GC User Reference

 

 

To deliver this message to header modify Data Structure of D4210620A – S421002C_SalesOrderDetailData

 

  1. Add additional parameter to D4210620A - S421002C_SalesOrderDetailData

 

  1. Look for DD Alias ‘URRF’ and drag and drop to “Structure Member”

à If necessary change Structure Member Name

 

 

Note: Step 4 through 8 can be updated/modified through usual Object Management or Package Build Process. So if necessary, skip these steps from 4 to 8

 

 

  1. Click “Create a type definition”

à Data Structure information has been stored at clipboard

à Note that same change can be done through manual override

 

 

 

  1. (Optional) Ctrl + V to paste clipboard into text file

à This action is to make it sure clipboard contains the latest information/data

 

 

 

 

  1. Actual Value (this information repeats in pasted value of clipboard and b4210620.h file)
    1. Name: typedef struct tagDSD4210620A
    2. Verify that additional parameter is added

 

 

/*****************************************

 * TYPEDEF for Data Structure

 *    Template Name: S421002C_SalesOrderDetailData                              

 *    Template ID:   D4210620A

 *    Generated:     Mon May 05 21:09:44 2008

 *

 * DO NOT EDIT THE FOLLOWING TYPEDEF

 *    To make modifications, use the OneWorld Data Structure

 *    Tool to Generate a revised version, and paste from

 *    the clipboard.

 *

 **************************************/

 

#ifndef DATASTRUCTURE_D4210620A

#define DATASTRUCTURE_D4210620A

 

typedef struct tagDSD4210620A

{

  JCHAR             szSessionKey[33];                   

  MATH_NUMERIC      mnLineKey;                          

  JCHAR             szViewVersion[11];                  

  JCHAR             cLineProcessStatus;                 

  JCHAR             cMoreNewLines;                      

  JCHAR             cGetFirstLine;                      

  int               nViewSelectionRequired;             

                 

  JCHAR             szUserReservedReference[16];        

} DSD4210620A, *LPDSD4210620A;

 

#define IDERRszSessionKey_81                      81L

#define IDERRmnLineKey_82                         82L

#define IDERRszViewVersion_84                     84L

#define IDERRcLineProcessStatus_85                85L

#define IDERRcMoreNewLines_86                     86L

#define IDERRcGetFirstLine_88                     88L

#define IDERRnViewSelectionRequired_89            89L

#define IDERRszUserReservedReference_251          251L

 

#endif

 

 

  1. Modify B4210620.h based on typedef information

 

 

 

 

  1. If possible copy and paste typedef after allocating valid tagDS name

 

à Additional parameter has been added

 

à Additional parameter has been added

 

 

 

 

 

  1. Add additional Grid Column through B4210620 – S421002_SOLineViewController

 

 

 

à Verify that GC_URRF has been added

 

 

  1. Now you are about to map detail line information, which falls into one of below

IB4210030_ComposeEditLineData: the parameters you can see from F4211FSEditLine

Or,

IB4210030_IPreProcessSalesOrderLine

              |--- IB4210030_ComposePreProcessData: User reserved columns are handled here so proper mapping need to be done (each parameter can be found at F4211FSEditLinePreProcess)

*** Break In Code ***

void IB4210030_ComposePreProcessData(LPDSD4200310J         lpdsPreProcessor,

                                     LPDSSALESORDERHEADER  lpdsSalesOrderHeader,

                                     LPDSSALESORDERLINE    lpdsSalesOrderLine,

                                     BOOL                  bKitConfigWindowOpened,

                                     LPCALLMAP *           lplpCallMap,

                                     int *                 lpiNumCallMap)

 

{

*** Break In Code ***

/* doseo - start to assign user reserved columns */

   jdeStrcpy(lpdsPreProcessor->szUserReservedReference,

             lpdsSalesOrderLine->dsBusinessData.szUserReservedReference);

        /* doseo end */

 

   return;

}

*** Break In Code ***

 

 

 

 

 

  1. To apply this change run “BusBuild.exe” to compile it

 

 

Now you are ready to assign UI value into BSFN B4210620 through Data Structure of D4210620A

 

  1. To apply this change to P421002

 

 

  1. Assign parameters in calling B4201620 at ‘Notified By Parent’ event

à This is to show column on Parent Form (P42101)

è Repeat this for all calling (type of variable can be GC or GB you may follow exiting values)

 

 

 

 

à Map added column

 

 

  1. Repeat this action for Add Mode at the event of ‘Add Last Entry Row to Grid’

à Add mode

 

 

 

  1. Repeat this mapping for Update Mode at the event of ‘Get Custom Grid Row’

à To show data on update mode

è Repeat this for all calling (type of variable can be GC or GB you may follow exiting values)

 

 

  1. Repeat this mapping for Change of Data in UPDATE Mode at the event of ‘Row Exit & Changed – Asynch’

à To update data on Update mode

 

 

 

Test it,

Add Mode:-

è Additional column User Reference is entered

 

è User entered value is handed over to S421002C_SOLineViewController

è Input parameter of EditLinePreprocess got assigned

 

Update Mode:

 

Back to Top