insert ng-click event into ng-grid

前端 未结 3 1621
暖寄归人
暖寄归人 2020-12-15 11:14

i want to do something that i don\'t know if it is possible

HTML


    
    

        
3条回答
  •  無奈伤痛
    2020-12-15 11:53

    The document on their github site is really old.

    here is a link to the right page for this problem. http://ui-grid.info/docs/#/tutorial/305_appScope

            yourCtrl.gridOptions = {
                enableFiltering: true,
                enableHiding : false,
                enableSorting: true,
                appScopeProvider : yourCtrl,
                rowTemplate: '
    ', }; yourCtrl.doSomething = function(row) { alert("lala"); }

    yes, somehow

    ng-click="grid.appScope.doSomething"
    

    won't work

提交回复
热议问题