|
|
|
@ -608,7 +608,7 @@ sub preferences :Chained('base') :PathPart('preferences') :Args(0) {
|
|
|
|
|
my $prov_subscriber = $c->stash->{subscriber}->provisioning_voip_subscriber;
|
|
|
|
|
my $cfs = {};
|
|
|
|
|
|
|
|
|
|
foreach my $type(qw/cfu cfna cft cfb cfs/) {
|
|
|
|
|
foreach my $type(qw/cfu cfna cft cfb cfs cfr/) {
|
|
|
|
|
my $maps = $prov_subscriber->voip_cf_mappings
|
|
|
|
|
->search({ type => $type });
|
|
|
|
|
$cfs->{$type} = [];
|
|
|
|
@ -713,7 +713,7 @@ sub preferences :Chained('base') :PathPart('preferences') :Args(0) {
|
|
|
|
|
$c->stash->{pref_groups} = \@newprefgroups;
|
|
|
|
|
|
|
|
|
|
my $special_prefs = { check => 1 };
|
|
|
|
|
foreach my $pref(qw/cfu cft cfna cfb cfs
|
|
|
|
|
foreach my $pref(qw/cfu cft cfna cfb cfs cfr
|
|
|
|
|
speed_dial reminder auto_attendant
|
|
|
|
|
voice_mail fax_server/) {
|
|
|
|
|
my $preference = $c->model('DB')->resultset('voip_preferences')->find({
|
|
|
|
@ -858,6 +858,10 @@ sub preferences_callforward :Chained('base') :PathPart('preferences/callforward'
|
|
|
|
|
$cf_desc = $c->loc('Call Forward SMS');
|
|
|
|
|
last SWITCH;
|
|
|
|
|
};
|
|
|
|
|
/^cfr$/ && do {
|
|
|
|
|
$cf_desc = $c->loc('Call Forward Rerouting');
|
|
|
|
|
last SWITCH;
|
|
|
|
|
};
|
|
|
|
|
# default
|
|
|
|
|
NGCP::Panel::Utils::Message::error(
|
|
|
|
|
c => $c,
|
|
|
|
@ -999,7 +1003,6 @@ sub preferences_callforward :Chained('base') :PathPart('preferences/callforward'
|
|
|
|
|
new_aa => ($d eq 'autoattendant'),
|
|
|
|
|
);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
NGCP::Panel::Utils::Subscriber::create_cf_destination(
|
|
|
|
|
c => $c,
|
|
|
|
|
subscriber => $c->stash->{subscriber},
|
|
|
|
@ -1090,6 +1093,10 @@ sub preferences_callforward_advanced :Chained('base') :PathPart('preferences/cal
|
|
|
|
|
$cf_desc = $c->loc('Call Forward SMS');
|
|
|
|
|
last SWITCH;
|
|
|
|
|
};
|
|
|
|
|
/^cfr$/ && do {
|
|
|
|
|
$cf_desc = $c->loc('Call Forward Rerouting');
|
|
|
|
|
last SWITCH;
|
|
|
|
|
};
|
|
|
|
|
# default
|
|
|
|
|
NGCP::Panel::Utils::Message::error(
|
|
|
|
|
c => $c,
|
|
|
|
@ -2886,7 +2893,7 @@ sub edit_master :Chained('master') :PathPart('edit') :Args(0) :Does(ACL) :ACLDet
|
|
|
|
|
if(keys %old_profile_attributes) {
|
|
|
|
|
my $cfs = $c->model('DB')->resultset('voip_preferences')->search({
|
|
|
|
|
id => { -in => [ keys %old_profile_attributes ] },
|
|
|
|
|
attribute => { -in => [qw/cfu cfb cft cfna cfs/] },
|
|
|
|
|
attribute => { -in => [qw/cfu cfb cft cfna cfs cfr/] },
|
|
|
|
|
});
|
|
|
|
|
$prov_subscriber->voip_usr_preferences->search({
|
|
|
|
|
attribute_id => { -in => [ keys %old_profile_attributes ] },
|
|
|
|
|