Fixed links for SMART and IDE param

This commit is contained in:
Jamie Cameron
2007-10-11 18:31:49 +00:00
parent 81cf5d7cc8
commit 415df5525a
2 changed files with 5 additions and 2 deletions

View File

@@ -14,3 +14,5 @@ Added support for systems with more than 26 IDE or SCSI drives.
---- Changes since 1.300 ----
Added support for formatting FATX filesystems.
Added a display of each partitions UUID, and added code to support their detection.
---- Changes since 1.360 ----
Link to SMART module for SCSI disks too, and IDE params page for SATA disks pretending to the SCSI.

View File

@@ -44,12 +44,13 @@ foreach $d (&list_disks_partitions()) {
# Show links to other modules
@links = ( );
if ($d->{'type'} eq 'ide' && $ed) {
if (($d->{'type'} eq 'ide' ||
$d->{'type'} eq 'scsi' && $d->{'model'} =~ /ATA/) && $ed) {
# Display link to IDE params form
push(@links, "<a href='edit_hdparm.cgi?".
"disk=$d->{'index'}'>$text{'index_hdparm'}</a>");
}
if ($smart && $d->{'type'} eq 'ide') {
if ($smart) {
# Display link to smart module
push(@links, "<a href='../smart-status/index.cgi?".
"drive=$d->{'device'}'>$text{'index_smart'}</a>");