2 'name_singular' => 'deployment zone',
3 'table' => 'deploy_zone',
4 'post_url' => popurl(1).'process/deploy_zone-fixed.html',
5 'viewall_dir' => 'browse',
7 'description' => 'Description',
9 'dbaname' => 'Business name (if different from agent)',
10 'technology' => 'Technology',
11 'adv_speed_up' => 'Upstream',
12 'adv_speed_down' => 'Downstream',
13 'cir_speed_up' => 'Upstream',
14 'cir_speed_down' => 'Downstream',
15 'is_consumer' => 'Consumer/mass market',
16 'is_business' => 'Business/government',
18 'active_date' => 'Active since',
21 { field => 'zonetype',
25 { field => 'is_broadband',
30 { field => 'active_date',
34 { field => 'agentnum',
35 type => 'select-agent',
37 viewall_right => 'Edit FCC report configuration for all agents',
40 { field => 'technology',
42 options => [ map { @$_ } values(%$media_types) ],
43 labels => $technology_labels,
45 { field => 'is_consumer', type => 'checkbox', value=>'Y' },
46 { field => 'is_business', type => 'checkbox', value=>'Y' },
47 { type => 'tablebreak-tr-title',
48 value => 'Advertised maximum speed (Mbps)' },
51 { type => 'tablebreak-tr-title',
52 value => 'Contractually guaranteed speed (Mbps)' },
56 { type => 'tablebreak-tr-title', value => 'Census blocks'},
57 { field => 'blocknum',
58 type => 'deploy_zone_block',
59 o2m_table => 'deploy_zone_block',
61 m2_error_callback => $m2_error_callback,
67 my $curuser = $FS::CurrentUser::CurrentUser;
69 unless $curuser->access_right([
70 'Edit FCC report configuration',
71 'Edit FCC report configuration for all agents',
74 my $technology_labels = FS::part_pkg_fcc_option->technology_labels;
75 my $media_types = FS::part_pkg_fcc_option->media_types;
76 delete $media_types->{'Mobile Wireless'}; # cause this is the fixed zone page
78 my $m2_error_callback = sub {
79 my ($cgi, $deploy_zone) = @_;
80 my @blocknums = grep {
81 /^blocknum\d+/ and length($cgi->param($_.'_censusblock'))
84 sort { $a->censusblock <=> $b->censusblock }
87 FS::deploy_zone_block->new({
88 blocknum => scalar($cgi->param($k)),
89 zonenum => $deploy_zone->zonenum,
90 censusblock => scalar($cgi->param($k.'_censusblock')),
91 censusyear => scalar($cgi->param($k.'_censusyear')),