git-svn-id: file:///root/webif/svn/pkg/webif/trunk@3246 2a923420-c742-0410-a762-8d5b09965624
This commit is contained in:
hummypkg 2016-09-01 16:49:01 +00:00
parent eda5ab7656
commit ddde3ecc4e
10 changed files with 71 additions and 18 deletions

View File

@ -1,10 +1,10 @@
Package: webif
Priority: optional
Section: web
Version: 1.3.2-4
Version: 1.3.2-5
Architecture: mipsel
Maintainer: af123@hpkg.tv
Depends: tcpfix,webif-channelicons(>=1.1.24),lighttpd(>=1.4.39-1),jim(>=0.76-2),jim-oo,jim-sqlite3(>=0.76),jim-cgi(>=0.7-1),jim-binary(>=0.76),service-control(>=2.1),busybox(>=1.20.2-1),lsof(>=4.87),epg(>=1.2.3),hmt(>=2.0.10),ssmtp,cron-daemon(>=1.18.3-3),at(>=3.1.18),anacron,trm(>=1.1),openssl-command,nicesplice,id3v2,file,rsvsync(>=1.1.6),webif-charts(>=1.2-1),stripts(>=1.2.5-3),tmenu(>=1.08),ffmpeg,id3v2,multienv(>=1.6),tcpping(>=1.1),e2fsprogs,wireless-tools(>=29-1),dbupdate,recmon(>=2.0.7),hwctl,nugget(>=0.94)
Depends: tcpfix,webif-channelicons(>=1.1.24),lighttpd(>=1.4.39-1),jim(>=0.76-2),jim-oo,jim-sqlite3(>=0.76),jim-cgi(>=0.7-1),jim-binary(>=0.76),service-control(>=2.1),busybox(>=1.20.2-1),lsof(>=4.87),epg(>=1.2.3),hmt(>=2.0.10),ssmtp,cron-daemon(>=1.18.3-3),at(>=3.1.18),anacron,trm(>=1.1),openssl-command,nicesplice,id3v2,file,rsvsync(>=1.1.8),webif-charts(>=1.2-1),stripts(>=1.2.5-3),tmenu(>=1.08),ffmpeg,id3v2,multienv(>=1.6),tcpping(>=1.1),e2fsprogs,wireless-tools(>=29-1),dbupdate,recmon(>=2.0.7),hwctl,nugget(>=0.94)
Suggests:
Description: An evolving web interface for the Humax.
Tags: http://hummy.tv/forum/threads/7116/

View File

@ -2,10 +2,15 @@
package require cgi
source /mod/webif/lib/setup
require epg.class spinner.class altrow
require epg.class spinner.class altrow findhsvc
jqplugin iphone-style-checkboxes freezeheader scrollto
jscss service.js service.css
set service [cgi_get service 4170]
set chname [system strip [get_channel_attr_bysvc $service szSvcName]]
setpagetag "EPG - $chname"
header
require totop
@ -18,7 +23,6 @@ require totop
require epg_popup
set service [cgi_get service 4170]
set records [epg dbfetch dump \
-service $service \
-sort "strftime('%%H%%J', start, 'unixepoch', 'localtime'), strftime('%%M', start, 'unixepoch')" \

BIN
webif/html/img/aractive.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

View File

@ -10,8 +10,11 @@ puts {
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>
}
source /mod/webif/include/model.jim
puts $::mws::pagetitle
incr ::mws::headerdone
puts {
</title>
<meta http-equiv=X-UA-Compatible content="IE=edge,chrome=1" />

View File

@ -17,7 +17,7 @@ puts {
<span style="display: inline; font-size: 150%;
padding: 0 0 0 2em;">
}
source /mod/webif/include/model.jim
puts $::mws::pagetitle
source /mod/webif/include/upgrade.jim
puts {
</span>

View File

@ -207,15 +207,7 @@ proc eventrow {event {table TBL_RESERVATION}} {
puts "<span class=ds>$ds</span>"
}
if {$showing == 2} {
# AR watch
puts "
<span class=relative>
<img class=\"stackimg va\" src=/img/ar.png>
<img class=\"stackimg va\" src=/img/ripple.gif>
</span>
"
} elseif {$showing} {
if {$showing == 1} {
set perc $(($n - ($s - $sp)) * 100 / \
($d + $sp + $ep))
puts "<br>"

View File

@ -1,3 +0,0 @@
puts "Humax [system model] Fox T2 ([system hostname])"

View File

@ -67,5 +67,21 @@ if {![exists -proc get_channel_attr]} {
}
return 0
}
proc get_channel_attr_bysvc {svc {field usLcn}} {
global rsvdb
set ff [$rsvdb query "
select $field
from channel.TBL_SVC
where usSvcId = $svc
limit 1
"]
if {[llength $ff] == 1} {
return [lindex [lindex $ff 0] 1]
}
return 0
}
}

View File

@ -236,6 +236,9 @@ rsv method iconset {{height 20}} {
lappend iconlist \
"<img src=/img/pad.png height=$height
title=\"$padding\" alt=\"$padding\">"
} elseif {[$self status] eq "arwatch"} {
lappend iconlist \
"<img src=/img/aractive.gif height=$height>"
} else {
lappend iconlist \
"<img src=/img/ar.png height=$height>"

View File

@ -48,8 +48,46 @@ if {![exists -proc require]} {
set done 1
}
proc setpagetag {name} {
set ::mws::pagetag $name
}
proc ::mws::setpagetitle {} {
global env
if {[info exists ::mws::pagetitle]} return
if {![dict exists $env REQUEST_URI]} return
if {![info exists ::mws::pagetag]} {
switch -glob -- $env(REQUEST_URI) {
"/sched/*" { set ::mws::pagetag "Schedule" }
"/diag/*" { set ::mws::pagetag "Diagnostics" }
"/browse/*" { set ::mws::pagetag "Browse Files" }
"/xepg/*" { set ::mws::pagetag "EPG" }
"/settings/*" { set ::mws::pagetag "Settings" }
"/services/*" { set ::mws::pagetag "Services" }
"/pkg/*" { set ::mws::pagetag "Packages" }
"/cgi-bin/*" { set ::mws::pagetag "" }
default {
set _xpath [split $env(REQUEST_URI) /]
if {[llength $_xpath] > 2} {
set ::mws::pagetag [string totitle [\
lindex $_xpath 1]]
} else {
set ::mws::pagetag ""
}
}
}
}
set ::mws::pagetitle "Humax [system model] Fox T2 ([\
system hostname])"
if {$::mws::pagetag ne ""} {
append ::mws::pagetitle " - $::mws::pagetag"
}
}
proc header {{type "text/html"} {cache 0}} {
httpheader $type $cache
::mws::setpagetitle
uplevel source /mod/webif/html/lib/header.jim
incr ::mws::headerdone
}