From 0f359d5480aa1621d73ee802f420e8951abc620d Mon Sep 17 00:00:00 2001 From: Mark Wells Date: Thu, 31 Jul 2014 22:54:08 -0700 Subject: new 477 report: deployment info, combined browse-edit UI, #24047 --- httemplate/elements/deploy_zone_block.html | 47 +++++++++++ httemplate/elements/input-fcc_options.html | 108 ++++++++++++++++++++++++++ httemplate/elements/tr-input-fcc_options.html | 4 +- 3 files changed, 157 insertions(+), 2 deletions(-) create mode 100644 httemplate/elements/deploy_zone_block.html create mode 100644 httemplate/elements/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/input-fcc_options.html b/httemplate/elements/input-fcc_options.html new file mode 100644 index 000000000..b191e1c07 --- /dev/null +++ b/httemplate/elements/input-fcc_options.html @@ -0,0 +1,108 @@ +% 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/tr-input-fcc_options.html b/httemplate/elements/tr-input-fcc_options.html index 11cb4a962..58f7247c4 100644 --- a/httemplate/elements/tr-input-fcc_options.html +++ b/httemplate/elements/tr-input-fcc_options.html @@ -41,9 +41,9 @@ function show_fcc_options() { } var media = String.toLowerCase(curr_values['media'] || 'unknown media'); if ( curr_values['is_consumer'] ) { - out += '
  • Consumer-grade service
  • >'; + out += '
  • Consumer-grade
  • >'; } else { - out += '
  • Business-grade service
  • '; + out += '
  • Business-grade
  • '; } if ( curr_values['is_broadband'] ) { out += '
  • Broadband via ' + tech + '' -- cgit v1.2.1 From d7cf0d6bb3b81b1c91ef1bcc3252d56f96b65b0f Mon Sep 17 00:00:00 2001 From: Mark Wells Date: Tue, 5 Aug 2014 15:54:51 -0700 Subject: 477 report: improve browse-edit UI --- httemplate/elements/input-fcc_options.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'httemplate/elements') diff --git a/httemplate/elements/input-fcc_options.html b/httemplate/elements/input-fcc_options.html index b191e1c07..1d56cf274 100644 --- a/httemplate/elements/input-fcc_options.html +++ b/httemplate/elements/input-fcc_options.html @@ -39,7 +39,7 @@ function show_fcc_options(id) { } var media = String.toLowerCase(curr_values['media'] || 'unknown media'); if ( curr_values['is_consumer'] ) { - out += '
  • Consumer-grade service
  • >'; + out += '
  • Consumer-grade service
  • '; } else { out += '
  • Business-grade service
  • '; } -- cgit v1.2.1 From 1ebcca94aba75c5901c6eefaf373f39e94b03cf0 Mon Sep 17 00:00:00 2001 From: Mark Wells Date: Wed, 6 Aug 2014 14:11:01 -0700 Subject: 477 report: mobile deployment info --- httemplate/elements/deploy_zone_vertex.html | 45 +++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 httemplate/elements/deploy_zone_vertex.html (limited to 'httemplate/elements') 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; + + -- cgit v1.2.1