1 <% include( '/elements/header.html', 'Search RADIUS sessions' ) %>
3 <FORM NAME="OneTrueForm" ACTION="sqlradius.cgi" METHOD="GET">
4 % #include( '/elements/table.html' )
6 <% ntable('#cccccc') %>
8 <TD ALIGN="right">Username: </TD>
9 <TD><INPUT TYPE="text" NAME="username"></TD>
11 <% include( '/elements/tr-checkbox.html',
12 'field' => 'summarize',
13 'label' => 'Summarize',
19 <TD><FONT SIZE="-1"><I>(leave blank to show all users)</I></FONT></TD>
21 % my @part_export = qsearch( 'part_export', { 'exporttype' => 'sqlradius' } );
23 % qsearch( 'part_export', { 'exporttype' => 'sqlradius_withdomain' } );
25 % if ( grep { ! $_->option('hide_ip') } @part_export ) {
28 <TD ALIGN="right">IP address: </TD>
29 <TD><INPUT TYPE="text" NAME="ip"></TD>
33 <TD><FONT SIZE="-1"><I>(leave blank to show all IPs)</I></FONT></TD>
36 % if ( grep { $_->option('show_called_station') } @part_export ) {
39 <TD ALIGN="right">Destination prefix:</TD>
40 <TD><INPUT TYPE="text" NAME="prefix"></TD>
44 <TD><FONT SIZE="-1"><I>(country code or country code and prefix)</I></FONT></TD>
48 <TD><FONT SIZE="-1"><I>(leave blank to show all destinations)</I></FONT></TD>
55 <INPUT TYPE="radio" NAME="open_sessions" VALUE="0" onClick="open_changed(this);" CHECKED>Completed sessions<BR>
56 <INPUT TYPE="radio" NAME="open_sessions" VALUE="1" onClick="open_changed(this);">Open sessions
61 <TH COLSPAN=2>Session start</TD>
64 <% include( '/elements/tr-input-beginning_ending.html',
65 'prefix' => 'starttime',
70 <SCRIPT TYPE="text/javascript">
72 function open_changed(what) {
74 var value=get_open_value(what);
76 what.form.stoptime_beginning_text.disabled = true;
77 what.form.stoptime_ending_text.disabled = true;
78 what.form.stoptime_beginning_text.style.backgroundColor = '#dddddd';
79 what.form.stoptime_ending_text.style.backgroundColor = '#dddddd';
80 what.form.stoptime_beginning_button.style.display = 'none';
81 what.form.stoptime_ending_button.style.display = 'none';
82 what.form.stoptime_beginning_disabled.style.display = '';
83 what.form.stoptime_ending_disabled.style.display = '';
84 } else if ( value == '0' ) {
85 what.form.stoptime_beginning_text.disabled = false;
86 what.form.stoptime_ending_text.disabled = false;
87 what.form.stoptime_beginning_text.style.backgroundColor = '#ffffff';
88 what.form.stoptime_ending_text.style.backgroundColor = '#ffffff';
89 what.form.stoptime_beginning_button.style.display = '';
90 what.form.stoptime_ending_button.style.display = '';
91 what.form.stoptime_beginning_disabled.style.display = 'none';
92 what.form.stoptime_ending_disabled.style.display = 'none';
97 function get_open_value(what) {
99 for (var i=0; i < what.form.open_sessions.length; i++) {
100 if (what.form.open_sessions[i].checked) {
101 var rad_val = what.form.open_sessions[i].value;
110 <TH COLSPAN=2>Session end</TD>
113 <% include( '/elements/tr-input-beginning_ending.html',
114 'prefix' => 'stoptime',
120 <BR><INPUT TYPE="submit" VALUE="View sessions">
123 <% include('/elements/footer.html') %>
127 unless $FS::CurrentUser::CurrentUser->access_right('List rating data');