Release plugin.video.themoviedb.helper - Access to TheMovieDb API for Skinners
(2023-11-03, 05:27)jurialmunkey Wrote: It can be done but is dependent on the user having enabled that setting. Ive been hesitant to allow skins to override that setting forcibly as it can cause problems/slow-downs for users with very large libraries.

You could use a variable though to check if the user has that setting enabled and only apply the filter if they do e.g.
Code:
<value condition="Addon.SettingBool(plugin.video.themoviedb.helper,local_db)">

In terms of filtering by DBID it's as simple as adding:
Code:
&amp;exclude_key=dbid&amp;exclude_value=is_empty

e.g. for Recommendations dialog, say you want Recommended movies but only ones in the library:
Code:
5000|info=recommendations&amp;exclude_key=dbid&amp;exclude_value=is_empty|true|info

Also note that excluding simply removes items from the page which don't match so you will end up with fewer items (e.g. page of 20 but only 4 in library then list will only have 4 recommendations).

To help with that, you might want to extend the page length param to retrieve more pages (more pages = slower so that's the obvious downside).
e.g. to get 40 recs instead of normal 20 bump length to 2
Code:
5000|info=recommendations&amp;length=2&amp;exclude_key=dbid&amp;exclude_value=is_empty|true|info


Side note: You might also be interested in the filter dir functionality in SkinVariables which allows you to apply the same type of filtering to other plugins and library paths:
https://github.com/jurialmunkey/script.s...irectories

I probably have a decently large library but I also run Kodi on what most would consider a top of the line PC. Likely not the worst case scenario for this particular functionality, however, I have not noticed any issues at all Tongue

Does that setting being enabled also place the items with those in the library before those that are not?

That is what I currently notice and also use
xml:
<visible>!String.IsEmpty(ListItem.DBID)</visible>
to show an icon that it is in the library in the recommendations window. Does that visible only work when that setting is enabled?

Honestly, my main reason for wanting to switch to TMDbH is not only cause it is actively developed and maintained but I have wanted to be able to browse items using DialogVideoInfo and your script is the only one that does it perfectly.

In my mind I have two separate "workflows".
The first is inside DialogVideoInfo and that is local content only. The second is the Recommendations Dialog which is all content, local or not.

I wanted to use the add_path method since it opened info for the item directly. I originally thought it was just the videodb:// path cause that is what I saw in a test label so I used INFO[Container(xxx).FolderPath]$INFO[Container(xxx).ListItem.DBID] to replicate that but messing about with it further I realized that add_path=$INFO[ListItem.FolderPath], when the content is provided by TMDbH, is its own unique plugin path. I did see the other option using add_query= but that often brought up a select dialog to fine tune and since the item is in my library I figured it should already know what movie it was.

Not sure if all that made any sense but long story short I wanted to not have that search dialog pop up so that is what I have been trying to, unsuccessfully, accomplish for the past few days Laugh

I will definitely have to look further into SkinVariables. Someone just recently posted in my forum about wanting me to use it for what looks like the Viewtype Builder in the Wiki.

Thank you Smile
Reply


Messages In This Thread
RE: TheMovieDB Helper - by jurialmunkey - 2019-07-31, 11:47
RE: plugin.video.themoviedb.helper - Access to TheMovieDb API for Skinners - by mikeSiLVO - 2023-11-03, 07:55
Logout Mark Read Team Forum Stats Members Help
plugin.video.themoviedb.helper - Access to TheMovieDb API for Skinners2