wrolpi/modules/archive/schema.py
lrnselfreliance c23b014add
Feature/archive search (#70)
* Working through archive search.

* Using custom hook.

* Setting archive.contents duration creation.

* Archive search and domain list use custom hooks.

* Watching search param using value, not history.

* Search params are preserved on load.  Search and domain can be cleared.

* Fixing archive external link.

* Archive search form is new generic SearchInput.

* Reworking Archives empty states.

* Simplifying Archives logic.

* Fixing bug which displayed the wrong empty state during loading.

* Archives can be synced and deleted.

* Changing wording of archive delete.

* Removing URL table.

* Deleting domain if it has no archives.

* Fixing FE use of archive.url.  Fixing bug with get_domains.

* Universal results are displayed on Welcome page.

* Creating ExternalLink to open a link in a new tab.g

* Increasing size of search headers.

* Adding divider to ease reading.

* Adding More button below search results.

* Disabling More buttons when there are no results.

* Ordering videos by rank so linked results are at the top.

Signed-off-by: Roland <roland@learningselfreliance.com>
2022-01-03 15:13:38 -07:00

31 lines
685 B
Python

from sanic_openapi import doc
class ArchiveDict:
id = doc.Integer()
url_id = doc.Integer()
domain_id = doc.Integer()
singlefile_path = doc.String()
readability_path = doc.String()
readability_json_path = doc.String()
readability_txt_path = doc.String()
screenshot_path = doc.String()
title = doc.String()
archive_datetime = doc.DateTime()
class DomainDict:
id = doc.Integer()
domain = doc.String()
class ArchiveSearchRequest:
search_str = doc.String()
domain = doc.String()
offset = doc.Integer()
limit = doc.Integer()
class ArchiveSearchResponse:
videos = doc.List(ArchiveDict)
totals = doc.Dictionary()