diff options
author | Mark Wells <mark@freeside.biz> | 2016-03-10 01:20:21 -0800 |
---|---|---|
committer | Mark Wells <mark@freeside.biz> | 2016-03-10 01:23:34 -0800 |
commit | 733afa09f60a32088277bf743ac29d9caa1c7c78 (patch) | |
tree | ae1ee6b8c1c997207f54aa01b5919bad0a526fef /httemplate/elements/tr-input-fiber_circuit.html | |
parent | 2829b0c807bd4093f49e5d76cc1c112a868afcb6 (diff) |
add svc_fiber circuit id field, OLT sites, and other improvements, #35260
Diffstat (limited to 'httemplate/elements/tr-input-fiber_circuit.html')
-rw-r--r-- | httemplate/elements/tr-input-fiber_circuit.html | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/httemplate/elements/tr-input-fiber_circuit.html b/httemplate/elements/tr-input-fiber_circuit.html new file mode 100644 index 000000000..fb6462bb6 --- /dev/null +++ b/httemplate/elements/tr-input-fiber_circuit.html @@ -0,0 +1,31 @@ +<& /elements/tr-td-label.html, %opt &> + <td> + <table class="inv"> + <tr> + <th>FDU#</th> + <td><input name="<% $field %>_fdu" value="<% $fdu |h %>" SIZE="1"></td> + <th>FAT#</th> + <td><input name="<% $field %>_fat" value="<% $fat |h %>" SIZE="1"> + <input name="<% $field %>_subfat" value="<% $subfat |h %>" SIZE="1"> + </td> + <th>Port#</th> + <td><input name="<% $field %>_port" value="<% $port |h %>" SIZE="1"></td> + </tr> + </table> + </td> +</tr> +<%doc> +Supports a circuit ID of the form +FDU# (digit), FAT# (digit), SubFAT (letter), Port# (numeric) +May support other formats in the future, or just a free text field. +</%doc> +<%init> +my %opt = @_; +my $value = length($opt{curr_value}) ? $opt{curr_value} : $opt{value}; +my ($fdu, $fat, $port) = split('/', $value); +my $subfat = ''; +if ( $fat =~ /[A-Z]$/i ) { + $subfat = substr($fat, -1, 1, ''); +} +my $field = $opt{'field'} || 'circuit_id'; +</%init> |