15 |
my $dsn = $Conf{SearchDSN}; |
my $dsn = $Conf{SearchDSN}; |
16 |
my $db_user = $Conf{SearchUser} || ''; |
my $db_user = $Conf{SearchUser} || ''; |
17 |
|
|
18 |
my $index_path = $Conf{HyperEstraierIndex}; |
my $hest_index_path = $Conf{HyperEstraierIndex}; |
|
if ($index_path) { |
|
|
$index_path = $TopDir . '/' . $index_path; |
|
|
$index_path =~ s#//#/#g; |
|
|
} |
|
19 |
|
|
20 |
my $dbh; |
my $dbh; |
21 |
|
|
194 |
my $offset = $param->{'offset'} || 0; |
my $offset = $param->{'offset'} || 0; |
195 |
$offset *= $on_page; |
$offset *= $on_page; |
196 |
|
|
197 |
die "no index_path?" unless ($index_path); |
die "no index_path?" unless ($hest_index_path); |
198 |
|
|
199 |
use HyperEstraier; |
use HyperEstraier; |
200 |
|
|
201 |
my ($index_path, $index_node_url) = getHyperEstraier_url($index_path); |
my ($index_path, $index_node_url) = getHyperEstraier_url($hest_index_path); |
202 |
|
|
203 |
# open the database |
# open the database |
204 |
my $db; |
my $db; |
297 |
|
|
298 |
my $dbh = get_dbh(); |
my $dbh = get_dbh(); |
299 |
|
|
300 |
my $sql = q{ |
my $sql = q{ |
301 |
SELECT |
SELECT |
302 |
backups.hostID AS hostID, |
backups.hostID AS hostID, |
303 |
hosts.name AS host, |
hosts.name AS host, |
307 |
backups.date AS date, |
backups.date AS date, |
308 |
backups.size AS size |
backups.size AS size |
309 |
FROM backups |
FROM backups |
310 |
WHERE id not in( select id from backups,archive_backup where archive_backup.backup_id=backups.id) |
INNER JOIN shares ON backups.shareID=shares.ID |
311 |
|
INNER JOIN hosts ON backups.hostID = hosts.ID |
312 |
|
LEFT OUTER JOIN archive_backup ON archive_backup.backup_id = backups.id AND archive_backup.backup_id IS NULL |
313 |
|
WHERE backups.size > 0 |
314 |
|
GROUP BY |
315 |
|
backups.hostID, |
316 |
|
hosts.name, |
317 |
|
shares.name, |
318 |
|
backups.num, |
319 |
|
backups.shareid, |
320 |
|
backups.id, |
321 |
|
backups.type, |
322 |
|
backups.date, |
323 |
|
backups.size |
324 |
ORDER BY backups.date |
ORDER BY backups.date |
325 |
}; |
}; |
326 |
my $sth = $dbh->prepare( $sql ); |
my $sth = $dbh->prepare( $sql ); |
374 |
if (e.checked) |
if (e.checked) |
375 |
{ |
{ |
376 |
var ret = e.name.match("fcb(.*)"); |
var ret = e.name.match("fcb(.*)"); |
377 |
suma += parseInt(eval("document.forma.fss"+ret[1]+".value")); |
suma += parseInt(eval("document.forma.fss"+ret[1]+".value") || 0); |
378 |
|
|
379 |
} |
} |
380 |
} |
} |