Enable the Branch Out Link - Intergraph Smart Materials - Version 10.2 - Installation & Upgrade - Hexagon

Intergraph Smart Materials Installation (10.2)

Language
English
Product
Intergraph Smart Materials
Subproduct
Classic
Search by Category
Installation & Upgrade
Smart Materials/Smart Reference Data Version
10.2

You can enable links on the Portal home page and on the Inquiries page that can be used to execute your own program from the Portal.

PortIns11

Whether these links are enabled and displayed is controlled by the CIPs M_PCK_COMPANY_CUSTOM.CHECK_ESUPP_FOR_BRANCH for the Portal home page and M_PCK_QUOTE_CUSTOM.CHECK_ESUPP_FOR_BRANCH_P3027 for the Inquiries page.

The following is the CHECK_ESUPP_FOR_BRANCH function:

FUNCTION check_esupp_for_branch (p_sup_id m_suppliers.sup_id%TYPE)

RETURN VARCHAR2

IS

BEGIN

RETURN 'Y';

END check_esupp_for_branch;

The following is the CHECK_ESUPP_FOR_BRANCH_P3027 function:

FUNCTION check_esupp_for_branch_P3027 (p_sup_id m_suppliers.sup_id%TYPE)

RETURN VARCHAR2

IS

v_ret VARCHAR2(1) := 'Y';

BEGIN

-- Get the project default for "enable to branch to an application"

SELECT m_pck_pd_zp.zp_br_app

INTO v_ret

FROM dual;

-- Add anymore logic to define the return value...

RETURN v_ret;

END check_esupp_for_branch_P3027;

Use the project default ZP_BR_APP to enable the Branch Out To link on the Inquiries page.

If you click the link, the JavaScript BranchOut.js is executed. You can find this script in the <your_install_folder> \Smart Materials Portal 2020\CustomerJS folder.

Script

The script delivered with the software is displayed below:

function branchOut(params) {

var supId = params[0];

var inqId = params[1];

var qsId = params[2];

var usrId = params[3];

var form = params[4];

alert("JavaScript function branchOut beeing called\n\n" +

"supId: " + supId + "\n" +

"inqId: " + inqId + "\n" +

"qsId: " + qsId + "\n" +

"usrId: " + usrId + "\n" +

"form: " + form);

}

The function parameters are:

Params[0] – supplier ID

Params[1] – inquiry ID

Params[2] – quote summary ID

Params[3] – user ID

Params[4] – calling form

The sample function displays a message box as shown below:

24-05-2013 18-14-14

Implement your own coding to run when using the Branch Out To links.