Opened 16 years ago

Closed 16 years ago

#5235 closed patch (fixed)

MythWeb Recordings Limit Patch

Reported by: jhoff@… Owned by: Rob Smith
Priority: minor Milestone: unknown
Component: mythweb Version: unknown
Severity: low Keywords:
Cc: Ticket locked: no

Description

So this is my first patch to MythWeb. Hell it's my first patch to anything, so it's not the cleanest approach, nor is it the most user-friendly, however what it lacks in style it makes up for in functionality.

Basically, it's a patch to add a "Limit" field to the "Recorded Programs" module for MythWeb. I got tired of my 500+ recordings loading everytime and I wanted to just have it truncate after displaying X amount of recordings.

I also added a textbox to the table that allows you to put in a "custom" limit ( the $Limit variable defined in modules/tv/recordings.php ). If no limit is specified, it will use the pre-defined limit, which is by default commented out. If left uncommented, it will always show everything.

Finally, there is a little modification to the "summary" line at the bottom to indicate how many recordings are being viewed.

Like I said, not the cleanest, but I know some people have been looking for something like this. Hopefully someone with a better feel for the modules can better integrate it, but for now, it works.

Should work against current SVN Trunk ( 17106 )

Attachments (1)

recorded_limit.patch (3.1 KB) - added by jhoff@… 16 years ago.
patch

Download all attachments as: .zip

Change History (6)

Changed 16 years ago by jhoff@…

Attachment: recorded_limit.patch added

patch

comment:1 Changed 16 years ago by jhoff@…

Sorry that 3rd section should have read:

I also added a textbox to the table that allows you to put in a "custom" limit. If no limit is specified, it will use the pre-defined limit, which is by default commented out ( $Limit - defined at the beginning of modules/tv/recordings.php ). If left uncommented, it will always show everything.

comment:2 in reply to:  1 Changed 16 years ago by jhoff@…

Wow. I need to proofread better I guess...

"If left commented, it will always show everything"

comment:3 Changed 16 years ago by anonymous

This seems like the wrong approach. You should enable some simple paging on recordings and limit to x recordings per page. The PHP code to do this is pretty simple and there are examples of this all over the place.

comment:4 Changed 16 years ago by Rob Smith

Owner: changed from xris to Rob Smith
Status: newaccepted

comment:5 Changed 16 years ago by Rob Smith

Resolution: fixed
Status: acceptedclosed

(In [17577]) Fixes #5235, this adds in paging for the recorded programs, default set to off, can be changed in Settings -> TV -> My Session -> Page recorded programs

Note: See TracTickets for help on using tickets.