Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
I created a custom property editor but I need to update the $scope.model every 5 seconds.
I tried...
angular.module('umbraco').controller('ListController', function ($scope, $log, $timeout, $interval, $filter, editorState, listResource) { $interval(function () { listResource.getList().then(function (response) { $scope.mylist = response; }); }, 5000); });
The 'listResource.getList()' function works fine but when I wrap it in a $interval it doesn't seem to work. I'm getting an Angular error:
Error: Unknown provider: $intervalProvider <- $interval
Anyone know how to accomplish this?
I believe I solved this issue.
The Umbraco version I'm running is 7.4.3 which runs angular 1.1.5 which does NOT support $interval. I had to use create a function with calls itself every X seconds using $timeout instead.
Hope this helps someone.
is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.
Continue discussion
Custom Property Editor v7 - Update $scope.model every X seconds
I created a custom property editor but I need to update the $scope.model every 5 seconds.
I tried...
The 'listResource.getList()' function works fine but when I wrap it in a $interval it doesn't seem to work. I'm getting an Angular error:
Anyone know how to accomplish this?
I believe I solved this issue.
The Umbraco version I'm running is 7.4.3 which runs angular 1.1.5 which does NOT support $interval. I had to use create a function with calls itself every X seconds using $timeout instead.
Hope this helps someone.
is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.