Changeset 72 for trunk/dns.cgi


Ignore:
Timestamp:
02/16/11 18:04:21 (13 years ago)
Author:
Kris Deugau
Message:

/trunk

Checkpoint - adding sort-on-title-click to record list columns

  • HTML seems complete
  • Still need to store sort type, direction in session
  • Still need to pass sort info into record retrieval sub in DNSDB.pm
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/dns.cgi

    r70 r72  
    252252    my ($count) = ($sth->fetchrow_array);
    253253
     254##work
     255# set up the headers
     256  my @cols = ('host', 'type', 'val', 'distance', 'weight', 'port', 'ttl');
     257  my %colheads = (host => 'Name', type => 'Type', val => 'Address',
     258        distance => 'Distance', weight => 'Weight', port => 'Port', ttl => 'TTL');
     259  my %custom = (id => $webvar{id}, defrec => $webvar{defrec});
     260  fill_colheads($sortby, $sortorder, \@cols, \%colheads, \%custom);
     261
    254262# fill the page-count and first-previous-next-last-all details
    255263  fill_pgcount($count,"records",domainName($dbh,$webvar{id}));
     
    10971105  $page->param(minttl   => $soa{minttl});
    10981106  $page->param(ttl      => $soa{ttl});
     1107
     1108  $startwith = $session->param($webvar{page}.'startwith');
     1109  $filter = $session->param($webvar{page}.'filter');
    10991110
    11001111#  my @foo2 = getDomRecs($dbh,'def',1);
     
    14841495  my $cols = shift;
    14851496  my $colnames = shift;
     1497  my $custom = shift;
    14861498
    14871499  my @headings;
     
    15011513      $coldata{order} = 'ASC';
    15021514    }
     1515    if ($custom) {
     1516      foreach my $ckey (keys %$custom) {
     1517        $coldata{$ckey} = $custom->{$ckey};
     1518      }
     1519    }
    15031520    push @headings, \%coldata;
    15041521  }
Note: See TracChangeset for help on using the changeset viewer.