Add shared_buddylist_visibility and display_name.

The former is used to control whether to export a subscriber to
the customer's shared XMPP roster.
The latter is used to set the XMPP name for a contact and can be
used in outbound_from_display.
agranig/pref-label
Andreas Granig 13 years ago
parent 24750af002
commit a5555d27c2

@ -0,0 +1,16 @@
SET AUTOCOMMIT=0;
USE provisioning;
DELETE FROM voip_preferences WHERE attribute = 'shared_buddylist_visibility';
DELETE FROM voip_preference_groups WHERE name = 'XMPP Settings';
DELETE FROM voip_preferences WHERE attribute = 'display_name';
SELECT id INTO @out_id FROM voip_preferences WHERE attribute = 'outbound_from_display';
DELETE FROM voip_preferences_enum WHERE preference_id = @out_id AND value = 'np_display';
UPDATE voip_usr_preferences SET value = 'npn' WHERE attribute_id = @out_id AND value = 'np_display';
UPDATE voip_dom_preferences SET value = 'npn' WHERE attribute_id = @out_id AND value = 'np_display';
UPDATE voip_peer_preferences SET value = 'npn' WHERE attribute_id = @out_id AND value = 'np_display';
COMMIT;

@ -0,0 +1,24 @@
SET AUTOCOMMIT=0;
USE provisioning;
INSERT INTO voip_preference_groups (name) values ('XMPP Settings');
SELECT LAST_INSERT_ID() INTO @xmpp_id;
SELECT id INTO @num_id FROM voip_preference_groups WHERE name = 'Number Manipulations';
INSERT INTO voip_preferences
(voip_preference_groups_id, attribute, type, usr_pref, dom_pref, peer_pref,
internal, data_type, max_occur, description, modify_timestamp)
VALUES
(@xmpp_id, 'shared_buddylist_visibility', 1, 1, 0, 0,
0, 'boolean', 1, 'Export this subscriber into the shared XMPP buddy list for the customer.', '1970-01-01 00:00:00'),
(@num_id, 'display_name', 0, 1, 0, 0,
0, 'string', 1, 'The network-provided display name used for XMPP contacts and optionally SIP outbound header manipulation.', '1970-01-01 00:00:00');
SELECT id INTO @disp_id FROM voip_preferences WHERE attribute = 'outbound_from_display';
INSERT INTO voip_preferences_enum
(preference_id, label, value, usr_pref, dom_pref, peer_pref, default_val)
VALUES
(@disp_id, 'Network-Provided Display-name', 'np_display', 1, 1, 1, 0);
COMMIT;
Loading…
Cancel
Save