Browse Source

UI-3111: Added user and device privacy options (#63)

* Adeed device privacy options

* Added user privacy options
4.3
sergey-safarov 8 years ago
committed by Joris Tirado
parent
commit
17dbe82cb5
6 changed files with 70 additions and 1 deletions
  1. +17
    -1
      i18n/en-US.json
  2. +8
    -0
      submodules/devices/devices.js
  3. +8
    -0
      submodules/users/users.js
  4. +13
    -0
      views/devices-sip_device.html
  5. +13
    -0
      views/devices-softphone.html
  6. +11
    -0
      views/users-name.html

+ 17
- 1
i18n/en-US.json View File

@ -200,6 +200,14 @@
"srtp": "SRTP",
"zrtp": "ZRTP"
},
"outbound_privacy": {
"type": "Caller-ID privacy ",
"default": "Default",
"none": "None",
"number": "Number",
"name": "Name",
"full": "Full"
},
"__comment": "UI-1119: Adding ignore_complete_elsewhere",
"__version": "3.19",
"ignoreCompletedElsewhere": {
@ -499,7 +507,15 @@
"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"
"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"
}
},
"delete": "Delete User",
"errorCallerId": "Before configuring the Caller-ID of this user, you need to assign them a number",


+ 8
- 0
submodules/devices/devices.js View File

@ -719,6 +719,14 @@ define(function(require) {
delete mergedData.media.fax.option;
}
if (mergedData.hasOwnProperty('caller_id_options') && mergedData.caller_id_options.hasOwnProperty('outbound_privacy') && mergedData.caller_id_options.outbound_privacy === 'default') {
delete mergedData.caller_id_options.outbound_privacy;
if (_.isEmpty(mergedData.caller_id_options)) {
delete mergedData.caller_id_options;
}
}
if (mergedData.hasOwnProperty('caller_id') && mergedData.caller_id.hasOwnProperty('emergency') && mergedData.caller_id.emergency.hasOwnProperty('number') && mergedData.caller_id.emergency.number === '') {
delete mergedData.caller_id.emergency.number;


+ 8
- 0
submodules/users/users.js View File

@ -2919,6 +2919,14 @@ define(function(require) {
userData.caller_id.internal.number = userData.presence_id + '';
}
if (userData.hasOwnProperty('caller_id_options') && userData.caller_id_options.hasOwnProperty('outbound_privacy') && userData.caller_id_options.outbound_privacy === 'default') {
delete userData.caller_id_options.outbound_privacy;
if (_.isEmpty(userData.caller_id_options)) {
delete userData.caller_id_options;
}
}
if (userData.timezone === 'inherit') {
delete userData.timezone;
}


+ 13
- 0
views/devices-sip_device.html View File

@ -222,6 +222,19 @@
</label>
</div>
<div class="control-group">
<label class="control-label checkbox">
<span>{{ i18n.devices.popupSettings.miscellaneous.outbound_privacy.type }}</span>
<select class="input-small" name="caller_id_options.outbound_privacy">
<option value="default"{{#compare caller_id_options.outbound_privacy "===" "default"}} selected{{/compare}}>{{ i18n.devices.popupSettings.miscellaneous.outbound_privacy.default }}</option>
<option value="none"{{#compare caller_id_options.outbound_privacy "===" "none"}} selected{{/compare}}>{{ i18n.devices.popupSettings.miscellaneous.outbound_privacy.none }}</option>
<option value="number"{{#compare caller_id_options.outbound_privacy "===" "number"}} selected{{/compare}}>{{ i18n.devices.popupSettings.miscellaneous.outbound_privacy.number }}</option>
<option value="name"{{#compare caller_id_options.outbound_privacy "===" "name"}} selected{{/compare}}>{{ i18n.devices.popupSettings.miscellaneous.outbound_privacy.name }}</option>
<option value="full"{{#compare caller_id_options.outbound_privacy "===" "full"}} selected{{/compare}}>{{ i18n.devices.popupSettings.miscellaneous.outbound_privacy.full }}</option>
</select>
</label>
</div>
<div class="rtp-line clearfix">
<div class="control-group">
<label class="control-label checkbox">


+ 13
- 0
views/devices-softphone.html View File

@ -179,6 +179,19 @@
</label>
</div>
<div class="control-group">
<label class="control-label checkbox">
<span>{{ i18n.devices.popupSettings.miscellaneous.outbound_privacy.type }}</span>
<select class="input-small" name="caller_id_options.outbound_privacy">
<option value="default"{{#compare caller_id_options.outbound_privacy "===" "default"}} selected{{/compare}}>{{ i18n.devices.popupSettings.miscellaneous.outbound_privacy.default }}</option>
<option value="none"{{#compare caller_id_options.outbound_privacy "===" "none"}} selected{{/compare}}>{{ i18n.devices.popupSettings.miscellaneous.outbound_privacy.none }}</option>
<option value="number"{{#compare caller_id_options.outbound_privacy "===" "number"}} selected{{/compare}}>{{ i18n.devices.popupSettings.miscellaneous.outbound_privacy.number }}</option>
<option value="name"{{#compare caller_id_options.outbound_privacy "===" "name"}} selected{{/compare}}>{{ i18n.devices.popupSettings.miscellaneous.outbound_privacy.name }}</option>
<option value="full"{{#compare caller_id_options.outbound_privacy "===" "full"}} selected{{/compare}}>{{ i18n.devices.popupSettings.miscellaneous.outbound_privacy.full }}</option>
</select>
</label>
</div>
<div class="control-group">
<label class="control-label checkbox">
{{#monsterCheckbox i18n.devices.popupSettings.miscellaneous.mediaWebrtc.label }}


+ 11
- 0
views/users-name.html View File

@ -117,6 +117,17 @@
{{/select}}
</select>
</div>
<div class="row-fields">
<lavel class="fix-left">{{ i18n.users.editionForm.outbound_privacy.type }}</label>
<select id="privacy_type" name="caller_id_options.outbound_privacy">
<option value="default"{{#compare caller_id_options.outbound_privacy "===" "default"}} selected{{/compare}}>{{ i18n.users.editionForm.outbound_privacy.default }}</option>
<option value="none"{{#compare caller_id_options.outbound_privacy "===" "none"}} selected{{/compare}}>{{ i18n.users.editionForm.outbound_privacy.none }}</option>
<option value="number"{{#compare caller_id_options.outbound_privacy "===" "number"}} selected{{/compare}}>{{ i18n.users.editionForm.outbound_privacy.number }}</option>
<option value="name"{{#compare caller_id_options.outbound_privacy "===" "name"}} selected{{/compare}}>{{ i18n.users.editionForm.outbound_privacy.name }}</option>
<option value="full"{{#compare caller_id_options.outbound_privacy "===" "full"}} selected{{/compare}}>{{ i18n.users.editionForm.outbound_privacy.full }}</option>
</select>
</div>
</div>
<!--<div class="advanced-fields content-centered span3">
<a id="resend_instructions" href="javascript:void(0)">{{ i18n.users.resendInstructions }}</a>


Loading…
Cancel
Save