WEBUI JS: DVR - fix the date filters, fix the file size rendering
This commit is contained in:
parent
17a8c50c26
commit
4a60cb8801
2 changed files with 15 additions and 7 deletions
|
@ -212,6 +212,17 @@ tvheadend.dvr_finished = function(panel, index) {
|
|||
list: 'disp_title,episode,start_real,stop_real,' +
|
||||
'duration,filesize,channelname,creator,' +
|
||||
'sched_status,url',
|
||||
columns: {
|
||||
filesize: {
|
||||
renderer: function() {
|
||||
return function(v) {
|
||||
if (v == null)
|
||||
return '';
|
||||
return parseInt(v / 1000000) + ' MB';
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
sort: {
|
||||
field: 'start',
|
||||
direction: 'DESC'
|
||||
|
|
|
@ -135,6 +135,7 @@ tvheadend.IdNodeField = function(conf)
|
|||
|
||||
this.column = function(conf)
|
||||
{
|
||||
var cfg = conf && this.id in conf ? conf[this.id] : {};
|
||||
var w = 300;
|
||||
var ftype = 'string';
|
||||
if (this.type === 'int' || this.type === 'u32' ||
|
||||
|
@ -144,6 +145,7 @@ tvheadend.IdNodeField = function(conf)
|
|||
w = 80;
|
||||
} else if (this.type === 'time') {
|
||||
w = 120;
|
||||
ftype = 'date';
|
||||
if (this.durations) {
|
||||
ftype = 'numeric';
|
||||
w = 80;
|
||||
|
@ -155,17 +157,12 @@ tvheadend.IdNodeField = function(conf)
|
|||
if (this.enum || this.list)
|
||||
w = 300;
|
||||
|
||||
if (conf && this.id in conf) {
|
||||
if (conf[this.id].width)
|
||||
w = conf[this.id].width;
|
||||
}
|
||||
|
||||
var props = {
|
||||
width: w,
|
||||
width: cfg.width || w,
|
||||
dataIndex: this.id,
|
||||
header: this.text,
|
||||
editor: this.editor({create: false}),
|
||||
renderer: this.renderer(),
|
||||
renderer: cfg.renderer ? cfg.renderer() : this.renderer(),
|
||||
editable: !this.rdonly,
|
||||
hidden: this.hidden,
|
||||
filter: {
|
||||
|
|
Loading…
Add table
Reference in a new issue