Is it possible to have a select drop down inside of the AngularJS ng-grid?

后端 未结 4 975
广开言路
广开言路 2021-02-04 12:34

I have coded the following:

$scope.gridOptions = {
    data: \'myData\',
    enableCellEdit: true,
    multiSelect: false,
    columnDefs: [
        { field: \'I         


        
4条回答
  •  天涯浪人
    2021-02-04 13:27

    A more complete/tidier way to do this in ng-grid 2.x I've included in a plunker here: http://plnkr.co/edit/VABAEu?p=preview, leveraging content from another similar question on stackoverflow here: AngularJS and ng-grid - auto save data to the server after a cell was changed

    In summary, my format for the editable field template looks like so:

          $scope.statuses = {1: 'active', 2: 'inactive'};
          $scope.cellSelectEditableTemplate = '
                            
        
    提交评论

提交回复
热议问题