Subversion Repositories ALCASAR

Rev

Rev 2929 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log

Rev 2929 Rev 3173
Line 102... Line 102...
102
	<i>$items[$nam]</i>
102
	<i>$items[$nam]</i>
103
	<input type=hidden name="item_of_$this->name" value="$this->item">
103
	<input type=hidden name="item_of_$this->name" value="$this->item">
104
	</td><td align=left>
104
	</td><td align=left>
105
	<select name=operator_of_$this->name>
105
	<select name=operator_of_$this->name>
106
EOM;
106
EOM;
107
		foreach($operators as $operator){
107
		foreach ($operators as $operator){
108
			if($this->operator == $operator)
108
			if($this->operator == $operator)
109
				$selected=" selected ";
109
				$selected=" selected ";
110
			else
110
			else
111
				$selected='';
111
				$selected='';
112
			print("<option value=\"$operator\" $selected>$operator</option>\n");
112
			print("<option value=\"$operator\" $selected>$operator</option>\n");
Line 158... Line 158...
158
<tr>
158
<tr>
159
<td>
159
<td>
160
<b>$l_attributes</b><br>
160
<b>$l_attributes</b><br>
161
<select name="accounting_show_attrs[]" size=5 multiple>
161
<select name="accounting_show_attrs[]" size=5 multiple>
162
EOM;
162
EOM;
163
foreach($items as $key => $val)
163
foreach ($items as $key => $val)
164
	echo <<<EOM
164
	echo <<<EOM
165
<option $selected[$key] value="$key">$val</option>
165
<option $selected[$key] value="$key">$val</option>
166
EOM;
166
EOM;
167
 
167
 
168
echo <<<EOM
168
echo <<<EOM
Line 170... Line 170...
170
<br><br>
170
<br><br>
171
<b>$l_ordered</b><br>
171
<b>$l_ordered</b><br>
172
<select name="order_by">
172
<select name="order_by">
173
EOM;
173
EOM;
174
 
174
 
175
foreach($items as $key => $val)
175
foreach ($items as $key => $val)
176
	if ($val == 'username')
176
	if ($val == 'username')
177
		echo <<<EOM
177
		echo <<<EOM
178
	<option selected value="$key">$val</option>
178
	<option selected value="$key">$val</option>
179
EOM;
179
EOM;
180
	else
180
	else
Line 197... Line 197...
197
<tr><td>
197
<tr><td>
198
<select name=item_name onchange="this.form.add.value=1;this.form.submit()">
198
<select name=item_name onchange="this.form.add.value=1;this.form.submit()">
199
<option>--Attribute--</option>
199
<option>--Attribute--</option>
200
EOM;
200
EOM;
201
 
201
 
202
foreach($items as $key => $val)
202
foreach ($items as $key => $val)
203
	print("<option value=\"$key\">$val</option>");
203
	print("<option value=\"$key\">$val</option>");
204
 
204
 
205
echo <<<EOM
205
echo <<<EOM
206
</select>
206
</select>
207
</td></tr>
207
</td></tr>
Line 294... Line 294...
294
	<tr><td>
294
	<tr><td>
295
		<table border=1 width=100% cellpadding=2 cellspacing=0 bgcolor="#ffffe0" valign=top>
295
		<table border=1 width=100% cellpadding=2 cellspacing=0 bgcolor="#ffffe0" valign=top>
296
		<tr bgcolor="#d0ddb0">
296
		<tr bgcolor="#d0ddb0">
297
EOM;
297
EOM;
298
 
298
 
299
foreach($accounting_show_attrs as $val){
299
foreach ($accounting_show_attrs as $val){
300
	$desc = $sql_attrs[$val]['desc'];
300
	$desc = $sql_attrs[$val]['desc'];
301
	if($val == 'acctoutputoctets')
301
	if($val == 'acctoutputoctets')
302
		$desc = "Upload";
302
		$desc = "Upload";
303
	if($val == 'acctinputoctets')
303
	if($val == 'acctinputoctets')
304
		$desc = "Download";
304
		$desc = "Download";
Line 309... Line 309...
309
	$search = da_sql_query($link,$config,$query);
309
	$search = da_sql_query($link,$config,$query);
310
	if ($search){
310
	if ($search){
311
		while( $row = da_sql_fetch_array($search,$config) ){
311
		while( $row = da_sql_fetch_array($search,$config) ){
312
			//$num++;
312
			//$num++;
313
			echo "<tr align=center>\n";
313
			echo "<tr align=center>\n";
314
			foreach($accounting_show_attrs as $val){
314
			foreach ($accounting_show_attrs as $val){
315
				$info = $row[$val];
315
				$info = $row[$val];
316
				if($val == "acctoutputoctets" || $val == "acctinputoctets")
316
				if($val == "acctoutputoctets" || $val == "acctinputoctets")
317
					$info = bytes2str($info);
317
					$info = bytes2str($info);
318
				if($val == "acctsessiontime")
318
				if($val == "acctsessiontime")
319
					$info = time2strclock($info);
319
					$info = time2strclock($info);