Get_meta button unfocused on return to edit books

This commit is contained in:
Ozzie Isaacs 2021-07-31 09:00:34 +02:00
parent 250cafe814
commit 53603f79bd
5 changed files with 11 additions and 5 deletions

View File

@ -31,7 +31,7 @@ class ComicVine(Metadata):
apikey = "57558043c53943d5d1e96a9ad425b0eb85532ee6"
if self.active:
headers = {
'User-Agent': 'Not Evil Browser' # ,
'User-Agent': 'Not Evil Browser'
}
result = requests.get("https://comicvine.gamespot.com/api/search?api_key="

View File

@ -17,8 +17,8 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
from scholarly import scholarly
from flask import url_for
import json
from cps.services.Metadata import Metadata
#try:
@ -51,7 +51,7 @@ class scholar(Metadata):
v['tags'] = ""
v['ratings'] = 0
v['series'] = ""
v['cover'] = "/../../../static/generic_cover.jpg"
v['cover'] = url_for('static', filename='generic_cover.jpg')
v['url'] = ""
v['source'] = {
"id": self.__id__,

View File

@ -269,3 +269,4 @@ $("#xchange").click(function () {
$("#book_title").val($("#bookAuthor").val());
$("#bookAuthor").val(title);
});

View File

@ -107,4 +107,9 @@ $(function () {
$("#keyword").val(bookTitle);
doSearch(bookTitle);
});
$("#metaModal").on("show.bs.modal", function(e) {
$(e.relatedTarget).one('focus', function (e) {
$(this).blur();
});
});
});

View File

@ -232,7 +232,7 @@
<form class="padded-bottom" id="meta-search">
<div class="input-group">
<label class="sr-only" for="keyword">{{_('Keyword')}}</label>
<input type="text" class="form-control" id="keyword" name="keyword" placeholder="{{_(" Search keyword ")}}">
<input type="text" class="form-control" id="keyword" name="keyword" placeholder="{{_("Search keyword")}}">
<span class="input-group-btn">
<button type="submit" class="btn btn-primary" id="do-search">{{_("Search")}}</button>
</span>
@ -262,7 +262,7 @@
<img class="pull-left img-responsive"
data-toggle="modal"
data-target="#metaModal"
src="<%= cover || "{{ url_for('static', filename='img/academicpaper.svg') }}" %>"
src="<%= cover || "{{ url_for('static', filename='img/academicpaper.svg') }}" %>"
alt="Cover"
>
<div class="media-body">