From 022bfd91eca7ae26f8f6ee125179f5c0ff4cbb72 Mon Sep 17 00:00:00 2001 From: Mark Wells Date: Thu, 7 Aug 2014 13:50:51 -0700 Subject: merge new form 477 stuff, #24047 --- httemplate/elements/deploy_zone_block.html | 47 +++++++++++ httemplate/elements/deploy_zone_vertex.html | 45 ++++++++++ httemplate/elements/input-fcc_options.html | 114 ++++++++++++++++++++++++++ httemplate/elements/menu.html | 4 +- httemplate/elements/tr-input-fcc_options.html | 102 +++++++++++++++++++++++ 5 files changed, 310 insertions(+), 2 deletions(-) create mode 100644 httemplate/elements/deploy_zone_block.html create mode 100644 httemplate/elements/deploy_zone_vertex.html create mode 100644 httemplate/elements/input-fcc_options.html create mode 100644 httemplate/elements/tr-input-fcc_options.html (limited to 'httemplate/elements') diff --git a/httemplate/elements/deploy_zone_block.html b/httemplate/elements/deploy_zone_block.html new file mode 100644 index 000000000..9985944bd --- /dev/null +++ b/httemplate/elements/deploy_zone_block.html @@ -0,0 +1,47 @@ +% unless ( $opt{'js_only'} ) { + + + Block + + > +   + Year + + > +% } +<%init> + +my( %opt ) = @_; + +my $name = $opt{'element_name'} || $opt{'field'} || 'blocknum'; +my $id = $opt{'id'} || 'blocknum'; + +my $curr_value = $opt{'curr_value'} || $opt{'value'}; + +my $onchange = $opt{'onchange'}; +if ( $onchange ) { + $onchange =~ s/\(what\);/(this);/; + $onchange = 'onchange="'.$onchange.'"'; +} + +my $deploy_zone_block = $curr_value + ? FS::deploy_zone_block->by_key($curr_value) + : FS::deploy_zone_block->new; + + diff --git a/httemplate/elements/deploy_zone_vertex.html b/httemplate/elements/deploy_zone_vertex.html new file mode 100644 index 000000000..b3c8b31ea --- /dev/null +++ b/httemplate/elements/deploy_zone_vertex.html @@ -0,0 +1,45 @@ +% unless ( $opt{'js_only'} ) { + + + Latitude  + + > +   + Longitude  + + > +% } +<%init> + +my( %opt ) = @_; + +my $name = $opt{'element_name'} || $opt{'field'} || 'vertexnum'; +my $id = $opt{'id'} || 'vertexnum'; + +my $curr_value = $opt{'curr_value'} || $opt{'value'}; + +my $onchange = $opt{'onchange'}; +if ( $onchange ) { + $onchange =~ s/\(what\);/(this);/; + $onchange = 'onchange="'.$onchange.'"'; +} + +my $deploy_zone_vertex = $curr_value + ? FS::deploy_zone_vertex->by_key($curr_value) + : FS::deploy_zone_vertex->new; + + diff --git a/httemplate/elements/input-fcc_options.html b/httemplate/elements/input-fcc_options.html new file mode 100644 index 000000000..85a647043 --- /dev/null +++ b/httemplate/elements/input-fcc_options.html @@ -0,0 +1,114 @@ +% unless ($opt{js_only}) { +<& hidden.html, 'field' => $id, @_ &> +%# <& input-text.html, 'id' => $id, @_ &> # XXX debugging + + +% } +% unless ($opt{html_only}) { +% my $popup = $fsurl.'misc/part_pkg_fcc_options.html?id='; +% my $popup_name = 'popup-'.time. "-$$-". rand() * 2**32; + +% } +<%init> +my %opt = @_; +my $id = $opt{id} || $opt{field}; + diff --git a/httemplate/elements/menu.html b/httemplate/elements/menu.html index 8355d7a2c..7e329cf23 100644 --- a/httemplate/elements/menu.html +++ b/httemplate/elements/menu.html @@ -258,8 +258,8 @@ $report_packages{'Suspended customer packages'} = [ $fsurl.'search/cust_pkg.cgi $report_packages{'Suspension summary'} = [ $fsurl.'search/cust_pkg_susp.html', 'Show suspension activity', ] if $curuser->access_right('Summarize packages'); $report_packages{'Customer packages with unconfigured services'} = [ $fsurl.'search/cust_pkg.cgi?APKG_pkgnum', 'List packages which have provisionable services' ]; -$report_packages{'FCC Form 477 packages'} = [ $fsurl.'search/report_477.html', 'Summarize packages by census tract for particular types' ] - if $conf->exists('cust_main-require_censustract'); +$report_packages{'FCC Form 477'} = [ $fsurl.'search/report_477.html' ] + if $conf->exists('part_pkg-show_fcc_options'); $report_packages{'Advanced package reports'} = [ $fsurl.'search/report_cust_pkg.html', 'by agent, date range, status, package definition' ]; tie my %report_inventory, 'Tie::IxHash', diff --git a/httemplate/elements/tr-input-fcc_options.html b/httemplate/elements/tr-input-fcc_options.html new file mode 100644 index 000000000..58f7247c4 --- /dev/null +++ b/httemplate/elements/tr-input-fcc_options.html @@ -0,0 +1,102 @@ + + + + <& hidden.html, 'id' => $id, @_ &> +%# <& input-text.html, 'id' => $id, @_ &> # XXX debugging + + +% # show some kind of useful summary of the FCC options here + + + +<%init> +my %opt = @_; +my $id = $opt{id} || $opt{field}; + -- cgit v1.2.1