Comments

  • Vinod Kumar Kv

    Please find below the detailed outline for business scenario:
    1) We have created a normal business object in VBCS. This business object supports (POST, GET, PATCH and other methods by default)
    2) Now we have a button on VBCS page. On click of this button we are calling an action chain.
    3) In this action chain we want to query data from VBCS business object with filter as (CID=someObjectID and STATUS='PROD')
    4) Whatever data will come from this query we want to use some of the fields from that data on popup form.

    In short before opening the popup window we want to query data from one business object with filter and use it in popup form.

     

  • Vinod Kumar Kv

    Thanks

    Is there a way to call ServiceDataProviders and ArrayDataProviders in action chain?

  • Vinod Kumar Kv

    Thanks Rod,

    Yes, your understanding is right. 

     

  • Vinod Kumar Kv

    Thanks Thomas,

    Yes gl-matrix-min has been rename to world-matrix.Below is the log details

     

    log.js:298 ðŸ [VB 10:52:16 (INFO), /vb/stateManagement/page]: Page 'shell' of flow 'app' LOADED.  (completed in 287 ms)
    /ic/builder/design/extimport/1.0/preview/webApps/myapp/webApps/myapp/world-matrix.js:1 Failed to load resource: the server responded with a status of 404 (Not Found)
    (index):1 Refused to execute script from 'https://paradisevbcsvb-gnaveen.aucom-east-1.oraclecloud.com/ic/builder/design/extimport/1.0/preview/webApps/myapp/webApps/myapp/world-matrix.js' because its MIME type ('application/problem+json') is not executable, and strict MIME type checking is enabled.
    log.js:298 ðŸ [VB 10:52:17 (INFO), /vb/stateManagement/page]: Page 'main-start' of flow 'main' LOADED.  (completed in 592 ms)

     

  • Vinod Kumar Kv

    Hello Shay,

    We are trying to replicate the same steps as mentioned in the below blog.We are getting an error.

    https://blogs.oracle.com/vbcs/importing-and-using-javascript-libraries-in-your-visual-builder-custom-code

     

  • Vinod Kumar Kv

    Thanks Shay,

    We have created a buiness rule (before insert trigger) on one object in VBCS. As per rule if cost > 100 i need to send email to user and update the approval value to true. But I am getting below mentioned error.

    ERROR on UI:
    Error: Exception in expression "Expense" trigger "BeforeInsert_Rule_1" : com.oracle.breeze.ramp.helpers.Email.EmailException : java.lang.NullPointerException
    at "Expense" trigger "BeforeInsert_Rule_1" line 23

    (Code: 400)

    ERROR LOGS:
    Aug 09 2018 11:36:58 AM    Trigger started: Is expensive create, business object: Expense, event: BeforeInsert
    Aug 09 2018 11:36:58 AM    Trigger condition (cost > 100) is true
    Aug 09 2018 11:36:59 AM    Trigger ended: Is expensive create
    Aug 09 2018 11:36:59 AM    JBO-25183: Exception in expression "Expense" trigger "BeforeInsert_Rule_1" : com.oracle.breeze.ramp.helpers.Email.EmailException : java.lang.NullPointerException

    Trigger code:

    println 'Trigger started: Is expensive create, business object: Expense, event: BeforeInsert';
    try {

        // Execute Conditionally Criterion (Execute Conditionally)
        def codeCriterion_1 = (cost > 100);
        println "Trigger condition (cost > 100) is " + codeCriterion_1;
        if (codeCriterion_1) {
            // Action Group (Action Group)
            approval = true;

            def recipients = 'vinod@techkasetti.com';
            def sender = 'vinod@techkasetti.com';
            def variables = [:];
            variables["Parameter1"] = 'Vinod';
            variables["Parameter2"] = 'Kumar';
            variables["Parameter3"] = 'August 3, 2018';
            variables["Parameter4"] = '300';

            def subject = "Expense Report For [[Parameter1]]";
            def body = "<p>Hi [[Parameter2]],</p><p>Big expense has happened on [[Parameter3]] with value [[Parameter4]].</p><p>Thanks,</p><p>Team TechKasetti</p>";
            com.oracle.breeze.ramp.helpers.Email.send(recipients, sender, subject, body, variables);
     

           return;
        }

    } finally {

        // Trigger End
        println 'Trigger ended: Is expensive create';

    }