From 1a341d5c8d2c828a1b49c627c49a60db092ca7de Mon Sep 17 00:00:00 2001 From: longinus Date: Wed, 8 Aug 2012 15:49:20 +0000 Subject: [PATCH] update to db ver 102 add tsid field to epg timeline expert table hide channels without chname disable te_ary/bc_ary modification fix rpm spec, now can be build in fedora 17 fix httpd conf, add FollowSymLinks, remove Allow/Order git-svn-id: svn+ssh://svn.sourceforge.jp/svnroot/rec10@943 4e526526-5e11-4fc0-8910-f8fd03428081 --- rectool/trunk/rec10.conf | 4 +--- rectool/trunk/rectool.pl | 21 ++++++++++++--------- rectool/trunk/rectool.spec | 6 +++--- 3 files changed, 16 insertions(+), 15 deletions(-) diff --git a/rectool/trunk/rec10.conf b/rectool/trunk/rec10.conf index c85b2bf..0b33ba6 100644 --- a/rectool/trunk/rec10.conf +++ b/rectool/trunk/rec10.conf @@ -1,7 +1,5 @@ - Options ExecCGI + Options ExecCGI FollowSymLinks AllowOverride None - Order allow, deny - Allow from all AddHandler cgi-script .pl .cgi diff --git a/rectool/trunk/rectool.pl b/rectool/trunk/rectool.pl index c6fe589..fa4a478 100755 --- a/rectool/trunk/rectool.pl +++ b/rectool/trunk/rectool.pl @@ -33,7 +33,7 @@ use utf8; ################ バージョン定義 ################ -my $rectool_version = 101; +my $rectool_version = 102; ################ 初期化ここから ################ @@ -155,16 +155,17 @@ tie %chtxt_0_chname, 'Tie::IxHash'; my $ary_ref = $dbh->selectall_arrayref( "SELECT chtxt, chname, ch, bctype FROM epg_ch - WHERE visible = 1" + WHERE visible = 1 + AND chname != '' + ORDER BY chtxt" ); %chtxt_chname = map { $_->[0], $_->[1] } @{$ary_ref}; -# NHK BS 1/2/hiをBS/CSから除外(101-103) - by 2011/04 -# te: 地上波、BSのNHK以外 -# bc: BSのNHK、CS -my @te_ary = grep $_->[0]=~ /^\d|BS_(?!(10|19)[1-3])/, @{$ary_ref}; -my @bc_ary = grep $_->[0]!~ /^\d|BS_(?!(10|19)[1-3])/, @{$ary_ref}; +# te: 地上波 +# bc: BS、CS +my @te_ary = grep $_->[0]=~ /^\d/, @{$ary_ref}; +my @bc_ary = grep $_->[0]!~ /^\d/, @{$ary_ref}; # teの操作(まとめる) foreach my $line ( @te_ary ) { @@ -1808,7 +1809,7 @@ if ( $mode eq 'expert' ) { $ary_ref = $dbh->selectall_arrayref( - "SELECT chname, chtxt, bctype, ch, csch, updatetime, status, visible + "SELECT chname, chtxt, bctype, ch, csch, tsid, updatetime, status, visible FROM epg_ch ORDER BY bctype " ); $HTML .= qq {
\n番組表の更新状況
\n}; @@ -1818,6 +1819,7 @@ if ( $mode eq 'expert' ) { $HTML .= qq {bctype\n}; $HTML .= qq {ch\n}; $HTML .= qq {csch\n}; + $HTML .= qq {tsid\n}; $HTML .= qq {最終更新時刻\n}; $HTML .= qq {状態\n}; $HTML .= qq {表示\n}; @@ -1826,6 +1828,7 @@ if ( $mode eq 'expert' ) { $HTML .= qq {\n}; $HTML .= qq {$status->[0]\n$status->[1]\n$status->[2]\n$status->[3]\n}; $HTML .= qq {$status->[4]\n$status->[5]\n$status->[6]\n$status->[7]\n}; + $HTML .= qq {$status->[8]\n}; $HTML .= qq {\n}; } $HTML .= qq {\n}; @@ -1841,7 +1844,7 @@ if ( $mode eq 'expert' ) { FROM epg_ch WHERE bctype NOT LIKE '_s%' " ); foreach my $line ( @{$ary_ref} ) { - $HTML .= qq {\n}; + $HTML .= qq {\n}; } $HTML .= qq {\n}; $HTML .= qq {\n}; diff --git a/rectool/trunk/rectool.spec b/rectool/trunk/rectool.spec index 11cc031..efcf05c 100644 --- a/rectool/trunk/rectool.spec +++ b/rectool/trunk/rectool.spec @@ -21,15 +21,15 @@ rectool-0.0.1 %prep rm -rf $RPM_BUILD_ROOT -%__mkdir -p $RPM_BUILD_ROOT/usr/share/rec10/rectool/ -%__mkdir -p $RPM_BUILD_ROOT/etc/httpd/conf.d/ -%__mkdir -p $RPM_BUILD_ROOT/var/www/html/rec10/ %build %install #rm -rf $RPM_BUILD_ROOT +%__mkdir -p $RPM_BUILD_ROOT/usr/share/rec10/rectool/ +%__mkdir -p $RPM_BUILD_ROOT/etc/httpd/conf.d/ +%__mkdir -p $RPM_BUILD_ROOT/var/www/html/rec10/ %__cp $RPM_SOURCE_DIR/rectool.pl $RPM_BUILD_ROOT/usr/share/rec10/rectool/ %__cp $RPM_SOURCE_DIR/rec10.conf $RPM_BUILD_ROOT/etc/httpd/conf.d/ ln -sf /usr/share/rec10/rectool/rectool.pl $RPM_BUILD_ROOT/var/www/html/rec10/ -- 2.11.0