destination
zone
diff --git a/lib/admin/Controller/domain.pm b/lib/admin/Controller/domain.pm
index 58e9e46..fb30c78 100644
--- a/lib/admin/Controller/domain.pm
+++ b/lib/admin/Controller/domain.pm
@@ -287,12 +287,14 @@ sub create_rewrite : Local {
unless(keys %messages) {
if($c->model('Provisioning')->call_prov( $c, 'voip', 'create_domain_rewrite',
{ domain => $domain,
- direction => $direction,
- field => $field,
- match_pattern => $match_pattern,
- replace_pattern => $replace_pattern,
- description => $description,
- priority => $priority,
+ data => {
+ direction => $direction,
+ field => $field,
+ match_pattern => $match_pattern,
+ replace_pattern => $replace_pattern,
+ description => $description,
+ priority => $priority,
+ },
},
undef
))
@@ -344,13 +346,15 @@ sub edit_rewrite : Local {
unless(keys %messages) {
if($c->model('Provisioning')->call_prov( $c, 'voip', 'update_domain_rewrite',
- { id => $rewriteid,
- match_pattern => $match_pattern,
- replace_pattern => $replace_pattern,
- description => $description,
- direction => $direction,
- field => $field,
- priority => $priority,
+ { id => $rewriteid,
+ data => {
+ match_pattern => $match_pattern,
+ replace_pattern => $replace_pattern,
+ description => $description,
+ direction => $direction,
+ field => $field,
+ priority => $priority,
+ },
},
undef
))
diff --git a/lib/admin/Controller/peering.pm b/lib/admin/Controller/peering.pm
index fa1e175..a6f86f4 100644
--- a/lib/admin/Controller/peering.pm
+++ b/lib/admin/Controller/peering.pm
@@ -159,7 +159,7 @@ sub edit_grp : Local {
my %messages;
my %settings;
- $settings{id} = $c->request->params->{grpid};
+ my $grpid = $c->request->params->{grpid};
$settings{priority} = $c->request->params->{priority};
$settings{description} = $c->request->params->{grpdesc};
$settings{peering_contract_id} = $c->request->params->{peering_contract_id} || undef;
@@ -168,7 +168,9 @@ sub edit_grp : Local {
unless(keys %messages) {
if($c->model('Provisioning')->call_prov( $c, 'voip', 'update_peer_group',
- \%settings,
+ { id => $grpid,
+ data => \%settings,
+ },
undef
))
{
@@ -213,7 +215,7 @@ sub create_rule : Local {
my $grpid = $c->request->params->{grpid};
my $callee_prefix = $c->request->params->{callee_prefix};
- my $caller_pattern = $c->request->params->{caller_pattern};
+ my $caller_prefix = $c->request->params->{caller_prefix};
my $description = $c->request->params->{description};
# $messages{crulerr} = 'Client.Syntax.MalformedPeerGroupName'
@@ -222,9 +224,11 @@ sub create_rule : Local {
unless(keys %messages) {
if($c->model('Provisioning')->call_prov( $c, 'voip', 'create_peer_rule',
{ group_id => $grpid,
- callee_prefix => $callee_prefix,
- caller_pattern => $caller_pattern,
- description => $description
+ data => {
+ callee_prefix => $callee_prefix,
+ caller_prefix => $caller_prefix,
+ description => $description
+ },
},
undef
))
@@ -304,7 +308,7 @@ sub edit_rule : Local {
my $grpid = $c->request->params->{grpid};
my $ruleid = $c->request->params->{ruleid};
my $callee_prefix = $c->request->params->{callee_prefix};
- my $caller_pattern = $c->request->params->{caller_pattern};
+ my $caller_prefix = $c->request->params->{caller_prefix};
my $description = $c->request->params->{description};
# $messages{crulerr} = 'Client.Syntax.MalformedPeerGroupName'
@@ -312,10 +316,12 @@ sub edit_rule : Local {
unless(keys %messages) {
if($c->model('Provisioning')->call_prov( $c, 'voip', 'update_peer_rule',
- { id => $ruleid,
- callee_prefix => $callee_prefix,
- caller_pattern => $caller_pattern,
- description => $description
+ { id => $ruleid,
+ data => {
+ callee_prefix => $callee_prefix,
+ caller_prefix => $caller_prefix,
+ description => $description
+ },
},
undef
))
@@ -362,7 +368,6 @@ sub create_peer : Local {
my $ip = $c->request->params->{ip};
my $port = $c->request->params->{port};
my $weight = $c->request->params->{weight};
- my $via_lb = defined $c->request->params->{via_lb} ? 1 : 0;
#TODO: add syntax checks here
@@ -373,12 +378,13 @@ sub create_peer : Local {
unless(keys %messages) {
if($c->model('Provisioning')->call_prov( $c, 'voip', 'create_peer_host',
{ group_id => $grpid,
- name => $name,
- domain => $domain,
- ip => $ip,
- port => $port,
- weight => $weight,
- via_lb => $via_lb
+ data => {
+ name => $name,
+ domain => $domain,
+ ip => $ip,
+ port => $port,
+ weight => $weight,
+ },
},
undef
))
@@ -462,7 +468,6 @@ sub edit_peer : Local {
my $ip = $c->request->params->{ip};
my $port = $c->request->params->{port};
my $weight = $c->request->params->{weight};
- my $via_lb = defined $c->request->params->{via_lb} ? 1 : 0;
# $messages{crulerr} = 'Client.Syntax.MalformedPeerGroupName'
# unless $callee_prefix =~ /^[a-zA-Z0-9_\.\-\@\:]+/;
@@ -470,12 +475,13 @@ sub edit_peer : Local {
unless(keys %messages) {
if($c->model('Provisioning')->call_prov( $c, 'voip', 'update_peer_host',
{ id => $peerid,
- name => $name,
- domain => $domain,
- ip => $ip,
- port => $port,
- weight => $weight,
- via_lb => $via_lb
+ data => {
+ name => $name,
+ domain => $domain,
+ ip => $ip,
+ port => $port,
+ weight => $weight,
+ },
},
undef
))
@@ -522,7 +528,7 @@ sub rewrite : Local {
);
my $all_peer_details;
return unless $c->model('Provisioning')->call_prov( $c, 'voip', 'get_peer_group_details',
- { id => $$peer_details{group_id} },
+ { id => $$peer_details{peer_host}{group_id} },
\$all_peer_details
);
my $all_peers = $$all_peer_details{peers};
@@ -578,12 +584,14 @@ sub create_rewrite : Local {
unless(keys %messages) {
if($c->model('Provisioning')->call_prov( $c, 'voip', 'create_peer_rewrite',
{ peer_id => $peerid,
- match_pattern => $match_pattern,
- replace_pattern => $replace_pattern,
- description => $description,
- direction => $direction,
- field => $field,
- priority => $priority,
+ data => {
+ match_pattern => $match_pattern,
+ replace_pattern => $replace_pattern,
+ description => $description,
+ direction => $direction,
+ field => $field,
+ priority => $priority,
+ },
},
undef
))
@@ -691,12 +699,14 @@ sub edit_rewrite : Local {
unless(keys %messages) {
if($c->model('Provisioning')->call_prov( $c, 'voip', 'update_peer_rewrite',
{ id => $rewriteid,
- match_pattern => $match_pattern,
- replace_pattern => $replace_pattern,
- description => $description,
- direction => $direction,
- field => $field,
- priority => $priority,
+ data => {
+ match_pattern => $match_pattern,
+ replace_pattern => $replace_pattern,
+ description => $description,
+ direction => $direction,
+ field => $field,
+ priority => $priority,
+ },
},
undef
))
@@ -741,7 +751,7 @@ sub copy_rewrite : Local {
my $rpeerid = $c->request->params->{rpeerid};
my $policy= $c->request->params->{policy};
my $grpid = $c->request->params->{grpid};
- my $delete_old = $policy eq "delete" ? 1 : 0;
+ my $delete_existing = $policy eq "delete" ? 1 : 0;
unless(defined $peerid && defined $rpeerid)
{
@@ -751,8 +761,8 @@ sub copy_rewrite : Local {
unless(keys %messages) {
if($c->model('Provisioning')->call_prov( $c, 'voip', 'copy_peer_rewrites',
{ from_peer_id => $rpeerid,
- to_peer_id => $peerid,
- delete_old => $delete_old
+ to_peer_id => $peerid,
+ delete_existing => $delete_existing
},
undef
))
diff --git a/root/layout/menu b/root/layout/menu
index cc3433f..92082ca 100644
--- a/root/layout/menu
+++ b/root/layout/menu
@@ -19,6 +19,9 @@
[% END %]
Accounts
Subscribers
+ [% IF Catalyst.config.li_features %]
+ Lawful Intercept
+ [% END %]
[%# Devices %]
[%# Registrations %]
diff --git a/root/tt/admin.tt b/root/tt/admin.tt
index a51715a..fdf8250 100644
--- a/root/tt/admin.tt
+++ b/root/tt/admin.tt
@@ -13,7 +13,7 @@
r/o
PW
CDR
- [% IF Catalyst.config.lawful_intercept %]
+ [% IF Catalyst.config.li_features %]
LI
[% END %]
@@ -58,7 +58,7 @@
[% IF erefill.call_data or !erefill && admin.call_data %]checked="checked" [% END %]
title="if checked, the administrator may view call detail records" />
- [% IF Catalyst.config.lawful_intercept %]
+ [% IF Catalyst.config.li_features %]
- [% IF Catalyst.config.lawful_intercept %]
+ [% IF Catalyst.config.li_features %]
- [% IF Catalyst.config.lawful_intercept %]
+ [% IF Catalyst.config.li_features %]
lawful intercepts:
diff --git a/root/tt/domain_detail.tt b/root/tt/domain_detail.tt
index 7d06898..cca2cd5 100644
--- a/root/tt/domain_detail.tt
+++ b/root/tt/domain_detail.tt
@@ -1,5 +1,5 @@
back
@@ -28,7 +28,7 @@
- cancel
+ cancel
[% ELSE %]
[% rule.match_pattern %]
[% rule.replace_pattern %]
@@ -61,11 +61,11 @@
[% rule.description %]
[% UNLESS Catalyst.session.admin.read_only %]
- edit
+ edit
[% END %]
-
+
@@ -199,7 +199,7 @@
-
+
@@ -252,7 +252,7 @@
-
+
- cancel
+ cancel
[% ELSE %]
[% rule.match_pattern %]
[% rule.replace_pattern %]
@@ -285,11 +285,11 @@
[% rule.description %]
[% UNLESS Catalyst.session.admin.read_only %]
- edit
+ edit
[% END %]
-
+
@@ -311,7 +311,7 @@
-
+
@@ -376,7 +376,7 @@
title="audio file in wave format" />
-
+
save
@@ -384,22 +384,22 @@
- cancel
+ cancel
[% IF aerefill && prov_error %][% prov_error %]
[% END %]
[% ELSE %]
[% audio.handle %]
[% audio.description %]
- listen
+ listen
[% UNLESS Catalyst.session.admin.read_only %]
- edit
+ edit
[% END %]
-
+
[% UNLESS Catalyst.session.admin.read_only %]
@@ -430,7 +430,7 @@
title="audio file in wave format" />
-
+
add
@@ -488,7 +488,7 @@
name="description" value="[% verefill.description %]" />
-
+
save
@@ -496,7 +496,7 @@
- cancel
+ cancel
[% IF verefill && prov_error %][% prov_error %]
[% END %]
[% ELSE %]
@@ -507,12 +507,12 @@
[% vsc.description %]
[% UNLESS Catalyst.session.admin.read_only %]
- edit
+ edit
[% END %]
-
+
[% UNLESS Catalyst.session.admin.read_only %]
@@ -557,7 +557,7 @@
name="description" value="[% vcrefill.data.description %]" />
-
+
add
diff --git a/root/tt/peering_detail.tt b/root/tt/peering_detail.tt
index 21d744f..557d58d 100644
--- a/root/tt/peering_detail.tt
+++ b/root/tt/peering_detail.tt
@@ -1,6 +1,6 @@
back
@@ -24,7 +24,7 @@
[% IF rule.id == reditid && !Catalyst.session.admin.read_only %]
-
+
+ name="caller_prefix" value="[% rule.caller_prefix %]" />
- cancel
+ cancel
[% ELSE %]
[% rule.callee_prefix %]
- [% rule.caller_pattern %]
+ [% rule.caller_prefix %]
[% rule.description %]
[% UNLESS Catalyst.session.admin.read_only %]
- edit
+ edit
[% END %]
-
+
[% UNLESS Catalyst.session.admin.read_only %]
@@ -74,14 +74,14 @@
[% UNLESS Catalyst.session.admin.read_only %]
-
+
+ name="caller_prefix" value="" />
IP Address
Port
Weight
- Via Loadbalancer
@@ -125,7 +124,7 @@
[% IF peer.id == peditid && !Catalyst.session.admin.read_only %]
-
+
-
-
-
save
@@ -158,24 +153,20 @@
- cancel
+ cancel
[% ELSE %]
[% peer.name %]
[% peer.domain %]
[% peer.ip %]
[% peer.port %]
[% peer.weight %]
-
-
-
[% UNLESS Catalyst.session.admin.read_only %]
- edit
+ edit
[% END %]
-
+
[% UNLESS Catalyst.session.admin.read_only %]
@@ -193,7 +184,7 @@
[% UNLESS Catalyst.session.admin.read_only %]
-
+
@@ -214,10 +205,6 @@
-
-
-
add
diff --git a/root/tt/peering_rewrite.tt b/root/tt/peering_rewrite.tt
index 596c910..89b3fe7 100644
--- a/root/tt/peering_rewrite.tt
+++ b/root/tt/peering_rewrite.tt
@@ -1,9 +1,9 @@
-
back
+
back
[% IF all_peers.size > 0 %]
[% UNLESS Catalyst.session.admin.read_only %]
@@ -14,8 +14,8 @@
-
-
+
+
Copy rules from peering host
@@ -65,7 +65,7 @@
[% IF rule.id == ifeditid && !Catalyst.session.admin.read_only %]
-
+
@@ -92,7 +92,7 @@
- cancel
+ cancel
[% ELSE %]
[% rule.match_pattern %]
[% rule.replace_pattern %]
@@ -100,11 +100,11 @@
[% rule.description %]
[% UNLESS Catalyst.session.admin.read_only %]
- edit
+ edit
[% END %]
-
+
@@ -124,8 +124,8 @@
[% UNLESS Catalyst.session.admin.read_only %]
-
-
+
+
@@ -180,7 +180,7 @@
[% IF rule.id == iteditid && !Catalyst.session.admin.read_only %]
-
+
@@ -207,7 +207,7 @@
- cancel
+ cancel
[% ELSE %]
[% rule.match_pattern %]
[% rule.replace_pattern %]
@@ -215,11 +215,11 @@
[% rule.description %]
[% UNLESS Catalyst.session.admin.read_only %]
- edit
+ edit
[% END %]
-
+
@@ -239,8 +239,8 @@
[% UNLESS Catalyst.session.admin.read_only %]
-
-
+
+
@@ -294,7 +294,7 @@
[% IF rule.id == ofeditid && !Catalyst.session.admin.read_only %]
-
+
@@ -321,7 +321,7 @@
- cancel
+ cancel
[% ELSE %]
[% rule.match_pattern %]
[% rule.replace_pattern %]
@@ -329,11 +329,11 @@
[% rule.description %]
[% UNLESS Catalyst.session.admin.read_only %]
- edit
+ edit
[% END %]
-
+
@@ -353,8 +353,8 @@
[% UNLESS Catalyst.session.admin.read_only %]
-
-
+
+
@@ -408,7 +408,7 @@
[% IF rule.id == oteditid && !Catalyst.session.admin.read_only %]
-
+
@@ -435,7 +435,7 @@
- cancel
+ cancel
[% ELSE %]
[% rule.match_pattern %]
[% rule.replace_pattern %]
@@ -443,11 +443,11 @@
[% rule.description %]
[% UNLESS Catalyst.session.admin.read_only %]
- edit
+ edit
[% END %]
-
+
@@ -467,8 +467,8 @@
[% UNLESS Catalyst.session.admin.read_only %]
-
-
+
+