在angular-xeditable

时间:2015-09-02 03:07:37

标签: angularjs x-editable

在我的情况下,我使用http://vitalets.github.io/angular-xeditable/#editable-table来编辑整个表,如果表有两行或更多行并单击编辑并更新了一些值(文本值),则在点击事件上我希望得到那些更新的值在控制器中。你能给些建议么。 http://jsfiddle.net/0amredgj/3/

var app = angular.module("app", ["xeditable"]);
 app.run(function(editableOptions) {
     editableOptions.theme = 'bs3';
});

app.controller('Ctrl', function($scope) {
$scope.user = {
name: 'awesome user',
   name2: 'awesome222 user',
   name3: 'awesome user',
   name4: 'awesome222 user'
};

 $scope.result = function(data){
 alert($scope.user.name)
  alert($scope.user.name2)
   alert($scope.user.name3)
    alert($scope.user.name4)
 }
});

1 个答案:

答案 0 :(得分:0)

试试这个小提琴:

<input ... e-name="username">

fiddle