mirror of https://github.com/nextcloud/contacts
Reset selection after adding a field
This commit is contained in:
parent
b850611356
commit
30db794ac5
|
@ -59,6 +59,7 @@ app.controller('contactdetailsCtrl', ['ContactService', 'AddressBookService', 'v
|
|||
var idx = ctrl.contact.addProperty(field, {value: defaultValue});
|
||||
ctrl.singleProperties = ctrl.contact.getSingleProperties();
|
||||
ctrl.focus = field;
|
||||
$scope.field = '';
|
||||
};
|
||||
|
||||
ctrl.deleteField = function (field, index) {
|
||||
|
|
|
@ -279,6 +279,7 @@ app.controller('contactdetailsCtrl', ['ContactService', 'AddressBookService', 'v
|
|||
var idx = ctrl.contact.addProperty(field, {value: defaultValue});
|
||||
ctrl.singleProperties = ctrl.contact.getSingleProperties();
|
||||
ctrl.focus = field;
|
||||
$scope.field = '';
|
||||
};
|
||||
|
||||
ctrl.deleteField = function (field, index) {
|
||||
|
@ -486,6 +487,23 @@ app.directive('detailsitem', ['$compile', function($compile) {
|
|||
};
|
||||
}]);
|
||||
|
||||
app.controller('groupCtrl', function() {
|
||||
var ctrl = this;
|
||||
});
|
||||
|
||||
app.directive('group', function() {
|
||||
return {
|
||||
restrict: 'A', // has to be an attribute to work with core css
|
||||
scope: {},
|
||||
controller: 'groupCtrl',
|
||||
controllerAs: 'ctrl',
|
||||
bindToController: {
|
||||
group: "=data"
|
||||
},
|
||||
templateUrl: OC.linkTo('contacts', 'templates/group.html')
|
||||
};
|
||||
});
|
||||
|
||||
app.controller('grouplistCtrl', ['$scope', 'ContactService', '$routeParams', function($scope, ContactService, $routeParams) {
|
||||
|
||||
$scope.groups = [t('contacts', 'All contacts')];
|
||||
|
@ -511,23 +529,6 @@ app.directive('grouplist', function() {
|
|||
};
|
||||
});
|
||||
|
||||
app.controller('groupCtrl', function() {
|
||||
var ctrl = this;
|
||||
});
|
||||
|
||||
app.directive('group', function() {
|
||||
return {
|
||||
restrict: 'A', // has to be an attribute to work with core css
|
||||
scope: {},
|
||||
controller: 'groupCtrl',
|
||||
controllerAs: 'ctrl',
|
||||
bindToController: {
|
||||
group: "=data"
|
||||
},
|
||||
templateUrl: OC.linkTo('contacts', 'templates/group.html')
|
||||
};
|
||||
});
|
||||
|
||||
app.directive('telModel', function(){
|
||||
return{
|
||||
restrict: 'A',
|
||||
|
|
Loading…
Reference in New Issue