2019-11-06, 23:28
(2019-11-06, 22:59)jurialmunkey Wrote: ListItem.IMDBNumber works fine for items in the Library Db.Thank you very much for your detailed explanation.
It's just add-ons that are unable to set it correctly. To get around it, with TMDbHelper I also set the value to a property:
ListItem.Property(imdb_id)
For other add-ons I check with a variable and put the appropriate "query=" or "imdb_id=" param:
xml:
<variable name="Info_Param_IMDB_or_QUERY">
<value condition="String.IsEqual(ListItem.DBType,movie) + !String.IsEmpty(ListItem.Property(imdb_id))">imdb_id=$INFO[ListItem.Property(imdb_id)]</value>
<value condition="String.IsEqual(ListItem.DBType,movie) + !String.IsEmpty(ListItem.IMDBNumber) + !String.StartsWith(ListItem.IMDBNumber,xx)">imdb_id=$INFO[ListItem.IMDBNumber]</value>
<value condition="[String.IsEqual(ListItem.DBType,tvshow) | String.IsEqual(ListItem.DBType,season) | String.IsEqual(ListItem.DBType,episode)] + !String.IsEmpty(ListItem.TvShowTitle)">query=$INFO[ListItem.TvShowTitle]</value>
<value condition="!String.IsEmpty(ListItem.Title) + !String.IsEmpty(ListItem.Year)">query=$INFO[ListItem.Title]&year=$INFO[ListItem.Year]</value>
<value condition="!String.IsEmpty(ListItem.Title)">query=$INFO[ListItem.Title]</value>
<value>query=$INFO[ListItem.Label]</value>
</variable>
i.e. Use it like so:
Code:plugin://plugin.video.themoviedb.helper/?info=recommendations&type=movie&$VAR[Info_Param_IMDB_or_QUERY]