tm1Ui.DimensionElements function returning undefined for some users


We have an issue where on some users machines using Chrome the tm1Ui.DimensionElements() is returning undefined. It works correctly in IE though. It seems to be happening on windows machines with Chrome, Macs using Chrome look like they are OK.

When looking in Chrome debugger, it looks like it is trying to make a GET call instead of a POST and returning a 400 error.

Here is the code we see it happening with.

$tm1Ui.dimensionElements($, "Period", "Last,FiscalYear", "Forecast Current By Month", "", "", "", false, false)
      return Promise.all([periodData, 
        $tm1Ui.dimensionElements($, "Period", "", "", "{[Period].[" + periodData[0].Attributes.FiscalYear + "].Children}", "", "", false, false),
        $tm1Ui.dimensionElements($, "Period", "","", "{LastPeriods(12,[Period].["+ periodData[0].Attributes.Last + "])}", "", "", false, false)
      $ = periodYearData[0];
      $scope.yearDetails.FirstQtrName = $[0].Parents[0].Name;
      $scope.yearDetails.SecondQtrName = $[3].Parents[0].Name;
      $scope.yearDetails.ThirdQtrName = $[7].Parents[0].Name;
      $scope.yearDetails.FourthQtrName = $[10].Parents[0].Name;
      if($scope.yearDetails.FirstQtrName.substring(1,2) == "Q1")
        $scope.yearDetails.PriorFirstQtrVersion = "Forecast Working";     
      if($scope.yearDetails.FirstQtrName.substring(1,2) == "Q1" || $scope.yearDetails.FirstQtrName.substring(1,2) == "Q2")
        $scope.yearDetails.PriorSecondQtrVersion = "Forecast Working";     
      if($scope.yearDetails.FirstQtrName.substring(1,2) == "Q4")
        $scope.yearDetails.PriorThirdQtrVersion = "Forecast Working";     
      $scope.yearDetails.PriorYearName = $[0].Attributes.FiscalYear;
      $scope.yearDetails.PriorMonthNames = periodYearData[2];
      $scope.yearDetails.PriorYearNames[0] = periodYearData[1][0].Name;
      $scope.yearDetails.PriorYearNames[1] = periodYearData[1][1].Name;
      $scope.yearDetails.PriorYearNames[2] = periodYearData[1][2].Name;
      $scope.yearDetails.PriorYearNames[3] = periodYearData[1][3].Name;
      $scope.yearDetails.PriorYearNames[4] = $scope.yearDetails.PriorYearName;
      $scope.yearDetails.PriorFirstQtrName = periodYearData[1][0].Name;
      $scope.yearDetails.PriorSecondQtrName = periodYearData[1][1].Name;
      $scope.yearDetails.PriorThirdQtrName = periodYearData[1][2].Name;
      $scope.yearDetails.PriorFourthQtrName = periodYearData[1][3].Name;


Hi @chet_watkins,

Which of the requests fired a GET request? Can you check the details?

Next, if you fire it without using Promise.all, does it work?

Also, by returning undefined, is it for the 3 requests?



I had the problem before adding the promise.all. I added the promise.all after doing some reasearch on serializing promises and best practices on trying to run code off of results obtained.

I can get the get request specifics tomorrow for you. I have a Mac and can’t recreate the issue on my machine.

It’s the first request. The second request needs the first ones data.


Is there an email I can send the screenshots we took to? I would prefer not posting them in a public forum.



Hi @chet_watkins,

Check also the application.logs file and see what is the actual error.