Opened 6 years ago

#11501 new Patch - Feature

New MythFrontend Screen that displays result of custom SQL query

Reported by: raalph.a@… Owned by:
Priority: minor Milestone: unknown
Component: MythTV - General Version: Unspecified
Severity: low Keywords:
Cc: Ticket locked: no

Description

I've often wished I could tweak Myth FE program search functions (example: add a column to a search screen; list program titles only once instead of once for every showing; etc) Myth offers a lot of flexibility via Custom Record and themes, but obviously there are some limitations.

Another example, in my own implementation, I added a new "FavActor?" field to the person table, and I created my own movie search screen that displays a flag if a movie has one of my favorite actors in it.

The attached solution provides hooks into Myth Frontend that allows a user to define their own screen in an XML theme file which displays the results of their own SQL.

In brief, to use it,

  • Write your own SQL and store it in the settings table
  • Create a window in a new theme file (customqry-ui.xml) that refers to the columns in your SQL.
  • Modify the appropriate menu.xlm to add an action that calls your new screen.

The user can create multiple screens, each with it's own SQL and it's own layout of the results.

The patch is a minor modification to mythfrontend main.cpp, and addition of a new class, CustomQueryResult?. In an effort to limit users hosing their db, the only thing you can do with the results is display upcoming shows that have the same title as the selected item, and get program details for the selected item.

Usage details are in the attached readme file.

Attachments (2)

customqueryresult_readme.txt (12.7 KB) - added by anonymous 6 years ago.
customqueryresult.patch (19.9 KB) - added by raalph.a@… 6 years ago.
patch

Download all attachments as: .zip

Change History (2)

Changed 6 years ago by anonymous

Changed 6 years ago by raalph.a@…

Attachment: customqueryresult.patch added

patch

Note: See TracTickets for help on using tickets.