mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-06-23 10:54:17 +00:00
(js) Fix handling of contact categories
This commit is contained in:
@@ -20,6 +20,7 @@
|
||||
vm.allAddressTypes = Card.$ADDRESS_TYPES;
|
||||
vm.categories = {};
|
||||
vm.userFilterResults = [];
|
||||
vm.transformCategory = transformCategory;
|
||||
vm.addOrgUnit = addOrgUnit;
|
||||
vm.addBirthday = addBirthday;
|
||||
vm.addScreenName = addScreenName;
|
||||
@@ -38,6 +39,12 @@
|
||||
vm.toggleRawSource = toggleRawSource;
|
||||
vm.showRawSource = false;
|
||||
|
||||
function transformCategory(input) {
|
||||
if (angular.isString(input))
|
||||
return { value: input };
|
||||
else
|
||||
return input;
|
||||
}
|
||||
function addOrgUnit() {
|
||||
var i = vm.card.$addOrgUnit('');
|
||||
focus('orgUnit_' + i);
|
||||
|
||||
Reference in New Issue
Block a user