Add templates and clean up views for scrobbling
Biggest thing here is adding the ability to scrobble until the video is 95% done and then not scrobble the same video file again for 15 minutes. This seems hacky, but in practice works pretty well, so long as you don't monkey around with the 95% completion thing. Unlike music, videos are generally watched all the way through.
This commit is contained in:
@ -85,40 +85,32 @@
|
||||
<span class="navbar-toggler-icon"></span>
|
||||
</button>
|
||||
|
||||
{% if request.user.is_authenticated %}
|
||||
<div class="collapse navbar-collapse" id="navbarSupportedContent">
|
||||
<ul class="navbar-nav mr-auto">
|
||||
<li class="nav-item">
|
||||
<a class="nav-link" href="{% url 'home' %}">Recent<span class="sr-only"></span></a>
|
||||
</li>
|
||||
<li class="nav-item ">
|
||||
<a class="nav-link" href="{% url 'games:game_list' %}">Library<span class="sr-only"></span></a>
|
||||
</li>
|
||||
<li class="nav-item dropdown">
|
||||
<a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">Systems</a>
|
||||
<a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">Movies</a>
|
||||
<div class="dropdown-menu" aria-labelledby="navbarDropdown">
|
||||
<a class="dropdown-item" href="{% url "games:gamesystem_list" %}">All</a>
|
||||
<a class="dropdown-item" href="{ url "games:gamesystem_list" %}">All</a>
|
||||
{% for system in game_systems %}
|
||||
<a class="dropdown-item" href="{{system.get_absolute_url}}">{{system.name}} ({{system.game_set.count}})</a>
|
||||
{% endfor %}
|
||||
</div>
|
||||
</li>
|
||||
<li class="nav-item dropdown">
|
||||
<a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">Collections</a>
|
||||
<a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">Shows</a>
|
||||
<div class="dropdown-menu" aria-labelledby="navbarDropdown">
|
||||
<a class="dropdown-item" href="{% url "games:gamecollection_list" %}">All</a>
|
||||
<a class="dropdown-item" href="{ url "games:gamecollection_list" %}">All</a>
|
||||
{% for collection in game_collections %}
|
||||
<a class="dropdown-item" href="{{collection.get_absolute_url}}">{{collection.name}} ({{collection.games.count}})</a>
|
||||
{% endfor %}
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
{% if update_in_progress %}<em class="updating">Updating</em><img id="library-update-status" src="{% static 'img/spinner.gif'%}"" width=30 />{% endif %}
|
||||
<form class="form-inline my-2 my-lg-0" method="get" action="{% url 'search:search' %}">
|
||||
<input class="form-control mr-sm-2" name="q" type="search" placeholder="Search" aria-label="Search">
|
||||
<button class="btn btn-primary my-2 my-sm-0" type="submit">Search</button>
|
||||
</form>
|
||||
</div>
|
||||
{% if request.user.is_authenticated %}
|
||||
<a class="nav-link" href="{% url 'account_logout' %}">Logout<span class="sr-only"></span></a>
|
||||
{% else %}
|
||||
<a class="nav-link" href="{% url 'account_login' %}">Login<span class="sr-only"></span></a>
|
||||
|
||||
Reference in New Issue
Block a user