Hi,
We are building an application with Angular JS and Webix as strict specification :).
How to invoke function (say “accountSelected” ) marked in config initialization which is defined in angular scope of same controller,
HTML :
<html xmlns:ng="http://angularjs.org" ng-app="accountSearchApp">
<body ng-controller="searchController">
<div webix-ui="datatable_config" ></div>
</body>
</html>
SCRIPT :
var accountSearchApp = angular.module('accountSearchApp', [ "webix" ]);
// defining controller
accountSearchApp
.controller("searchController", function($scope){
$scope.datatable_config = {
id: "dt_01",
view:"datatable",
columns:[
{id:"edit", header:["Choose", {
content:"textFilter", placeholder:"Type here to filter the grid",
compare:oneForAll, colspan:2
}], width:200, template:"<a href='javascript:void(0)' onclick='accountSelected()'>Select</a>"
},
{ id:"AccountName", header:["Account Name",null], width:300, sort:"string"},
],
data: arryObj
};
$scope.accountSelected = function(){
console.log(" SUCCESS ");
}
});
Am able to invoke when function accountSelected definition is placed outside of controller scope, I need it working with func defined inside controller scope.
Thanks