parent
1fa23ab411
commit
4c902f929c
@ -1,67 +0,0 @@
|
|||||||
##############################################################################
|
|
||||||
# FlixPatrol Charts Collections #
|
|
||||||
# Created by Yozora, Bullmoose20, anon_fawkes, & Sohjiro #
|
|
||||||
# EDITING THIS FILE MAY CAUSE PULLING NEW UPDATES TO FAIL #
|
|
||||||
# https://metamanager.wiki/en/latest/defaults/chart/flixpatrol #
|
|
||||||
##############################################################################
|
|
||||||
|
|
||||||
external_templates:
|
|
||||||
pmm: templates
|
|
||||||
template_variables:
|
|
||||||
collection_section: "020"
|
|
||||||
pre: "_#"
|
|
||||||
|
|
||||||
templates:
|
|
||||||
flixpatrol:
|
|
||||||
default:
|
|
||||||
location: world
|
|
||||||
location_<<key>>: <<location>>
|
|
||||||
in_the_last: 1
|
|
||||||
in_the_last_<<key>>: <<in_the_last>>
|
|
||||||
limit: 10
|
|
||||||
limit_<<key>>: <<limit>>
|
|
||||||
conditionals:
|
|
||||||
actual_location:
|
|
||||||
default: <<location_<<key>>>>
|
|
||||||
conditions:
|
|
||||||
- key: apple
|
|
||||||
value: world
|
|
||||||
limit: <<limit>>
|
|
||||||
flixpatrol_top:
|
|
||||||
platform: <<platform>>
|
|
||||||
location: <<actual_location>>
|
|
||||||
in_the_last: <<in_the_last_<<key>>>>
|
|
||||||
limit: <<limit_<<key>>>>
|
|
||||||
|
|
||||||
dynamic_collections:
|
|
||||||
FlixPatrol:
|
|
||||||
type: custom
|
|
||||||
data:
|
|
||||||
netflix: Netflix
|
|
||||||
disney: Disney+
|
|
||||||
max: Max
|
|
||||||
hulu: Hulu
|
|
||||||
paramount: Paramount+
|
|
||||||
prime: Prime Video
|
|
||||||
apple: Apple TV+
|
|
||||||
title_format: <<key_name>> Top <<limit>>
|
|
||||||
template:
|
|
||||||
- flixpatrol
|
|
||||||
- shared
|
|
||||||
- arr
|
|
||||||
- custom
|
|
||||||
template_variables:
|
|
||||||
limit:
|
|
||||||
default: 10
|
|
||||||
platform:
|
|
||||||
default: <<key>>
|
|
||||||
max: hbo
|
|
||||||
paramount: paramount_plus
|
|
||||||
prime: amazon_prime
|
|
||||||
apple: apple_tv
|
|
||||||
image:
|
|
||||||
default: chart/<<key>>_top
|
|
||||||
translation_key:
|
|
||||||
default: flixpatrol
|
|
||||||
dynamic:
|
|
||||||
default: true
|
|
@ -1,104 +0,0 @@
|
|||||||
##############################################################################
|
|
||||||
# FlixPatrol Overlays #
|
|
||||||
# Created by Yozora, Bullmoose20, anon_fawkes, & Sohjiro #
|
|
||||||
# EDITING THIS FILE MAY CAUSE PULLING NEW UPDATES TO FAIL #
|
|
||||||
# https://metamanager.wiki/en/latest/defaults/overlays/flixpatrol #
|
|
||||||
##############################################################################
|
|
||||||
|
|
||||||
external_templates:
|
|
||||||
pmm: templates
|
|
||||||
template_variables:
|
|
||||||
default:
|
|
||||||
pre_text: TOP
|
|
||||||
style: round
|
|
||||||
limit: 10
|
|
||||||
limit_<<key>>: <<limit>>
|
|
||||||
conditionals:
|
|
||||||
pmm:
|
|
||||||
conditions:
|
|
||||||
- file.exists: false
|
|
||||||
file_<<key>>.exists: false
|
|
||||||
url.exists: false
|
|
||||||
url_<<key>>.exists: false
|
|
||||||
git.exists: false
|
|
||||||
git_<<key>>.exists: false
|
|
||||||
repo.exists: false
|
|
||||||
repo_<<key>>.exists: false
|
|
||||||
value: logo/<<style>>/<<key>>
|
|
||||||
queue: position
|
|
||||||
back_color: "#00000099"
|
|
||||||
back_width: 160
|
|
||||||
back_height: 160
|
|
||||||
font_size: 50
|
|
||||||
addon_position: top
|
|
||||||
addon_offset: 30
|
|
||||||
back_padding: 15
|
|
||||||
final_name: text(<<pre_text>><<limit_<<key>>>>)
|
|
||||||
|
|
||||||
queues:
|
|
||||||
position:
|
|
||||||
default:
|
|
||||||
horizontal_offset: 30
|
|
||||||
vertical_offset: 465
|
|
||||||
vertical_align: top
|
|
||||||
right:
|
|
||||||
- horizontal_align: right
|
|
||||||
- vertical_offset: 670
|
|
||||||
- vertical_offset: 875
|
|
||||||
left:
|
|
||||||
- horizontal_align: left
|
|
||||||
- vertical_offset: 670
|
|
||||||
- vertical_offset: 875
|
|
||||||
|
|
||||||
templates:
|
|
||||||
flixpatrol:
|
|
||||||
default:
|
|
||||||
slug: <<key>>
|
|
||||||
location: world
|
|
||||||
location_<<key>>: <<location>>
|
|
||||||
in_the_last: 1
|
|
||||||
in_the_last_<<key>>: <<in_the_last>>
|
|
||||||
limit: 10
|
|
||||||
limit_<<key>>: <<limit>>
|
|
||||||
conditionals:
|
|
||||||
actual_location:
|
|
||||||
default: <<location_<<key>>>>
|
|
||||||
conditions:
|
|
||||||
- key: apple
|
|
||||||
value: world
|
|
||||||
ignore_blank_results: true
|
|
||||||
flixpatrol_top:
|
|
||||||
platform: <<slug>>
|
|
||||||
location: <<actual_location>>
|
|
||||||
in_the_last: <<in_the_last_<<key>>>>
|
|
||||||
limit: <<limit_<<key>>>>
|
|
||||||
|
|
||||||
overlays:
|
|
||||||
|
|
||||||
Netflix:
|
|
||||||
variables: {key: netflix, weight: 60}
|
|
||||||
template: [name: standard, name: flixpatrol]
|
|
||||||
|
|
||||||
Disney:
|
|
||||||
variables: {key: disney, weight: 50}
|
|
||||||
template: [name: standard, name: flixpatrol]
|
|
||||||
|
|
||||||
Max:
|
|
||||||
variables: {key: max, weight: 40, slug: hbo}
|
|
||||||
template: [name: standard, name: flixpatrol]
|
|
||||||
|
|
||||||
Hulu:
|
|
||||||
variables: {key: hulu, weight: 30}
|
|
||||||
template: [name: standard, name: flixpatrol]
|
|
||||||
|
|
||||||
Paramount:
|
|
||||||
variables: {key: paramount, weight: 20, slug: paramount_plus}
|
|
||||||
template: [name: standard, name: flixpatrol]
|
|
||||||
|
|
||||||
Prime:
|
|
||||||
variables: {key: prime, weight: 10, slug: amazon_prime}
|
|
||||||
template: [name: standard, name: flixpatrol]
|
|
||||||
|
|
||||||
Apple:
|
|
||||||
variables: {key: apple, weight: 9, slug: apple_tv}
|
|
||||||
template: [name: standard, name: flixpatrol]
|
|
@ -1,94 +0,0 @@
|
|||||||
# FlixPatrol Charts Collections
|
|
||||||
|
|
||||||
The `flixpatrol` Default Collection File is used to create collections based on FlixPatrol Charts.
|
|
||||||
|
|
||||||
![](../images/flixpatrol.png)
|
|
||||||
|
|
||||||
## Requirements & Recommendations
|
|
||||||
|
|
||||||
Supported Library Types: Movie, Show
|
|
||||||
|
|
||||||
## Collections Section 020
|
|
||||||
|
|
||||||
| Collection | Key | Description |
|
|
||||||
|:----------------------------------|:------------|:---------------------------------------------------------------------------|
|
|
||||||
| `Netflix Top 10 Movies/Shows` | `netflix` | Collection of the Top Movies/Shows on Netflix according to FlixPatrol. |
|
|
||||||
| `Disney+ Top 10 Movies/Shows` | `disney` | Collection of the Top Movies/Shows on Disney+ according to FlixPatrol. |
|
|
||||||
| `MAX Top 10 Movies/Shows` | `max` | Collection of the Top Movies/Shows on MAX according to FlixPatrol. |
|
|
||||||
| `Hulu Top 10 Movies/Shows` | `hulu` | Collection of the Top Movies/Shows on Hulu according to FlixPatrol. |
|
|
||||||
| `Paramount+ Top 10 Movies/Shows` | `paramount` | Collection of the Top Movies/Shows on Paramount+ according to FlixPatrol. |
|
|
||||||
| `Prime Video Top 10 Movies/Shows` | `prime` | Collection of the Top Movies/Shows on Prime Video according to FlixPatrol. |
|
|
||||||
| `Apple+ Top 10 Movies/Shows` | `apple` | Collection of the Top Movies/Shows on Apple+ according to FlixPatrol. |
|
|
||||||
|
|
||||||
## Config
|
|
||||||
|
|
||||||
The below YAML in your config.yml will create the collections:
|
|
||||||
|
|
||||||
```yaml
|
|
||||||
libraries:
|
|
||||||
Movies:
|
|
||||||
collection_files:
|
|
||||||
- pmm: flixpatrol
|
|
||||||
TV Shows:
|
|
||||||
collection_files:
|
|
||||||
- pmm: flixpatrol
|
|
||||||
```
|
|
||||||
|
|
||||||
## Template Variables
|
|
||||||
|
|
||||||
Template Variables can be used to manipulate the file in various ways to slightly change how it works without having to
|
|
||||||
make your own local copy.
|
|
||||||
|
|
||||||
Note that the `template_variables:` section only needs to be used if you do want to actually change how the defaults
|
|
||||||
work. Any value not specified will use its default value if it has one if not it's just ignored.
|
|
||||||
|
|
||||||
??? abstract "Variable Lists (click to expand)"
|
|
||||||
|
|
||||||
* **File-Specific Template Variables** are variables available specifically for this PMM Defaults file.
|
|
||||||
|
|
||||||
* **Shared Template Variables** are additional variables shared across the PMM Defaults.
|
|
||||||
|
|
||||||
???+ warning
|
|
||||||
|
|
||||||
Due to Flixpatrol data limitations, Apple TV only works with the `world` location. If you set a country-specific location, Apple TV will fall-back to using the `world` location.
|
|
||||||
|
|
||||||
=== "File-Specific Template Variables"
|
|
||||||
|
|
||||||
| Variable | Description & Values |
|
|
||||||
|:---------------------------------------|:------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
|
||||||
| `limit` | **Description:** Changes the Builder Limit for all collections in a Defaults file.<br>**Default:** `10`<br>**Values:** Any Number 1-10 |
|
|
||||||
| `limit_<<key>>`<sup>1</sup> | **Description:** Changes the Builder Limit of the specified key's collection.<br>**Default:** `limit`<br>**Values:** Any Number 1-10 |
|
|
||||||
| `in_the_last` | **Description:** Changes How many days of daily Top 10 Lists to look at.<br>**Default:** `1`<br>**Values:** Any Number 1-30 |
|
|
||||||
| `in_the_last_<<key>>`<sup>1</sup> | **Description:** Changes How many days of daily Top 10 Lists to look at.<br>**Default:** `in_the_last`<br>**Values:** Any Number 1-30 |
|
|
||||||
| `location` | **Description:** Changes the Builder Location for all collections in a Defaults file.<br>**Default:** `world`<br>**Values:** [`location` Attribute Options](../../files/builders/flixpatrol.md#top-platform-attributes) |
|
|
||||||
| `location_<<key>>`<sup>1</sup> | **Description:** Changes the Builder Location of the specified key's collection.<br>**Default:** `location`<br>**Values:** [`location` Attribute Options](../../files/builders/flixpatrol.md#top-platform-attributes) |
|
|
||||||
| `sync_mode` | **Description:** Changes the Sync Mode for all collections in a Defaults file.<br>**Default:** `sync`<br>**Values:**<table class="clearTable"><tr><td>`sync`</td><td>Add and Remove Items based on Builders</td></tr><tr><td>`append`</td><td>Only Add Items based on Builders</td></tr></table> |
|
|
||||||
| `sync_mode_<<key>>`<sup>1</sup> | **Description:** Changes the Sync Mode of the specified key's collection.<br>**Default:** `sync_mode`<br>**Values:**<table class="clearTable"><tr><td>`sync`</td><td>Add and Remove Items based on Builders</td></tr><tr><td>`append`</td><td>Only Add Items based on Builders</td></tr></table> |
|
|
||||||
| `collection_order` | **Description:** Changes the Collection Order for all collections in a Defaults file.<br>**Default:** `custom`<br>**Values:**<table class="clearTable"><tr><td>`release`</td><td>Order Collection by Release Dates</td></tr><tr><td>`alpha`</td><td>Order Collection Alphabetically</td></tr><tr><td>`custom`</td><td>Order Collection Via the Builder Order</td></tr><tr><td>[Any `plex_search` Sort Option](../../files/builders/plex.md#sort-options)</td><td>Order Collection by any `plex_search` Sort Option</td></tr></table> |
|
|
||||||
| `collection_order_<<key>>`<sup>1</sup> | **Description:** Changes the Collection Order of the specified key's collection.<br>**Default:** `collection_order`<br>**Values:**<table class="clearTable"><tr><td>`release`</td><td>Order Collection by Release Dates</td></tr><tr><td>`alpha`</td><td>Order Collection Alphabetically</td></tr><tr><td>`custom`</td><td>Order Collection Via the Builder Order</td></tr><tr><td>[Any `plex_search` Sort Option](../../files/builders/plex.md#sort-options)</td><td>Order Collection by any `plex_search` Sort Option</td></tr></table> |
|
|
||||||
|
|
||||||
1. Each default collection has a `key` that when calling to effect a specific collection you must replace
|
|
||||||
`<<key>>` with when calling.
|
|
||||||
|
|
||||||
=== "Shared Template Variables"
|
|
||||||
|
|
||||||
{%
|
|
||||||
include-markdown "../collection_variables.md"
|
|
||||||
%}
|
|
||||||
|
|
||||||
???+ example "Example Template Variable Amendments"
|
|
||||||
|
|
||||||
The below is an example config.yml extract with some Template Variables added in to change how the file works.
|
|
||||||
|
|
||||||
Click the :fontawesome-solid-circle-plus: icon to learn more
|
|
||||||
|
|
||||||
```yaml
|
|
||||||
libraries:
|
|
||||||
Movies:
|
|
||||||
collection_files:
|
|
||||||
- pmm: flixpatrol
|
|
||||||
template_variables:
|
|
||||||
location: united_states #(1)!
|
|
||||||
```
|
|
||||||
|
|
||||||
1. Change the location of the FlixPatrol collections to the United States of America
|
|
@ -1,115 +0,0 @@
|
|||||||
# FlixPatrol Top Overlays
|
|
||||||
|
|
||||||
The `flixpatrol` Default Overlay File is used to create an overlay based on the Top Lists from FlixPatrol on items
|
|
||||||
within your library.
|
|
||||||
|
|
||||||
![](images/flixpatrol.png)
|
|
||||||
|
|
||||||
## Requirements & Recommendations
|
|
||||||
|
|
||||||
Supported Overlay Level: Movie, Show
|
|
||||||
|
|
||||||
## Supported Services
|
|
||||||
|
|
||||||
| Service | Key | Weight |
|
|
||||||
|:------------|:------------|:-------|
|
|
||||||
| Netflix | `netflix` | `60` |
|
|
||||||
| Disney+ | `disney` | `50` |
|
|
||||||
| MAX | `max` | `40` |
|
|
||||||
| Hulu | `hulu` | `30` |
|
|
||||||
| Paramount+ | `paramount` | `20` |
|
|
||||||
| Prime Video | `prime` | `10` |
|
|
||||||
| Apple+ | `apple` | `9` |
|
|
||||||
|
|
||||||
## Config
|
|
||||||
|
|
||||||
The below YAML in your config.yml will create the overlays:
|
|
||||||
|
|
||||||
```yaml
|
|
||||||
libraries:
|
|
||||||
Movies:
|
|
||||||
overlay_files:
|
|
||||||
- pmm: flixpatrol
|
|
||||||
TV Shows:
|
|
||||||
overlay_files:
|
|
||||||
- pmm: flixpatrol
|
|
||||||
```
|
|
||||||
|
|
||||||
## Template Variables
|
|
||||||
|
|
||||||
Template Variables can be used to manipulate the file in various ways to slightly change how it works without having to
|
|
||||||
make your own local copy.
|
|
||||||
|
|
||||||
Note that the `template_variables:` section only needs to be used if you do want to actually change how the defaults
|
|
||||||
work. Any value not specified will use its default value if it has one if not it's just ignored.
|
|
||||||
|
|
||||||
??? abstract "Variable Lists (click to expand)"
|
|
||||||
|
|
||||||
* **File-Specific Template Variables** are variables available specifically for this PMM Defaults file.
|
|
||||||
|
|
||||||
* **Overlay Template Variables** are additional variables shared across the PMM Overlay Defaults.
|
|
||||||
|
|
||||||
* **Overlay Text Template Variables** are additional variables shared across the PMM Text Overlay Defaults.
|
|
||||||
|
|
||||||
??? example "Default Template Variable Values (click to expand)"
|
|
||||||
|
|
||||||
| Variable | Default |
|
|
||||||
|:--------------------|:------------------|
|
|
||||||
| `horizontal_offset` | `30` |
|
|
||||||
| `horizontal_align` | `left`/`right` |
|
|
||||||
| `vertical_offset` | `465`/`670`/`875` |
|
|
||||||
| `vertical_align` | `top` |
|
|
||||||
| `back_color` | `#00000099` |
|
|
||||||
| `back_radius` | `30` |
|
|
||||||
| `back_width` | `160` |
|
|
||||||
| `back_height` | `160` |
|
|
||||||
| `back_padding` | `15` |
|
|
||||||
|
|
||||||
???+ bug "Warning"
|
|
||||||
|
|
||||||
`horizontal_offset`, `horizontal_align`, `vertical_offset`, and `vertical_align` are NOT available for use in this file
|
|
||||||
|
|
||||||
=== "File-Specific Template Variables"
|
|
||||||
|
|
||||||
| Variable | Description & Values |
|
|
||||||
|:----------------------------------|:---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
|
||||||
| `position` | **Description:** Changes the position of the Overlays.<br>**Default:** `right`<br>**Values:** `right`, `left`, or List of Coordinates |
|
|
||||||
| `style` | **Description:** Changes the style of the Logo Image.<br>**Default:** `round`<br>**Values:** `round` or `square` |
|
|
||||||
| `pre_text` | **Description:** Changes the text before the number.<br>**Default:** `TOP`<br>**Values:** Any String |
|
|
||||||
| `limit` | **Description:** Changes the Builder Limit for all overlays in a Defaults file.<br>**Default:** `10`<br>**Values:** Any Number 1-10 |
|
|
||||||
| `limit_<<key>>`<sup>1</sup> | **Description:** Changes the Builder Limit of the specified key's overlay.<br>**Default:** `limit`<br>**Values:** Any Number 1-10 |
|
|
||||||
| `location` | **Description:** Changes the Builder Location for all overlays in a Defaults file.<br>**Default:** `world`<br>**Values:** [`location` Attribute Options](../../files/builders/flixpatrol.md#top-platform-attributes) |
|
|
||||||
| `location_<<key>>`<sup>1</sup> | **Description:** Changes the Builder Location of the specified key's overlay.<br>**Default:** `location`<br>**Values:** [`location` Attribute Options](../../files/builders/flixpatrol.md#top-platform-attributes) |
|
|
||||||
| `in_the_last` | **Description:** Changes How many days of daily Top 10 Lists to look at.<br>**Default:** `1`<br>**Values:** Any Number 1-30 |
|
|
||||||
| `in_the_last_<<key>>`<sup>1</sup> | **Description:** Changes How many days of daily Top 10 Lists to look at.<br>**Default:** `in_the_last`<br>**Values:** Any Number 1-30 |
|
|
||||||
| `weight_<<key>>`<sup>1</sup> | **Description:** Controls the weight of the Overlay. Higher numbers have priority.<br>**Values:** Any Number |
|
|
||||||
| `addon_offset` | **Description:** Text Addon Image Offset from the text.<br>**Default:** `30`<br>**Values:** Any Number greater than 0 |
|
|
||||||
| `addon_position` | **Description:** Text Addon Image Alignment in relation to the text.<br>**Default:** `top`<br>**Values:** `left`, `right`, `top`, `bottom` |
|
|
||||||
|
|
||||||
1. Each default overlay has a `key` that when calling to effect a specific overlay you must replace `<<key>>`
|
|
||||||
with when calling.
|
|
||||||
|
|
||||||
=== "Overlay Template Variables"
|
|
||||||
|
|
||||||
{%
|
|
||||||
include-markdown "../overlay_variables.md"
|
|
||||||
%}
|
|
||||||
|
|
||||||
=== "Overlay Text Template Variables"
|
|
||||||
|
|
||||||
{%
|
|
||||||
include-markdown "../overlay_text_variables.md"
|
|
||||||
%}
|
|
||||||
|
|
||||||
???+ example "Example Template Variable Amendments"
|
|
||||||
|
|
||||||
The below is an example config.yml extract with some Template Variables added in to change how the file works.
|
|
||||||
|
|
||||||
```yaml
|
|
||||||
libraries:
|
|
||||||
Movies:
|
|
||||||
overlay_files:
|
|
||||||
- pmm: flixpatrol
|
|
||||||
template_variables:
|
|
||||||
location: united_states
|
|
||||||
```
|
|
@ -1,37 +0,0 @@
|
|||||||
# FlixPatrol Builders
|
|
||||||
|
|
||||||
You can find items using the features of [FlixPatrol.com](https://flixpatrol.com/) (FlixPatrol).
|
|
||||||
|
|
||||||
No configuration is required for this builder.
|
|
||||||
|
|
||||||
| Attribute | Description | Works with Movies | Works with Shows | Works with Playlists and Custom Sort |
|
|
||||||
|:---------------------------------------------|:-------------------------------------------------------------------------------------------------------------------------|:------------------------------------------:|:------------------------------------------:|:------------------------------------------:|
|
|
||||||
| [`flixpatrol_top`](#flixpatrol-top-platform) | Finds every item from [FlixPatrol's Top Platform Lists](https://flixpatrol.com/top10/) based on the attributes provided. | :fontawesome-solid-circle-check:{ .green } | :fontawesome-solid-circle-check:{ .green } | :fontawesome-solid-circle-check:{ .green } |
|
|
||||||
|
|
||||||
## FlixPatrol Top Platform
|
|
||||||
|
|
||||||
Finds every item from [FlixPatrol's Top Platform Lists](https://flixpatrol.com/top10/) based on the attributes provided.
|
|
||||||
|
|
||||||
The only required attribute is `platform`.
|
|
||||||
|
|
||||||
The `sync_mode: sync` and `collection_order: custom` Setting are recommended since the lists are continuously updated and in a specific order.
|
|
||||||
|
|
||||||
### Top Platform Attributes
|
|
||||||
|
|
||||||
| Attribute | Description & Values |
|
|
||||||
|:--------------|:----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
|
||||||
| `platform` | **Description:** Streaming Platform to filter on.<br>**Values:** `amazon_prime`, `apple_tv`, `chili`, `disney`, `freevee`, `globoplay`, `google`, `hbo`, `hulu`, `itunes`, `netflix`, `osn`, `paramount_plus`, `rakuten_tv`, `shahid`, `star_plus`, `starz`, `viaplay`, `vudu` |
|
|
||||||
| `location` | **Description:** Location to filter on.<br>**Default:** `world`<br>**Values:** `world`, `albania`, `algeria`, `angola`, `argentina`, `armenia`, `australia`, `austria`, `azerbaijan`, `bahamas`, `bahrain`, `bangladesh`, `belarus`, `belgium`, `belize`, `benin`, `bolivia`, `bosnia_and_herzegovina`, `botswana`, `brazil`, `bulgaria`, `burkina_faso`, `cambodia`, `cameroon`, `canada`, `chad`, `chile`, `colombia`, `costa_rica`, `croatia`, `cyprus`, `czech_republic`, `democratic_republic_of_the_congo`, `denmark`, `dominican_republic`, `ecuador`, `egypt`, `estonia`, `finland`, `france`, `gabon`, `georgia`, `germany`, `ghana`, `greece`, `guadeloupe`, `guatemala`, `guyana`, `haiti`, `honduras`, `hong_kong`, `hungary`, `iceland`, `india`, `indonesia`, `iraq`, `ireland`, `israel`, `italy`, `ivory_coast`, `jamaica`, `japan`, `jordan`, `kazakhstan`, `kenya`, `kuwait`, `kyrgyzstan`, `laos`, `latvia`, `lebanon`, `libya`, `lithuania`, `luxembourg`, `madagascar`, `malawi`, `malaysia`, `maldives`, `mali`, `malta`, `martinique`, `mauritania`, `mauritius`, `mexico`, `moldova`, `mongolia`, `montenegro`, `morocco`, `mozambique`, `myanmar`, `namibia`, `netherlands`, `new_caledonia`, `new_zealand`, `nicaragua`, `niger`, `nigeria`, `north_macedonia`, `norway`, `oman`, `pakistan`, `panama`, `papua_new_guinea`, `paraguay`, `peru`, `philippines`, `poland`, `portugal`, `qatar`, `republic_of_the_congo`, `reunion`, `romania`, `russia`, `rwanda`, `salvador`, `saudi_arabia`, `senegal`, `serbia`, `singapore`, `slovakia`, `slovenia`, `somalia`, `south_africa`, `south_korea`, `south_sudan`, `spain`, `sri_lanka`, `sweden`, `switzerland`, `taiwan`, `tajikistan`, `tanzania`, `thailand`, `togo`, `trinidad_and_tobago`, `tunisia`, `turkey`, `turkmenistan`, `uganda`, `ukraine`, `united_arab_emirates`, `united_kingdom`, `united_states`, `uruguay`, `uzbekistan`, `venezuela`, `vietnam`, `yemen`, `zambia`, `zimbabwe` |
|
|
||||||
| `limit` | **Description:** Number of items to return.<br>**Default:** `10`<br>**Values:** Integer greater than 0 |
|
|
||||||
| `in_the_last` | **Description:** Changes How many days of daily Top 10 Lists to look at.<br>**Default:** `1`<br>**Values:** Any Number 1-30 |
|
|
||||||
|
|
||||||
```yaml
|
|
||||||
collections:
|
|
||||||
US Netflix Monthly Top 10:
|
|
||||||
flixpatrol_top:
|
|
||||||
platform: netflix
|
|
||||||
location: united_states
|
|
||||||
limit: 10
|
|
||||||
collection_order: custom
|
|
||||||
sync_mode: sync
|
|
||||||
```
|
|
@ -1,59 +0,0 @@
|
|||||||
from modules import util
|
|
||||||
from modules.util import Failed
|
|
||||||
|
|
||||||
logger = util.logger
|
|
||||||
|
|
||||||
base_url = "https://raw.githubusercontent.com/meisnate12/PMM-TOP10/master/"
|
|
||||||
builders = ["flixpatrol_top"]
|
|
||||||
|
|
||||||
|
|
||||||
class FlixPatrol:
|
|
||||||
def __init__(self, config):
|
|
||||||
self.config = config
|
|
||||||
self._platforms = None
|
|
||||||
self._locations = None
|
|
||||||
self.country_data = {}
|
|
||||||
|
|
||||||
def load_info(self):
|
|
||||||
info = self.config.load_yaml(f"{base_url}info.yml")
|
|
||||||
self._platforms = info["platforms"]
|
|
||||||
self._locations = info["locations"]
|
|
||||||
|
|
||||||
def get_country(self, country):
|
|
||||||
if country not in self.country_data:
|
|
||||||
self.country_data[country] = self.config.load_yaml(f"{base_url}lists/{country}.yml")
|
|
||||||
return self.country_data[country]
|
|
||||||
|
|
||||||
@property
|
|
||||||
def platforms(self):
|
|
||||||
if self._platforms is None:
|
|
||||||
self.load_info()
|
|
||||||
return self._platforms
|
|
||||||
|
|
||||||
@property
|
|
||||||
def locations(self):
|
|
||||||
if self._locations is None:
|
|
||||||
self.load_info()
|
|
||||||
return self._locations
|
|
||||||
|
|
||||||
def get_tmdb_ids(self, method, data, is_movie):
|
|
||||||
flix_items = []
|
|
||||||
media_type = "movies" if is_movie else "shows"
|
|
||||||
if method == "flixpatrol_top":
|
|
||||||
logger.info(f"Processing FlixPatrol Top {media_type.capitalize()}:")
|
|
||||||
logger.info(f"\tPlatform: {data['platform'].replace('_', ' ').title()}")
|
|
||||||
logger.info(f"\tLocation: {data['location'].replace('_', ' ').title()}")
|
|
||||||
logger.info(f"\tIn The Last: {data['in_the_last']}")
|
|
||||||
logger.info(f"\tLimit: {data['limit']}")
|
|
||||||
country_info = self.get_country(data["location"])
|
|
||||||
for key in [k for k in country_info][:data["in_the_last"]]:
|
|
||||||
if data["platform"] in country_info[key] and media_type in country_info[key][data["platform"]]:
|
|
||||||
for item in country_info[key][data["platform"]][media_type]:
|
|
||||||
if item not in flix_items and len(flix_items) < data["limit"]:
|
|
||||||
flix_items.append(item)
|
|
||||||
items = [(i, "tmdb" if is_movie else "tmdb_show") for i in flix_items]
|
|
||||||
if len(items) > 0:
|
|
||||||
logger.info(f"Processed {len(items)} TMDb IDs")
|
|
||||||
return items
|
|
||||||
else:
|
|
||||||
raise Failed(f"FlixPatrol Error: No {media_type.capitalize()} Found for {data['platform'].replace('_', ' ').title()} in {data['location'].replace('_', ' ').title()}")
|
|
Loading…
Reference in new issue