diff --git a/CONTROL/control b/CONTROL/control index 58c41a2..ab0678a 100644 --- a/CONTROL/control +++ b/CONTROL/control @@ -1,10 +1,10 @@ Package: webif Priority: optional Section: web -Version: 1.2.0-5 +Version: 1.2.0-6 Architecture: mipsel Maintainer: af123@hummypkg.org.uk -Depends: webif-channelicons(>=1.1.14),lighttpd(>=1.4.35-2),jim(>=0.75-1),jim-oo,jim-sqlite3(>=0.75),jim-cgi(>=0.7),jim-binary(>=0.75),service-control(>=2.1),busybox(>=1.20.2-1),lsof(>=4.87),epg(>=1.2.0),hmt(>=1.2.0),ssmtp,anacron,trm(>=1.1),openssl-command,nicesplice,id3v2,file,rsvsync(>=1.0.2),webif-charts(>=1.2-1),stripts(>=1.2.5-3),smartmontools,tmenu(>=1.08),ffmpeg,id3v2,multienv(>=1.6),tcpping(>=1.1),e2fsprogs,wireless-tools(>=29-1),dbupdate,mongoose +Depends: webif-channelicons(>=1.1.14),lighttpd(>=1.4.35-2),jim(>=0.75-1),jim-oo,jim-sqlite3(>=0.75),jim-cgi(>=0.7),jim-binary(>=0.75),service-control(>=2.1),busybox(>=1.20.2-1),lsof(>=4.87),epg(>=1.2.0),hmt(>=2.0.0),ssmtp,anacron,trm(>=1.1),openssl-command,nicesplice,id3v2,file,rsvsync(>=1.0.2),webif-charts(>=1.2-1),stripts(>=1.2.5-3),smartmontools,tmenu(>=1.08),ffmpeg,id3v2,multienv(>=1.6),tcpping(>=1.1),e2fsprogs,wireless-tools(>=29-1),dbupdate,mongoose,recmon(>=2.0.2) Suggests: Description: An evolving web interface for the Humax. Tags: http://hummy.tv/forum/threads/5866/ diff --git a/etc/recmon.d/webiflog b/etc/recmon.d/webiflog new file mode 100755 index 0000000..a7e3b1c --- /dev/null +++ b/etc/recmon.d/webiflog @@ -0,0 +1,24 @@ +#!/mod/bin/jimsh + +source /mod/webif/lib/setup +require ts.class system.class + +set file [lindex $argv 0] +set ts [ts fetch "$file.ts"] +set root [system mediaroot] + +set dir [file dirname $file] +if {[string match "$root*" $dir]} { + set dir [string range $dir $([string length $root] + 1) end] +} +set ch [$ts get channel_name] +set dur [$ts duration] +set title [$ts get title] + +set msg "Recorded: $dir/$title ($dur minutes - $ch)" +set logfd [open "/mod/tmp/record.log" "a+"] +puts $logfd "[\ + clock format [clock seconds] -format "%d/%m/%Y %H:%M"\ + ] - $msg" +$logfd close + diff --git a/webif/html/browse/file.jim b/webif/html/browse/file.jim index 82c50e7..0fced0b 100755 --- a/webif/html/browse/file.jim +++ b/webif/html/browse/file.jim @@ -89,6 +89,9 @@ if {$type eq "ts"} { [$ts duration] minute(s). (Scheduled: [expr [$ts get scheddur] / 60]) + + Status + [$ts get status] Resumes [expr [$ts get resume] / 60] minutes into recording. diff --git a/webif/html/browse/index.jim b/webif/html/browse/index.jim index 2a1dcc3..e66eddd 100755 --- a/webif/html/browse/index.jim +++ b/webif/html/browse/index.jim @@ -117,7 +117,11 @@ proc entry {file} {{i 0}} { if {$ext eq ".ts" && [file exists "${base}.nts"]} { set type ts set ts [ts fetch $file 1] - set img Video_TS + if {[$ts get status] eq "Valid/OK"} { + set img Video_TS + } else { + set img Video_Failed + } set omenu opt if {[file exists "${base}.thm"]} { set thmok 1 } } elseif {$ext eq ".hmt"} { diff --git a/webif/html/img/Video_Failed_New.png b/webif/html/img/Video_Failed_New.png new file mode 100644 index 0000000..f893cdd Binary files /dev/null and b/webif/html/img/Video_Failed_New.png differ diff --git a/webif/lib/system.class b/webif/lib/system.class index b9f7d4f..d6ac9d3 100644 --- a/webif/lib/system.class +++ b/webif/lib/system.class @@ -134,6 +134,14 @@ proc {system mediaroot} {} { return "" } +proc {system dlnadb} {} { + switch [system model] { + HDR { return "/mnt/hd2/dms_cds.db" } + HD { return "/media/drive1/dms_cds.db" } + } + return "" +} + proc {system dustbin} {{short 0}} { set dustbin "\[Deleted Items\]" if {![catch {set fd [open "/mod/boot/dustbin.name" r]}]} { diff --git a/webif/lib/ts.class b/webif/lib/ts.class index 7ce560a..0148743 100644 --- a/webif/lib/ts.class +++ b/webif/lib/ts.class @@ -26,6 +26,7 @@ class ts { scheddur 0 genre 0 resume 0 + status "" } ts method bfile {} { @@ -52,7 +53,7 @@ ts method _parse {line} { lassign [split $line "\t"] \ title synopsis definition channel_num channel_name \ start end flags_list guidance bookmarks schedstart scheddur \ - genre resume + genre resume status set flags [split [string range $flags_list 0 end-1] ,] }