belaudiobooks / website

Catalog of belarusian audiobooks
GNU General Public License v3.0
33 stars 6 forks source link

Add links to reviews from livelib #63

Closed nbeloglazov closed 1 year ago

nbeloglazov commented 2 years ago

Many (most) more or less popular belarusian books have reviews on livelib.ru. We should add link on each audiobook page to the corresponding page on livelib so that users can quickly see reviews. Would be cool to even embed reviews, but livelib doesn't provide API yet, thread.

Example reviews for "Апошняя кніга пана А": https://www.livelib.ru/book/1004585776/reviews-aposhnyaya-kniga-pana-a-algerd-baharevich

frombrest commented 1 year ago

Does it make sense to generalize this task to add links to any review sources (not only livelib.ru)? i.e. create new model ReviewLink and relation One (book) - to - Many (ReviewLink) and probably ReviewLinkType (or possibly reuse current LinkType model)

As I understand we are going to attach links manually at least initially? Because it would be difficult fully automate that.

nbeloglazov commented 1 year ago

Currently I'm hesitating between two options: provide link to some other website containing reviews or provide ability for visitors to leave review on our site. At this point I doubt we can pull off our own review system: I don't see signs that visitors would like to leave reviews + leaving reviews on a site that's blocked in Belarus might feel risky to many.

As for your proposal multiple review sources for each book, let me first check if there are other potential sources. I'm sure there are other review platforms out there but maybe only livelib.ru has reviews for Belarusians books. And if that's the case I would keep it simple and didn't create one-to-many relationship.

frombrest commented 1 year ago

Any decisions on that? ⬆️

nbeloglazov commented 1 year ago

No, unfortunately not yet.

nbeloglazov commented 1 year ago

Got response. Yes, livelib is the main review platform and we should focus on it. I think we should start with a single review-platform link per book.

frombrest commented 1 year ago

So, task is:

  1. Add
    livelib_url = models.CharField(_('LiveLib URL'), max_length=256, blank=True,  default='')

    field to the book model.

  2. Add url to book_detail template.
  3. Add tests to make sure book_detail page shows url.

Question: Should we add some livelib icon to the static content to show near url?

Is that right? ⬆️

nbeloglazov commented 1 year ago

Yes, and a few more (optional) tasks.

  1. See if we can write a script to backfill existing books with livelib links.
  2. Update admin page for book creation to provide extra info on how to fill livelib field. If possible - add a link to the livelib search page.

Question: Should we add some livelib icon to the static content to show near url? No. Let's start with a simple "Водгукі на LiveLib" link.

nbeloglazov commented 1 year ago

Added livelib links that @frombrest gathered from the script. So we can officially consider it launched in prod!

nbeloglazov commented 1 year ago

@frombrest if you implement endpoint that returns list of livelib urls - I can add it to the admin page.

nbeloglazov commented 1 year ago

Ok. I think we are done with this feature!