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