26 Reports

The Reports module is an application available in Supply Chain Hub. This chapter describes the implementation considerations and the operation details.

Implementation Overview

This section provides an implementation overview for Report.

Functionality

Reports gives the possibility for Retailers to share BI Publisher reports with supplier users.

Integration High Level

Figure 26-1 Reports Integration High Level


Reports Integration High Level

Configuration

This module has multiple configurations to support its functionalities and, in the subsections, below, those configurations are highlighted. For some of them, it is imperative to validate the functionality of common frameworks in the Supply Chain Hub Frameworks section.

Report Configuration

In Reports application it is possible to add Reports, it will require the configuration details of the Report Type and Report. The configuration for reports is described in this section.

Database Objects

Configurations details must be defined in Reports tables and Reports filter views created.

Tables

ORCV_RPTS_REPORT_TYPE

This table holds the definition of Report Types and associates with the Application that uses the Report. The access to the Reports is set based on the APP_ALIAS and ENTITY_ID defined at Report Type and only users with access to it will be able to see the Reports of the Report Type. The translations for Report Types are set in ORCV_RPTS_REPORT_TYPE_TL.

Column Name Data Type Column Description
REPORT_TYPE_ID VARCHAR2 This field contains the report type id.
REPORT_TYPE_DESC VARCHAR2 This field contains the report type description.
APP_ALIAS VARCHAR2 This field contains the application alias of the report type.
ENTITY_ID VARCHAR2 This field contains the entity identification of the report type.

ORCV_RPTS_REPORT_HEAD

This table holds the details of Reports, they can be configured with up to 3 filters, those are defined as the name of the view that gets the entries allowed in the filter and they are responsible to apply data level security. The translations for Reports are set in ORCV_RPTS_REPORT_HEAD_TL.

Column Name Data Type Column Description
REPORT_ID VARCHAR2 This field contains the report identification.
REPORT_TYPE_ID VARCHAR2 This field contains the report type identification according orcv_rpts_report_type.
REPORT_NAME VARCHAR2 This field contains the report name.
REPORT_DESC VARCHAR2 This field contains the report description.
ENDPOINT_ID VARCHAR2 This field contains the endpoint id to call the report, it is required to be configured in ORCV_WS_ENDPOINT.
REPORT_URL_PATH VARCHAR2 This field contains the url path of the report.
PAYLOAD VARCHAR2 This field contains the payload for call the report.
FILTER_VIEW_1 VARCHAR2 This field contains the name of the view to filter 1.
FILTER_VIEW_2 VARCHAR2 This field contains the name of the view to filter 2.
FILTER_VIEW_3 VARCHAR2 This field contains the name of the view to filter 3.
FILTER_LABEL_1 VARCHAR2 This field contains the label to filter 1.
FILTER_LABEL_2 VARCHAR2 This field contains the label to filter 2.
FILTER_LABEL_3 VARCHAR2 This field contains the label to filter 3.
STATUS VARCHAR2 This field contains the status of the report.It can be "A"ctive/"I"nactive).
OUTPUT_FILE_NAME VARCHAR2 This field contains the name of the report generated.
REPORT_ICON VARCHAR2 This field contains the report icon image.
Views

It is possible to configure Reports filters based on views, the views must follow the structure below. The reports will be retrieve passing the CODE as the value.

Column Name Data Type Column Description
CODE VARCHAR2 Code value of the filter to be passed to the report.
CODE_DESC VARCHAR2 Code Description to be shown in Reports pages.
SEQ_NO NUMBER Column to order the filter presented in Reports pages.
Packages

When the Reports are requested from Reports pages it will use the following packages to retrieve the Report.

Package Name Package Description
ORCV_RPTS_MANAGE_P100_UI Package used in Apex to call Reports API.
ORCV_RPTS_REPORT Package that uses internal frameworks and retrieves the Report.
Configuration Steps
# Step Example
1 Configure the endpoint Configure the endpoint to be used in Reports in ORCV_WS_ENDPOINT.
2 Create the views defined as Filter Views

CREATE OR REPLACE VIEW NB_V_ORDER_FILTER_LOV (CODE, CODE_DESC, SEQ_NO) AS

SELECT order_no code, 'Order No ' || order_no code_desc, ROWNUM seq_no

FROM dcv_wv_ordhead oh

WHERE EXISTS (SELECT 1 FROM orcv_v_sppp_suppliers sec WHERE oh.supplier = sec.supplier AND ROWNUM = 1)

ORDER BY order_no;

3

Add a Report Type to

ORCV_RPTS_REPORT_TYPE

REPORT_TYPE_ID: SPPP_SAMPLE

REPORT_TYPE_DESC: Procure to Pay Sample

APP_ALIAS: SPPP

ENTITY_ID: ORDER

4

Add a Report to

ORCV_RPTS_REPORT_HEAD

REPORT_ID: SPPP_SAMPLE_ORDER_PDF

REPORT_TYPE_ID: SPPP_SAMPLE

REPORT_NAME: Order Detail Sample

REPORT_DESC: Order Detail Sample in PDF format

ENDPOINT_ID: ORCV_OBIP_REPORTS

REPORT_URL_PATH: MFCS%252FOrders%252Ford_det%252Ford_det.xdo/run

PAYLOAD: <--Boundary

Content-Type: application/json

Content-Disposition: form-data; name=""ReportRequest""

{

""byPassCache"": true,

""attributeLocale"": ""en-US"",

""attributeFormat"": ""pdf"",

""parameterNameValues"": {

""listOfParamNameValues"": {

""item"": [

{

""name"": ""PM_order_no"",

""values"": [

{""item"": ""@FILTER_1@""}

]

}

]

}

}

}

--Boundary-->

FILTER_VIEW_1: NB_V_ORDER_FILTER_LOV

FILTER_LABEL_1: Order No

STATUS: A

OUTPUT_FILE_NAME: Order_Detail.pdf

Operations

This section describes Report operations.

Integration by Module

Figure 26-2 Reports Integration by Module


Reports Integration by Module
STEP DESCRIPTION
1 Get Report from BI Publisher Rest Service.