1 package PciIds::Html::Tables;
4 use base 'PciIds::DBQ';
5 use PciIds::Html::Format;
10 return bless PciIds::DBQ::new( $dbh );
14 my $address = PciIds::Address::new( shift );
15 return '<a href="/read/'.$address->get().'">'.$address->tail().'</a>';
19 my( $self, $parent, $args ) = @_;
20 my $restrict = $args->{'restrict'};
21 $restrict = '' unless( defined $restrict );
22 $restrict = PciIds::Address::new( $parent )->restrictRex( $restrict );#How do I know if the restrict is OK?
23 htmlFormatTable( PciIds::DBQ::nodes( $self, $parent, $args, $restrict ), 3, [], [ \&formatLink ], sub { 1; }, sub {
24 my $name = shift->[ 1 ];
25 return ' class="'.( defined $name && $name ne '' ? 'item' : 'unnamedItem' ).'"';