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 am trying to reuse Member Group Picker of umbraco.
but when I submit form i get $scope.myMemberGroupPicker is undefined.
myview.html
<div ng-controller="myContentController"> <umb-control-group class="umb-membergrouppicker" label="Member Group"> <umb-editor model="myMemberGroupPicker" prevent-default=""></umb-editor> </umb-control-group> </div>
myview.controller.js
function myContentController($scope, $routeParams, angularHelper) {
$scope.myMemberGroupPicker = { view: 'memberGroupPicker', value: $scope.model.question.memberGroup, config: $.extend({}, $scope.config.memberGroupPicker) }; $scope.$watch('myMemberGroupPicker', function (scope) { if ($scope.myMemberGroupPicker != undefined) { $scope.model.question.memberGroup = $scope.myMemberGroupPicker.value; } }, true); $scope.save = function () { var group = $scope.myMemberGroupPicker.value; //undefined }
}
angular.module("umbraco").controller("myContentController", myContentController);
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
Reuse Member Group Picker on selection change event handler not working
I am trying to reuse Member Group Picker of umbraco.
but when I submit form i get $scope.myMemberGroupPicker is undefined.
myview.html
myview.controller.js
function myContentController($scope, $routeParams, angularHelper) {
}
angular.module("umbraco").controller("myContentController", myContentController);
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.