From 03fa1f136b48645768f79c63127c4debe6e94650 Mon Sep 17 00:00:00 2001 From: Daniel Tiefnig Date: Tue, 26 Apr 2011 16:50:12 +0000 Subject: [PATCH] reworked domain templates to follow new design now using tabs in domain view, dom preferences will be added next --- lib/admin/Controller/domain.pm | 223 ++++++++++-------- root/tt/domain.tt | 10 +- root/tt/domain_audio.tt | 104 +++++++++ root/tt/domain_detail.tt | 404 --------------------------------- root/tt/domain_rewrite.tt | 187 +++++++++++++++ root/tt/domain_vsc.tt | 134 +++++++++++ 6 files changed, 563 insertions(+), 499 deletions(-) create mode 100644 root/tt/domain_audio.tt delete mode 100644 root/tt/domain_detail.tt create mode 100644 root/tt/domain_rewrite.tt create mode 100644 root/tt/domain_vsc.tt diff --git a/lib/admin/Controller/domain.pm b/lib/admin/Controller/domain.pm index 072e066..d184d81 100644 --- a/lib/admin/Controller/domain.pm +++ b/lib/admin/Controller/domain.pm @@ -98,15 +98,15 @@ sub do_delete_domain : Local { return; } -=head2 detail +=head2 rewrite -Show details for a given domain: rewrite rules +Show rewrite rule details for a given domain. =cut -sub detail : Local { +sub rewrite : Local { my ( $self, $c ) = @_; - $c->stash->{template} = 'tt/domain_detail.tt'; + $c->stash->{template} = 'tt/domain_rewrite.tt'; my $domain = $c->request->params->{domain}; @@ -118,69 +118,6 @@ sub detail : Local { $c->stash->{domain} = $domain_rw; $c->stash->{editid} = $c->request->params->{editid}; - my $audio_files; - return unless $c->model('Provisioning')->call_prov( $c, 'voip', 'get_audio_files', - { domain => $domain }, - \$audio_files - ); - $c->stash->{audio_files} = $audio_files if eval { @$audio_files }; - - $c->stash->{edit_audio} = $c->request->params->{edit_audio}; - $c->stash->{delete_audio} = $c->request->params->{daf}; - - if(exists $c->session->{acrefill}) { - $c->stash->{acrefill} = $c->session->{acrefill}; - delete $c->session->{acrefill}; - } - if(exists $c->session->{aerefill}) { - $c->stash->{aerefill} = $c->session->{aerefill}; - delete $c->session->{aerefill}; - } elsif($c->request->params->{edit_audio}) { - foreach my $audio (eval { @$audio_files }) { - if($$audio{handle} eq $c->request->params->{edit_audio}) { - $c->stash->{aerefill} = $audio; - last; - } - } - } - - my $vscs; - return unless $c->model('Provisioning')->call_prov( $c, 'voip', 'get_domain_vscs', - { domain => $domain }, - \$vscs - ); - $c->stash->{vscs} = $vscs if eval { @$vscs }; - - my $vsc_actions; - return unless $c->model('Provisioning')->call_prov( $c, 'voip', 'get_vsc_actions', - { }, - \$vsc_actions - ); - @$vsc_actions = grep { my $tmp = $_; - ! grep { $$_{action} eq $tmp } - eval { @$vscs } - } - eval { @$vsc_actions }; - $c->stash->{vsc_actions} = $vsc_actions if @$vsc_actions; - - $c->stash->{edit_vsc} = $c->request->params->{edit_vsc}; - - if(exists $c->session->{vcrefill}) { - $c->stash->{vcrefill} = $c->session->{vcrefill}; - delete $c->session->{vcrefill}; - } - if(exists $c->session->{verefill}) { - $c->stash->{verefill} = $c->session->{verefill}; - delete $c->session->{verefill}; - } elsif($c->request->params->{edit_vsc}) { - foreach my $vsc (eval { @$vscs }) { - if($$vsc{action} eq $c->request->params->{edit_vsc}) { - $c->stash->{verefill} = $vsc; - last; - } - } - } - return 1; } @@ -228,7 +165,7 @@ sub create_rewrite : Local { { $messages{$m} = 'Server.Voip.SavedSettings'; $c->session->{messages} = \%messages; - $c->response->redirect("/domain/detail?domain=$domain#$a"); + $c->response->redirect("/domain/rewrite?domain=$domain#$a"); return; } else @@ -239,7 +176,7 @@ sub create_rewrite : Local { } $c->session->{messages} = \%messages; - $c->response->redirect("/domain/detail?domain=$domain#$a"); + $c->response->redirect("/domain/rewrite?domain=$domain#$a"); return; } @@ -288,7 +225,7 @@ sub edit_rewrite : Local { { $messages{$m} = 'Server.Voip.SavedSettings'; $c->session->{messages} = \%messages; - $c->response->redirect("/domain/detail?domain=$domain#$a"); + $c->response->redirect("/domain/rewrite?domain=$domain#$a"); return; } else @@ -299,7 +236,7 @@ sub edit_rewrite : Local { } $c->session->{messages} = \%messages; - $c->response->redirect("/domain/detail?domain=$domain#$a"); + $c->response->redirect("/domain/rewrite?domain=$domain#$a"); return; } @@ -380,17 +317,60 @@ sub delete_rewrite : Local { { $messages{$m} = 'Server.Voip.SavedSettings'; $c->session->{messages} = \%messages; - $c->response->redirect("/domain/detail?domain=$domain#$a"); + $c->response->redirect("/domain/rewrite?domain=$domain#$a"); return; } } else { } $c->session->{messages} = \%messages; - $c->response->redirect("/domain/detail?domain=$domain#$a"); + $c->response->redirect("/domain/rewrite?domain=$domain#$a"); return; } +=head2 audio + +Show audio file details for a given domain. + +=cut + +sub audio : Local { + my ( $self, $c ) = @_; + $c->stash->{template} = 'tt/domain_audio.tt'; + + my $domain = $c->request->params->{domain}; + + $c->stash->{domain} = $domain; + + my $audio_files; + return unless $c->model('Provisioning')->call_prov( $c, 'voip', 'get_audio_files', + { domain => $domain }, + \$audio_files + ); + $c->stash->{audio_files} = $audio_files if eval { @$audio_files }; + + $c->stash->{edit_audio} = $c->request->params->{edit_audio}; + $c->stash->{delete_audio} = $c->request->params->{daf}; + + if(exists $c->session->{acrefill}) { + $c->stash->{acrefill} = $c->session->{acrefill}; + delete $c->session->{acrefill}; + } + if(exists $c->session->{aerefill}) { + $c->stash->{aerefill} = $c->session->{aerefill}; + delete $c->session->{aerefill}; + } elsif($c->request->params->{edit_audio}) { + foreach my $audio (eval { @$audio_files }) { + if($$audio{handle} eq $c->request->params->{edit_audio}) { + $c->stash->{aerefill} = $audio; + last; + } + } + } + + return 1; +} + =head2 do_create_audio Store a new audio file in the database. @@ -421,7 +401,7 @@ sub do_create_audio : Local { { $messages{audiomsg} = 'Web.AudioFile.Created'; $c->session->{messages} = \%messages; - $c->response->redirect("/domain/detail?domain=$settings{domain}#audio"); + $c->response->redirect("/domain/audio?domain=$settings{domain}"); return; } } @@ -429,7 +409,7 @@ sub do_create_audio : Local { $messages{audioerr} = 'Client.Voip.InputErrorFound'; $c->session->{messages} = \%messages; $c->session->{acrefill} = \%settings; - $c->response->redirect("/domain/detail?domain=$settings{domain}#audio"); + $c->response->redirect("/domain/audio?domain=$settings{domain}"); return; } @@ -452,7 +432,7 @@ sub do_update_audio : Local { } $settings{handle} = $c->request->params->{handle}; unless(length $settings{handle}) { - $c->response->redirect("/domain/detail?domain=$settings{domain}"); + $c->response->redirect("/domain/audio?domain=$settings{domain}"); return; } $settings{data}{description} = $c->request->params->{description}; @@ -465,14 +445,14 @@ sub do_update_audio : Local { { $messages{audiomsg} = 'Web.AudioFile.Updated'; $c->session->{messages} = \%messages; - $c->response->redirect("/domain/detail?domain=$settings{domain}#audio"); + $c->response->redirect("/domain/audio?domain=$settings{domain}"); return; } $messages{audioerr} = 'Client.Voip.InputErrorFound'; $c->session->{messages} = \%messages; $c->session->{aerefill} = $settings{data}; - $c->response->redirect("/domain/detail?domain=$settings{domain}&edit_audio=$settings{handle}#audio"); + $c->response->redirect("/domain/audio?domain=$settings{domain}&edit_audio=$settings{handle}"); return; } @@ -494,7 +474,7 @@ sub do_delete_audio : Local { } $settings{handle} = $c->request->params->{handle}; unless(length $settings{handle}) { - $c->response->redirect("/domain/detail?domain=$settings{domain}"); + $c->response->redirect("/domain/audio?domain=$settings{domain}"); return; } @@ -503,11 +483,11 @@ sub do_delete_audio : Local { undef)) { $c->session->{messages} = { audiomsg => 'Web.AudioFile.Deleted' }; - $c->response->redirect("/domain/detail?domain=$settings{domain}#audio"); + $c->response->redirect("/domain/audio?domain=$settings{domain}"); return; } - $c->response->redirect("/domain/detail?domain=$settings{domain}&daf=$settings{handle}#audio"); + $c->response->redirect("/domain/audio?domain=$settings{domain}&daf=$settings{handle}"); return; } @@ -529,7 +509,7 @@ sub listen_audio : Local { } $settings{handle} = $c->request->params->{handle}; unless(length $settings{handle}) { - $c->response->redirect("/domain/detail?domain=$settings{domain}"); + $c->response->redirect("/domain/audio?domain=$settings{domain}"); return; } @@ -544,10 +524,71 @@ sub listen_audio : Local { return; } - $c->response->redirect("/domain/detail?domain=$settings{domain}#audio"); + $c->response->redirect("/domain/audio?domain=$settings{domain}"); return; } +=head2 vsc + +Show VSC details for a given domain. + +=cut + +sub vsc : Local { + my ( $self, $c ) = @_; + $c->stash->{template} = 'tt/domain_vsc.tt'; + + my $domain = $c->request->params->{domain}; + + $c->stash->{domain} = $domain; + + my $audio_files; + return unless $c->model('Provisioning')->call_prov( $c, 'voip', 'get_audio_files', + { domain => $domain }, + \$audio_files + ); + $c->stash->{audio_files} = $audio_files if eval { @$audio_files }; + + my $vscs; + return unless $c->model('Provisioning')->call_prov( $c, 'voip', 'get_domain_vscs', + { domain => $domain }, + \$vscs + ); + $c->stash->{vscs} = $vscs if eval { @$vscs }; + + my $vsc_actions; + return unless $c->model('Provisioning')->call_prov( $c, 'voip', 'get_vsc_actions', + { }, + \$vsc_actions + ); + @$vsc_actions = grep { my $tmp = $_; + ! grep { $$_{action} eq $tmp } + eval { @$vscs } + } + eval { @$vsc_actions }; + $c->stash->{vsc_actions} = $vsc_actions if @$vsc_actions; + + $c->stash->{edit_vsc} = $c->request->params->{edit_vsc}; + + if(exists $c->session->{vcrefill}) { + $c->stash->{vcrefill} = $c->session->{vcrefill}; + delete $c->session->{vcrefill}; + } + if(exists $c->session->{verefill}) { + $c->stash->{verefill} = $c->session->{verefill}; + delete $c->session->{verefill}; + } elsif($c->request->params->{edit_vsc}) { + foreach my $vsc (eval { @$vscs }) { + if($$vsc{action} eq $c->request->params->{edit_vsc}) { + $c->stash->{verefill} = $vsc; + last; + } + } + } + + return 1; +} + =head2 do_create_vsc Store a new VSC entry in the database. @@ -578,14 +619,14 @@ sub do_create_vsc : Local { { $messages{vscmsg} = 'Web.VSC.Created'; $c->session->{messages} = \%messages; - $c->response->redirect("/domain/detail?domain=$settings{domain}#vsc"); + $c->response->redirect("/domain/vsc?domain=$settings{domain}"); return; } $messages{vscerr} = 'Client.Voip.InputErrorFound'; $c->session->{messages} = \%messages; $c->session->{vcrefill} = \%settings; - $c->response->redirect("/domain/detail?domain=$settings{domain}#vsc"); + $c->response->redirect("/domain/vsc?domain=$settings{domain}"); return; } @@ -608,7 +649,7 @@ sub do_update_vsc : Local { } $settings{action} = $c->request->params->{action}; unless(length $settings{action}) { - $c->response->redirect("/domain/detail?domain=$settings{domain}"); + $c->response->redirect("/domain/vsc?domain=$settings{domain}"); return; } $settings{data}{digits} = length $c->request->params->{digits} @@ -624,14 +665,14 @@ sub do_update_vsc : Local { { $messages{vscmsg} = 'Web.VSC.Updated'; $c->session->{messages} = \%messages; - $c->response->redirect("/domain/detail?domain=$settings{domain}#vsc"); + $c->response->redirect("/domain/vsc?domain=$settings{domain}"); return; } $messages{vscerr} = 'Client.Voip.InputErrorFound'; $c->session->{messages} = \%messages; $c->session->{verefill} = $settings{data}; - $c->response->redirect("/domain/detail?domain=$settings{domain}&edit_vsc=$settings{action}#vsc"); + $c->response->redirect("/domain/vsc?domain=$settings{domain}&edit_vsc=$settings{action}"); return; } @@ -653,7 +694,7 @@ sub do_delete_vsc : Local { } $settings{action} = $c->request->params->{action}; unless(length $settings{action}) { - $c->response->redirect("/domain/detail?domain=$settings{domain}"); + $c->response->redirect("/domain/vsc?domain=$settings{domain}"); return; } @@ -662,11 +703,11 @@ sub do_delete_vsc : Local { undef)) { $c->session->{messages} = { vscmsg => 'Web.VSC.Deleted' }; - $c->response->redirect("/domain/detail?domain=$settings{domain}#vsc"); + $c->response->redirect("/domain/vsc?domain=$settings{domain}"); return; } - $c->response->redirect("/domain/detail?domain=$settings{domain}#vsc"); + $c->response->redirect("/domain/vsc?domain=$settings{domain}"); return; } diff --git a/root/tt/domain.tt b/root/tt/domain.tt index 60dd284..e2df7c3 100644 --- a/root/tt/domain.tt +++ b/root/tt/domain.tt @@ -11,10 +11,12 @@ [% FOREACH domain = domains %]
  • - [% IF Catalyst.config.domain.rewrite_features - || Catalyst.config.domain.vsc_features - || Catalyst.config.domain.audiofile_features %] - [% domain.domain %] + [% IF Catalyst.config.domain.rewrite_features %] + [% domain.domain %] + [% ELSIF Catalyst.config.domain.audiofile_features %] + [% domain.domain %] + [% ELSIF Catalyst.config.domain.vsc_features %] + [% domain.domain %] [% ELSE %] [% domain.domain %] [% END %] diff --git a/root/tt/domain_audio.tt b/root/tt/domain_audio.tt new file mode 100644 index 0000000..42b5605 --- /dev/null +++ b/root/tt/domain_audio.tt @@ -0,0 +1,104 @@ + +

    Domain [% domain %]

    + + + +
    +
      + [% IF Catalyst.config.domain.rewrite_features %] +
    • Rewrite Rules
    • + [% END %] + [% IF Catalyst.config.domain.audiofile_features %] +
    • Announcements
    • + [% END %] + [% IF Catalyst.config.domain.vsc_features %] +
    • VSCs
    • + [% END %] +
    +
    +
    + +

    Audio Files

    + + [% IF messages.audiomsg %]
    [% messages.audiomsg %]
    [% END %] + [% IF messages.audioerr %]
    [% messages.audioerr %]
    [% END %] + +
      +
    • +
      Handle
      +
      Description
      +
      Audio
      +
    • +
    +
      + [% id = 0 %] + [% FOREACH audio = audio_files %] + [% id = id + 1 %] +
    • + [% IF audio.handle == edit_audio %] +
      + + +
      [% audio.handle %]
      +
      + +
      +
      + +
      +
      + +
      +
      +
      + Cancel +
      + [% IF aerefill && prov_error %]
      [% prov_error %]
      [% END %] + [% ELSE %] +
      [% audio.handle %]
      +
      [% audio.description %]
      + +
      + [% UNLESS Catalyst.session.admin.read_only %] + Edit + [% END %] +
      +
      +
      + + + [% UNLESS Catalyst.session.admin.read_only %] +
      + [% IF audio.handle == delete_audio && prov_error %] +
      [% prov_error %]
      + [% END %] + [% END %] +
    • + [% END %] +
    • +
      + +
      + +
      +
      + +
      +
      + +
      +
      +
      +
      +
    • +
    + [% IF acrefill && prov_error %]
    [% prov_error %]
    [% END %] diff --git a/root/tt/domain_detail.tt b/root/tt/domain_detail.tt deleted file mode 100644 index 5f8e00c..0000000 --- a/root/tt/domain_detail.tt +++ /dev/null @@ -1,404 +0,0 @@ - - -

    Domain - [% domain.domain.domain %] -

    - - Back - - [% IF Catalyst.config.domain.rewrite_features %] - - [% - rewrites = [ - { - header = 'Inbound Rewrite Rules for Caller', - id = 'icaller', - tag = 'if', - dir = 'in', - field = 'caller', - msg = messages.icallermsg, - err = messages.icallererr, - rules = domain.rewrite_in_caller, - }, - { - header = 'Inbound Rewrite Rules for Callee', - id = 'icallee', - tag = 'it', - dir = 'in', - field = 'callee', - msg = messages.icalleemsg, - err = messages.icalleeerr, - rules = domain.rewrite_in_callee, - }, - { - header = 'Outbound Rewrite Rules for Caller', - id = 'ocaller', - tag = 'of', - dir = 'out', - field = 'caller', - msg = messages.ocallermsg, - err = messages.ocallererr, - rules = domain.rewrite_out_caller, - }, - ] - %] - - [% FOREACH rw = rewrites %] - -

    [% rw.header %]

    - - [% IF rw.msg %]
    [% rw.msg %]
    [% END %] - [% IF rw.err %]
    [% rw.err %]
    [% END %] - -
      -
    • -
       
      -
      Match Pattern
      -
      Replacement Pattern
      -
      Description
      -
    • -
    - -
      - [% id = 0 %] - [% priority = 999 %] - [% FOREACH rule = rw.rules %] - [% priority = rule.priority %] -
    • -
      - [% IF rule.id == editid && !Catalyst.session.admin.read_only %] -
      - - - - - -
      - -
      -
      - -
      -
      - -
      -
      - -
      -
      -
      - Cancel -
      - [% ELSE %] -
      [% rule.match_pattern %]
      -
      [% rule.replace_pattern %]
      -
      [% rule.description %]
      -
      - [% UNLESS Catalyst.session.admin.read_only %] - Edit - [% END %] -
      -
      - - - - -
      - [% UNLESS Catalyst.session.admin.read_only %] - - [% END %] -
      - [% END %] -
      -
    • - [% id = id + 1 %] - [% END %] -
    - - [% UNLESS Catalyst.session.admin.read_only %] -
      -
    • -
      - - - - -
       
      -
      - -
      -
      - -
      -
      - -
      -
      - -
      -
      -
    • -
    -
    - [% END %] - - [% END %] - [% END %] - - [% IF Catalyst.config.domain.audiofile_features %] - -

    Audio Files

    - -
    - [% IF messages.audiomsg %]
    [% messages.audiomsg %]
    [% END %] - [% IF messages.audioerr %]
    [% messages.audioerr %]
    [% END %] - - - - - - - - [% id = 0 %] - [% FOREACH audio = audio_files %] - [% id = id + 1 %] - [% IF audio.handle == edit_audio %] - - - - - - - - - - [% IF aerefill && prov_error %][% END %] - [% ELSE %] - - - - - - - - [% IF audio.handle == delete_audio && prov_error %] - - [% END %] - [% END %] - [% END %] - - - - - - - - -
    HandleDescriptionAudio - -
    [% audio.handle %] - - - - - - - - - -
    [% prov_error %]
    [% audio.handle %][% audio.description %]listen - [% UNLESS Catalyst.session.admin.read_only %] - Edit - [% END %] - -
    - - - [% UNLESS Catalyst.session.admin.read_only %] -
    [% prov_error %]
    - - - - - - - - -
    - [% IF acrefill && prov_error %]
    [% prov_error %]
    [% END %] -
    - - [% END %] - - [% IF Catalyst.config.domain.vsc_features %] - -

    Vertical Service Codes

    - -
    - [% IF messages.vscmsg %]
    [% messages.vscmsg %]
    [% END %] - [% IF messages.vscerr %]
    [% messages.vscerr %]
    [% END %] - - - - - - - - - [% id = 0 %] - [% FOREACH vsc = vscs %] - [% id = id + 1 %] - [% IF vsc.action == edit_vsc %] - - - - - - - - - - - [% IF verefill && prov_error %][% END %] - [% ELSE %] - - - - - - - - - [% END %] - [% END %] - [% IF vsc_actions %] - - - - - - - - - - [% ELSE %] - - [% END %] -
    ActionDigitsAudioDescription - -
    [% vsc.action %] - - - - - - - - - - - -
    [% prov_error %]
    [% vsc.action %][% vsc.digits %][% vsc.audio_file_handle %][% vsc.description %] - [% UNLESS Catalyst.session.admin.read_only %] - - [% END %] - -
    - - - [% UNLESS Catalyst.session.admin.read_only %] -
    - - - - - - - - - - -
    No undefined VSC actions found.
    - [% IF vcrefill && prov_error %]
    [% prov_error %]
    [% END %] -
    - - [% END %] - diff --git a/root/tt/domain_rewrite.tt b/root/tt/domain_rewrite.tt new file mode 100644 index 0000000..2503ccb --- /dev/null +++ b/root/tt/domain_rewrite.tt @@ -0,0 +1,187 @@ + + +

    Domain [% domain %]

    + + + +
    +
      + [% IF Catalyst.config.domain.rewrite_features %] +
    • Rewrite Rules
    • + [% END %] + [% IF Catalyst.config.domain.audiofile_features %] +
    • Announcements
    • + [% END %] + [% IF Catalyst.config.domain.vsc_features %] +
    • VSCs
    • + [% END %] +
    +
    +
    + + [% + rewrites = [ + { + header = 'Inbound Rewrite Rules for Caller', + id = 'icaller', + tag = 'if', + dir = 'in', + field = 'caller', + msg = messages.icallermsg, + err = messages.icallererr, + rules = domain.rewrite_in_caller, + }, + { + header = 'Inbound Rewrite Rules for Callee', + id = 'icallee', + tag = 'it', + dir = 'in', + field = 'callee', + msg = messages.icalleemsg, + err = messages.icalleeerr, + rules = domain.rewrite_in_callee, + }, + { + header = 'Outbound Rewrite Rules for Caller', + id = 'ocaller', + tag = 'of', + dir = 'out', + field = 'caller', + msg = messages.ocallermsg, + err = messages.ocallererr, + rules = domain.rewrite_out_caller, + }, + ] + %] + + [% FOREACH rw = rewrites %] + +

    [% rw.header %]

    + + [% IF rw.msg %]
    [% rw.msg %]
    [% END %] + [% IF rw.err %]
    [% rw.err %]
    [% END %] + +
      +
    • +
       
      +
      Match Pattern
      +
      Replacement Pattern
      +
      Description
      +
    • +
    + +
      + [% id = 0 %] + [% priority = 999 %] + [% FOREACH rule = rw.rules %] + [% priority = rule.priority %] +
    • +
      + [% IF rule.id == editid && !Catalyst.session.admin.read_only %] +
      + + + + + +
      + +
      +
      + +
      +
      + +
      +
      + +
      +
      +
      + Cancel +
      + [% ELSE %] +
      [% rule.match_pattern %]
      +
      [% rule.replace_pattern %]
      +
      [% rule.description %]
      +
      + [% UNLESS Catalyst.session.admin.read_only %] + Edit + [% END %] +
      +
      + + + + +
      + [% UNLESS Catalyst.session.admin.read_only %] + + [% END %] +
      + [% END %] +
      +
    • + [% id = id + 1 %] + [% END %] +
    + + [% UNLESS Catalyst.session.admin.read_only %] +
      +
    • +
      + + + + +
       
      +
      + +
      +
      + +
      +
      + +
      +
      + +
      +
      +
    • +
    +
    + [% END %] + + [% END %] + + + diff --git a/root/tt/domain_vsc.tt b/root/tt/domain_vsc.tt new file mode 100644 index 0000000..7ae0fd0 --- /dev/null +++ b/root/tt/domain_vsc.tt @@ -0,0 +1,134 @@ + +

    Domain [% domain %]

    + + + +
    +
      + [% IF Catalyst.config.domain.rewrite_features %] +
    • Rewrite Rules
    • + [% END %] + [% IF Catalyst.config.domain.audiofile_features %] +
    • Announcements
    • + [% END %] + [% IF Catalyst.config.domain.vsc_features %] +
    • VSCs
    • + [% END %] +
    +
    +
    + +

    Vertical Service Codes

    + + [% IF messages.vscmsg %]
    [% messages.vscmsg %]
    [% END %] + [% IF messages.vscerr %]
    [% messages.vscerr %]
    [% END %] + +
      +
      Action
      +
      Digits
      +
      Audio
      +
      Description
      + +
    +
      + [% id = 0 %] + [% FOREACH vsc = vscs %] + [% id = id + 1 %] +
    • + [% IF vsc.action == edit_vsc %] +
      + + +
      [% vsc.action %]
      +
      + +
      +
      + +
      +
      + +
      +
      + +
      +
      +
      + Cancel +
      + [% IF verefill && prov_error %]
      [% prov_error %]
      [% END %] + [% ELSE %] +
      [% vsc.action %]
      +
      [% vsc.digits %]
      +
      [% vsc.audio_file_handle %]
      +
      [% vsc.description %]
      +
      + [% UNLESS Catalyst.session.admin.read_only %] + Edit + [% END %] +
      +
      +
      + + + [% UNLESS Catalyst.session.admin.read_only %] +
      + [% END %] +
    • + [% END %] + +
    • + [% IF vsc_actions %] +
      + +
      + +
      +
      + +
      +
      + +
      +
      + +
      +
      +
      +
      + [% ELSE %] +
      No undefined VSC actions found.
      + [% END %] +
    • +
    + [% IF vcrefill && prov_error %]
    [% prov_error %]
    [% END %]