Visual Builder

Get Involved. Join the Conversation.

Posts

  • Shakila Murugan
    How to Generate PDF in Oracle VBCS?135.0
    Topic posted September 8, 2019 by Shakila MuruganBronze Medal: 1,250+ Points, tagged Action Flows, Business Objects, Custom Code, JET, UI 
    Title:
    How to Generate PDF in Oracle VBCS?
    Content:
    Hi Team
     
    I need to generate PDF file in VBCS.
     
    I have tried that in Oracle JET. In JET i have added library in main.js file
     
     'pdfmake': 'libs/Pdf/pdfmake',
        'vfs_fonts': 'libs/Pdf/vfs_fonts',
     
    and also extra 3 js files in src folder.
    It's worked fine in JET.
     
    Is this approach will work in VBCS?
    Is there any feature to add library in VBCS?
    Is there any other option available in VBCS to generate PDF? or i need to add pdfmaker library in vbcs to achieve this?
     
    Help me to solve this.
     
    Thanks
    Shakila Murugan
    Version:
    19.1.3
  • Venkata Thota
    How to call ICS (OIC) web service in VBCS95.0
    Topic posted June 27, 2018 by Venkata ThotaBlue Ribbon: 750+ Points, tagged Action Flows, Business Objects, Custom Code, Layout, REST, Security, Web 
    Title:
    How to call ICS (OIC) web service in VBCS
    Summary:
    Click button in VBCS triggers cloud integration wsdl with input parameter
    Content:

    Hi All

    My requirement is like below

    1) in VBCS (Classic Application) page, I have 3 components 1. Text Filed 2. Button 3. Text area.

    2) in Text Field I enter AccountId and press button. After that it will invoke ICS webservice (WSDL url) with AccountId from Text Field.

    3) Response of webservice display in Text Area .

     

    Uploaded images and sample JS code for reference.

    PS: VBCS and ICS are at same server in OIC.

    Please suggest the solution. It is very basic requirement but I didn't find any solution for this.

    Thanks in advance.

     

    Venkat..

    Image:
    Code Snippet:
  • Stiven Oliveira Bezerra
    Offline Post VBCS with Business Object115.0
    Topic posted November 25, 2019 by Stiven Oliveira BezerraBlue Ribbon: 750+ Points, tagged Business Objects, JET, Mobile, REST 
    Title:
    Offline Post VBCS with Business Object
    Content:

    Hi i need to do a Get and Post with offline service, i follow some steps for this post here, https://blogs.oracle.com/shay/adding-offline-capabilities-to-an-oracle-visual-builder-app. But my Post doesn't work, and i'm try to do this for Mobile VBCS. This my code: 

    define([
        'vbsw/helpers/serviceWorkerHelpers',
        'persist/persistenceManager',
        'persist/defaultResponseProxy',
        'persist/persistenceUtils',
        'persist/fetchStrategies',
        'persist/impl/logger'
      ],
      function(ServiceWorkerHelpers, PersistenceManager, DefaultResponseProxy,
        PersistenceUtils, FetchStrategies, Logger) {
        'use strict';

        function AppModule() {}

        function OfflineHandler() {

          Logger.option('level', Logger.LEVEL_LOG);
          Logger.option('writer', console);

          var options = {

            requestHandlerOverride: {
              handlePost: handlePost
            },
            fetchStrategy: FetchStrategies.getCacheIfOfflineStrategy({
              backgroundFetch: 'disabled'
            })
          };
          this._responseProxy = DefaultResponseProxy.getResponseProxy(options);
        }

        OfflineHandler.prototype.handleRequest = function(request, scope) {

          console.log('OfflineHandler.handleRequest() url = ' + request.url +
            ' cache = ' + request.cache +
            ' mode = ' + request.mode);

          if (request.url.match(
              'https://devpoc-timtoa.integration.ocp.oraclecloud.com:443/ic/builder/design/yb/1.2.1/resources/data/ServiceOrderLineReview'
            )) {

            return this._responseProxy.processRequest(request);
          }
          return PersistenceManager.browserFetch(request);
        };

        OfflineHandler.prototype.beforeSyncRequestListener = function(event) {
          return Promise.resolve();
        };
        OfflineHandler.prototype.afterSyncRequestListener = function(event) {
          return Promise.resolve();
        };
        AppModule.prototype.createOfflineHandler = function() {
          return Promise.resolve(new OfflineHandler());
        };
        AppModule.prototype.isOnline = function() {
          return ServiceWorkerHelpers.isOnline();
        };
        AppModule.prototype.forceOffline = function(flag) {
          return ServiceWorkerHelpers.forceOffline(flag).then(function() {
        
            if (!flag) {
              return ServiceWorkerHelpers.syncOfflineData();
            }
            return Promise.resolve();

          }).catch(function(error) {
            console.error(error);
          });
        };
        AppModule.prototype.dataSynch = function() {
          return ServiceWorkerHelpers.syncOfflineData();
        };

        // custom implementation to handle the POST request
        var handlePost = function(request) {
          if (ServiceWorkerHelpers.isOnline()) {}

          return PersistenceUtils.requestToJSON(request).then(function(
            requestData) {
            console.log('Inside PersistenceUtils');
            console.log(requestData);
            requestData.status = 202;
            requestData.statusText = 'OK';
            requestData.headers['content-type'] = 'application/json';
            requestData.headers['x-oracle-jscpt-cache-expiration-date'] =
              '';

            // if the request contains an ETag then we have to generate a new one
            var ifMatch = requestData.headers['if-match'];
            var ifNoneMatch = requestData.headers['if-none-match'];

            if (ifMatch || ifNoneMatch) {
              var randomInt = Math.floor(Math.random() * 1000000);
              requestData.headers['etag'] = (Date.now() + randomInt).toString();
              requestData.headers['x-oracle-jscpt-etag-generated'] =
                requestData.headers['etag'];
              delete requestData.headers['if-match'];
              delete requestData.headers['if-none-match'];
            }
            return PersistenceUtils.responseFromJSON(requestData);
          });
        };

        AppModule.prototype.hideSpinner = function() {
          // tear down the spinner screen
          var spinner = document.getElementById('vb-spinner');
          if (spinner) {
            // if the spinner screen is not yet displayed, immediately remove it and return
            var computedStyle = window.getComputedStyle(spinner);
            var opacity = parseInt(computedStyle.getPropertyValue('opacity'),
              10);
            if (opacity < 0.1) {
              spinner.parentNode.removeChild(spinner);
              return;
            }

            var transEndFn = function() {
              if (spinner.parentNode) {
                spinner.parentNode.removeChild(spinner);
              }
              spinner.removeEventListener('transitionend', transEndFn);
            };
            spinner.addEventListener('transitionend', transEndFn, false);
            spinner.className += ' vb-spinner-reveal-trans';
          }
        };

        return AppModule;
      });

     

    Have something wrong? I need more things to work in Mobile? I'm using the Business Object.

  • Andy May-Coates
    How to handle multiple nested collections in Visual Builder...Answered135.0
    Topic posted November 18, 2019 by Andy May-CoatesBronze Trophy: 5,000+ Points, tagged Business Objects, Layout, REST 
    Title:
    How to handle multiple nested collections in Visual Builder add-in for Excel
    Summary:
    How to handle multiple nested collections in Visual Builder add-in for Excel
    Content:

    In the Oracle Visual Builder add-in for Excel, a form-over-table layout can be used to support parent-child business object relationships e.g. supplier and supplier site.

    However, we have a REST API where there are multiple nested child collections, and properties need to be supplied at each level to be of any use. For example:-

    https://***.oraclecloud.com/fscmRestApi/resources/11.13.18.05/financialProjectPlans

    This has several nested levels of child collections, and properties from each level need to be included to bulk update a financial project plan resource assignment. For example:-

    Project level detail would come from the top level "financialProjectPlans"
    Task and resource detail would come from the next level "ResourceAssignments"
    Currency and plan amount totals come from the next level "PlanningAmounts"
    Periodic plan amounts come from the lowest level "PlanAmountDetail"

    What we really need is a table layout containing properties from all four levels above, where parent properties would simply fill down/duplicate.

    On a related note, when we import the swagger for the above service, the plugin only shows the top three levels (see image below). This seems to be the case for other REST APIs. Is this a product limitation? Is there any workaround to this either?

    Any help greatly appreciated.

    Version:
    Oracle Visual Builder Add-in for Excel 2.0.0.20643
    Image:
    Document:
  • Deep Mandal
    Oracle VBCS Role Based Mail SendAnswered65.0
    Topic posted November 14, 2019 by Deep MandalGreen Ribbon: 100+ Points, tagged Action Flows, Business Objects, Custom Code, Groovy 
    Title:
    Oracle VBCS Role Based Mail Send
    Summary:
    Oracle VBCS Role Based Mail Send
    Content:

    In Oracle VBCS how can we send mail to the Users attached to particular VBCS Role.

    For Example:

    Suppose I have two Roles Creator and Approver. So, when users having "Creator" Role creates some record in VBCS BO then I want to send mail to the users having "Approver" role. How this business scenario can be achieved.

    Version:
    19.3.1.2
  • vijay.kekane
    Patch to custom Object created in SaaS failAnswered85.0
    Topic posted October 23, 2019 by vijay.kekane Red Ribbon: 250+ Points, tagged Business Objects, Custom Code, REST, SaaS Integration 
    Title:
    Patch to custom Object created in SaaS fail
    Summary:
    Patch operation fail
    Content:

    Hi There,

    We have custom object created in financial cloud. This object's row need to be updated when data changes in VBCS screen. I am getting error "[VB (ERROR), /vb/helpers/rest]: The response specifies content type application/json, but unable to parse response as JSON. Reading response as text SyntaxError: Unexpected token I in JSON at position 0".

    Patch operation work good from postman so patch is allowed and I have valid response. Same patch operation also work when setting up REST endpoint in VBCS. However it does not work when update screen is used to update actual row.

    I have created new data Type based on REST endpoint to get response from REST operation. I am not sure reason for above error.

    Version:
    19.3.1.2
    Code Snippet:
  • Shakila Murugan
    Business Object not getting updated?Answered125.0
    Topic posted August 27, 2019 by Shakila MuruganBronze Medal: 1,250+ Points, tagged Action Flows, Business Objects, Custom Code, UI, Validation 
    Title:
    Business Object not getting updated?
    Content:

    Hi all,

    I have created vbcs application and integrated it into fusion page.
    When i insert or update data in my application (after integrating my application into fusion)
     it's not getting reflected in my VBCS Business object.

    Do i need to add any anonymous access for this?

     

    Thanks

    Shakila Murugan

    Version:
    19.1.3
  • Stephen Bryant
    Using a URL (as opposed to a selected row event) and...Answered145.0
    Topic posted July 19, 2019 by Stephen BryantBronze Trophy: 5,000+ Points, tagged Action Flows, Business Objects, REST, UI, Web 
    Title:
    Using a URL (as opposed to a selected row event) and Passing parameters to filter the ADP
    Summary:
    click URL, pass parameters and filter an ADP
    Content:

    Hello again,

    I can certainly configure a selected-row event and pass parameters to filter an ADP and show records.

    Is it possible to do this with a link on say, a document number, and passing that document as a parameter to filter and ADP?

    The goal is to show document numbers with an underline indicating that they can be clicked to bring up the details of that document.  This works the traditional when using the select-row event but would like it as a url.

    Thanks,

    Steve

    Version:
    19.1.3
  • Stephen Bryant
    Is it possible to delete all records in a BO using a REST...Answered75.0
    Topic posted July 13, 2019 by Stephen BryantBronze Trophy: 5,000+ Points, tagged Action Flows, Business Objects, REST, SaaS Integration 
    Title:
    Is it possible to delete all records in a BO using a REST CALL?
    Summary:
    Similar to truncating a table in plsql
    Content:

    Hello,

    We have a requirement to truncate/delete all records in a Business Object and then re-poplulate with new records.

    Can we truncate (delete all records) a business object via one rest call?

    Thanks,

    Steve

    Version:
    19.1.3
  • Nisheeth Ranjan
    How to change the timezone in VBCS ApplicationAnswered45.0
    Topic posted June 10, 2019 by Nisheeth RanjanSilver Medal: 2,000+ Points, tagged Business Objects 
    Title:
    How to change the timezone in VBCS Application
    Content:

    Hi Experts,

    Our OIC instance is located in Aishburn data center. We have created a VBCS application which stores the data in Business objects. By default the date and time it stores in created and last updated field is in UTC timezone. Is there any option to change the default timezone so that the correct time can be stores in the Business Objects.

    Thanks,

    Nisheeth