Fetching next_download for each channel.

This commit is contained in:
Roland 2022-01-15 13:52:43 -07:00
parent 4f770bd215
commit fa0ccedd8b
No known key found for this signature in database
GPG key ID: 9D6DBD3ACF11AB93

View file

@ -24,7 +24,8 @@ async def get_minimal_channels() -> List[dict]:
# Get all channels, even if they don't have videos.
stmt = '''
SELECT
c.id, name, link, directory, url, download_frequency, info_date
c.id, name, link, directory, url, download_frequency, info_date,
(select next_download from download d where d.url=c.url) AS next_download
FROM
channel AS c
ORDER BY LOWER(name)