diff --git a/app.js b/app.js index 8c6b4ca..d129be0 100644 --- a/app.js +++ b/app.js @@ -30,6 +30,15 @@ define(function(require) { requests: {}, subscribe: {}, appFlags: { + common: { + outboundPrivacy: [ + 'default', + 'none', + 'number', + 'name', + 'full' + ] + }, global: {} }, diff --git a/i18n/en-US.json b/i18n/en-US.json index 7b5807c..ffca5e3 100644 --- a/i18n/en-US.json +++ b/i18n/en-US.json @@ -18,6 +18,20 @@ "vmboxes": "Voicemail Boxes" }, + "commonMisc": { + "outboundPrivacy": { + "label": "Caller-ID privacy", + "tooltip": "Determines what appears as Caller-ID for offnet outbound calls.", + "values": { + "default": "- Default -", + "none": "Hide nothing", + "number": "Hide number only", + "name": "Hide name only", + "full": "Hide name and number" + } + } + }, + "groups": { "addFromSpare": "Add from Spare Numbers", "add": "Add Group", @@ -507,15 +521,7 @@ "languageHelp": "This will change the language of the text displayed in the UI", "timezoneHelp": "This will set the Timezone used for this User's devices and Voicemail Box", "ringingHelp": "This will set the Ringing Timeout for this User and his Devices. For example, if you set it to 20, this user will be rung for 20 seconds before the system moves to his Voicemail Box", - "mainExtensionHelp": "This will define the Caller-ID used for this User for calls inside the system, as well as setting his Presence ID to that number", - "outbound_privacy": { - "type": "Caller-ID privacy ", - "default": "Default", - "none": "None", - "number": "Number", - "name": "Name", - "full": "Full" - } + "mainExtensionHelp": "This will define the Caller-ID used for this User for calls inside the system, as well as setting his Presence ID to that number" }, "delete": "Delete User", "errorCallerId": "Before configuring the Caller-ID of this user, you need to assign them a number", diff --git a/submodules/devices/devices.js b/submodules/devices/devices.js index fcc4067..e18a784 100644 --- a/submodules/devices/devices.js +++ b/submodules/devices/devices.js @@ -746,6 +746,12 @@ define(function(require) { var self = this, defaults = { extra: { + outboundPrivacy: _.map(self.appFlags.common.outboundPrivacy, function(strategy) { + return { + key: strategy, + value: self.i18n.active().commonMisc.outboundPrivacy.values[strategy] + }; + }), hasE911Numbers: !_.isEmpty(data.e911Numbers), e911Numbers: data.e911Numbers, restrictions: data.listClassifiers, diff --git a/submodules/users/users.css b/submodules/users/users.css index 38a9584..f5ee253 100644 --- a/submodules/users/users.css +++ b/submodules/users/users.css @@ -348,11 +348,6 @@ cursor: default !important; } -#users_container .detail-user .row-fields .presence-id-select { - margin-left: 10px; - width: 72px; -} - #users_container .detail-user .row-fields .timeout-edit { margin-left: 50px; } @@ -371,6 +366,14 @@ display: block; } +#users_container .detail-user .row-fields .inline-block { + display: inline-block; +} + +#users_container .detail-user .row-fields .inline-block select { + margin: 0 7px; +} + #users_container .detail-user .email-border { margin-bottom: 10px; border: 2px dotted transparent; diff --git a/submodules/users/users.js b/submodules/users/users.js index ec5c74c..41ae67b 100644 --- a/submodules/users/users.js +++ b/submodules/users/users.js @@ -238,7 +238,13 @@ define(function(require) { iconColor: 'monster-red', title: self.i18n.active().users.do_not_disturb.title } - } + }, + outboundPrivacy: _.map(self.appFlags.common.outboundPrivacy, function(item) { + return { + key: item, + value: self.i18n.active().commonMisc.outboundPrivacy.values[item] + }; + }) }; if (!('extra' in dataUser)) { diff --git a/views/devices-sip_device.html b/views/devices-sip_device.html index 99c99a4..809989a 100644 --- a/views/devices-sip_device.html +++ b/views/devices-sip_device.html @@ -223,16 +223,21 @@