UINetworkC3Request visible in network tab

#1

I have a custom function on UI that performs a call to UINetworkC3Request.init …

  1. Should I see the call in the network tab?
  2. In the console I have an error that I think belong to the “success” - is this one the reason I do not see any call in network tab?
  3. to debug - can I run the UINetworkC3Request from console ? if yes how do I have to set the environment attribute?

VM6698 UIHelper.js:2653 Uncaught TypeError: Cannot read property ‘forEach’ of undefined

var query =   UINetworkC3Request.init({
        environment: self.get('environment'),
        autoExecute: true,
        c3type: 'ServicePoint',
        c3function: 'fetch',
        async: false,
        responseSelector: 'objs',
        c3arguments: {
            spec:{
            filter:"services.serviceAgreement.account.toRole.party.residentialTaxNumber=='"+residentialTax+"' || services.serviceAgreement.account.toRole.party.commercialTaxNumber=='"+value+"'" 
            }
        },
        success: function (xhr) {
            var fetchResults = xhr.response.get('data');
            fetchResults.forEach(function (fetchResult) {
                count = count + 1;
            });

           
        },
        failure: function (xhr) {
            var count =0;
            }

      });
0 Likes